summaryrefslogtreecommitdiff
path: root/init.fvpbase.rc
blob: e06b3ed1ae393c7f4a584b3e5b49e34adf09de58 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
on init
    # mount debugfs
    mount debugfs /sys/kernel/debug /sys/kernel/debug

on init
    # disable transparent huge pages
    write /sys/kernel/mm/transparent_hugepage/enabled "never"

    # See storage config details at http://source.android.com/tech/storage/
    mkdir /mnt/shell/emulated 0700 shell shell
    mkdir /storage/emulated 0555 root root
    export EXTERNAL_STORAGE /storage/emulated/legacy
    export EMULATED_STORAGE_SOURCE /mnt/shell/emulated
    export EMULATED_STORAGE_TARGET /storage/emulated
    # Support legacy paths
    symlink /storage/emulated/legacy /sdcard
    symlink /storage/emulated/legacy /mnt/sdcard
    symlink /storage/emulated/legacy /storage/sdcard0
    symlink /mnt/shell/emulated/0 /storage/emulated/legacy

    # Disabled virtual memory randomization
    # (if randomization is enabled the AEM-JIT will have a lower cache hit rate)
    write /proc/sys/kernel/randomize_va_space 0

on fs
    mount_all /fstab.fvpbase
    setprop ro.crypto.fuse_sdcard true

on post-fs-data
    mkdir /data/media 0770 media_rw media_rw

    # Set SELinux security contexts for files used by lava.
    restorecon_recursive /data/local/tmp/lava

on boot

    setprop ARGH ARGH
    setprop ro.radio.use-ppp no
    setprop ro.build.product generic
    setprop ro.product.device generic

# fake some battery state
    setprop status.battery.state Slow
    setprop status.battery.level 5
    setprop status.battery.level_raw  50
    setprop status.battery.level_scale 9

# Disable GPU support
    setprop ro.kernel.qemu 1
    setprop ro.kernel.qemu.gles 0

# Set Display density
    setprop ro.sf.lcd_density 120

# change permissions for process groups
# https://bugs.launchpad.net/bugs/1037611
    chmod 0660 /dev/cpuctl

# disable RenderScript
    setprop config.disable_renderscript 1

# disable some daemons the emulator doesn't want
    stop dund
    stop akmd

# enable Google-specific location features,
# like NetworkLocationProvider and LocationCollector
    setprop ro.com.google.locationfeatures 1

    # change permissions for process groups
    # https://bugs.launchpad.net/bugs/1037611
    chmod 0660 /dev/cpuctl

    # Disable bootanimation to speed up boot
    setprop ro.kernel.android.bootanim 0
    setprop debug.sf.nobootanimation 1

# enable test harness
    setprop ro.test_harness true

    # Setup paths used for socket communication with the dhcp daemon (dhcpd)
    mkdir /data/misc/dhcp 0770 dhcp dhcp
    chown dhcp dhcp /data/misc/dhcp

service dhcpcd_eth0 /system/bin/dhcpcd -dABKL eth0
    class main
    group dhcp
    oneshot

service sdcard /system/bin/sdcard -u 1023 -g 1023 -l /data/media /mnt/shell/emulated
    class late_start

on property:sys.boot_completed=1
    start dns_eth0

service dns_eth0 /system/bin/sh /system/bin/eth0_dns.sh
    disabled
    oneshot
    seclabel u:r:shell:s0