summaryrefslogtreecommitdiffstats
path: root/rootdir
diff options
context:
space:
mode:
authorCaio Schnepper <caioschnepper@gmail.com>2015-05-01 23:55:43 -0300
committerCaio Schnepper <caioschnepper@gmail.com>2015-05-28 18:29:17 -0300
commitecc3d13410f7821659f7cc1ef806dfb9378853a3 (patch)
tree6861390f0f9cdda0429aaa2b0252137a675eb85b /rootdir
parente3591e7a641044f28598dfe628c4e0d46d3d7435 (diff)
downloaddevice_samsung_galaxys2-common-ecc3d13410f7821659f7cc1ef806dfb9378853a3.zip
device_samsung_galaxys2-common-ecc3d13410f7821659f7cc1ef806dfb9378853a3.tar.gz
device_samsung_galaxys2-common-ecc3d13410f7821659f7cc1ef806dfb9378853a3.tar.bz2
galaxys2: initial L bringup
Change-Id: Ia356da8437917be3355eba59c1df3943bb33f905
Diffstat (limited to 'rootdir')
-rwxr-xr-xrootdir/fstab.smdk42106
-rw-r--r--rootdir/init.smdk4210.rc63
-rw-r--r--rootdir/lpm.rc64
3 files changed, 40 insertions, 93 deletions
diff --git a/rootdir/fstab.smdk4210 b/rootdir/fstab.smdk4210
index cf7d043..5d8b38a 100755
--- a/rootdir/fstab.smdk4210
+++ b/rootdir/fstab.smdk4210
@@ -11,9 +11,9 @@
/dev/block/mmcblk0p12 /preload ext4 noatime,nosuid,nodev,journal_async_commit wait
# vold-managed volumes ("block device" is actually a sysfs devpath)
-/devices/platform/dw_mmc/mmc_host/mmc0/mmc0 auto auto defaults voldmanaged=sdcard0:11,nonremovable,noemulatedsd
-/devices/platform/s3c-sdhci.2/mmc_host/mmc1 auto auto defaults voldmanaged=sdcard1:auto
-/devices/platform/s3c_otghcd/usb auto auto defaults voldmanaged=usbdisk0:auto
+/devices/platform/dw_mmc/mmc_host/mmc0/mmc0* auto auto defaults wait,voldmanaged=sdcard0:11,nonremovable,noemulatedsd
+/devices/platform/s3c-sdhci.2/mmc_host/mmc1* auto auto defaults wait,voldmanaged=sdcard1:auto,noemulatedsd
+/devices/platform/s3c_otghcd/usb* auto auto defaults voldmanaged=usbdisk0:auto
# recovery
/dev/block/mmcblk0p5 /boot emmc defaults recoveryonly
diff --git a/rootdir/init.smdk4210.rc b/rootdir/init.smdk4210.rc
index 49282aa..efabcfe 100644
--- a/rootdir/init.smdk4210.rc
+++ b/rootdir/init.smdk4210.rc
@@ -41,22 +41,16 @@ on fs
mkdir /data/misc/vpn/profiles 0770 system system
mkdir /data/misc/radio 0775 radio system
+ mkdir /data/radio 0770 radio radio
chmod 0770 /data/misc/wifi
-# Restorecon
- restorecon /efs/nv_data.bin
- restorecon /efs/nv_data.bin.md5
- restorecon /efs/.nv_core.bak
- restorecon /efs/.nv_core.bak.md5
- restorecon /efs/.nv_data.bak
- restorecon /efs/.nv_data.bak.md5
- restorecon /efs/.nv_state
- restorecon /efs/bluetooth/bt_addr
- restorecon /efs/FactoryApp/factorymode
- restorecon /efs/FactoryApp/hw_ver
- restorecon /efs/FactoryApp/keystr
- restorecon /efs/FactoryApp/serial_no
- restorecon /efs/imei/mps_code.dat
+on charger
+
+# CPU Frequency Governor
+ write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor powersave
+
+# EHCI runtime enable for LPA
+ write /sys/devices/platform/s5p-ehci/power/control auto
on post-fs-data
# insmod kernel modules
@@ -116,6 +110,9 @@ on post-fs-data
chmod 0775 /efs/.files/.dx1
chmod 0775 /efs/.files/.dm33
chmod 0775 /efs/.files/.mp301
+
+# SELinux restore context for efs files
+ restorecon_recursive /efs
# MTP Device permission.
chmod 0660 /dev/usb_mtp_gadget
@@ -172,6 +169,7 @@ on post-fs-data
chown system radio /sys/devices/platform/sec-battery/power_supply/battery/video
chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_lp_charging
chown system radio /sys/devices/platform/sec-battery/power_supply/battery/charging_source
+ chown system radio /sys/devices/platform/sec-battery/power_supply/battery/charging_enabled
chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_temp_adc_avg
chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_temp_adc
chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_temp
@@ -234,6 +232,8 @@ on post-fs-data
chmod 0660 /sys/class/rfkill/rfkill0/state
chown bluetooth bluetooth /sys/class/rfkill/rfkill0/state
chown bluetooth bluetooth /sys/class/rfkill/rfkill0/type
+ restorecon /sys/class/rfkill/rfkill0/state
+ restorecon /sys/class/rfkill/rfkill0/type
# Vibetonz
chmod 0660 /dev/tspdrv
@@ -247,6 +247,7 @@ on post-fs-data
chown system media_rw /sys/class/lcd/panel/gamma_mode
chown system media_rw /sys/class/lcd/panel/power_reduce
chown system system /sys/class/backlight/panel/auto_brightness
+ restorecon /sys/class/lcd/panel/power_reduce
# Permissions for mDNIe
chown system media_rw /sys/class/mdnie/mdnie/mode
@@ -255,6 +256,9 @@ on post-fs-data
chown system media_rw /sys/class/mdnie/mdnie/negative
write /sys/class/mdnie/mdnie/scenario 0
write /sys/class/mdnie/mdnie/mode 1
+ restorecon /sys/class/mdnie/mdnie/scenario
+ restorecon /sys/class/mdnie/mdnie/mode
+ restorecon /sys/class/mdnie/mdnie/negative
# Permissions for uart_sel and usb_sel
chown system radio /sys/class/sec/switch/uart_sel/value
@@ -318,6 +322,7 @@ on post-fs-data
on boot
mount debugfs /sys/kernel/debug /sys/kernel/debug
+ setprop wifi.interface wlan0
# permissions for NFC
setprop ro.nfc.port "I2C"
@@ -340,18 +345,25 @@ service cpboot-daemon /sbin/cbd -d -p 8
group radio cache inet misc audio sdcard_rw log sdcard_r
service mdnsd /system/bin/mdnsd
- class main
+ class main
user mdnsr
group inet net_raw
socket mdnsd stream 0660 mdnsr inet
disabled
oneshot
+service charger /sbin/healthd -c
+ class charger
+ critical
+ seclabel u:r:healthd:s0
+
service p2p_supplicant /system/bin/wpa_supplicant \
- -iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf -N \
- -ip2p0 -Dnl80211 -c/data/misc/wifi/p2p_supplicant.conf -e/data/misc/wifi/entropy.bin \
- -puse_p2p_group_interface=1 \
- -O/data/misc/wifi/sockets -g@android:wpa_wlan0
+ -iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf \
+ -I/system/etc/wifi/wpa_supplicant.conf \
+ -O/data/misc/wifi/sockets -N \
+ -ip2p0 -Dnl80211 -c/data/misc/wifi/p2p_supplicant.conf -e/data/misc/wifi/entropy.bin \
+ -puse_p2p_group_interface=1 \
+ -g@android:wpa_wlan0
# we will start as root and wpa_supplicant will switch to user wifi
# after setting up the capabilities required for WEXT
# user wifi
@@ -362,9 +374,11 @@ service p2p_supplicant /system/bin/wpa_supplicant \
oneshot
service wpa_supplicant /system/bin/wpa_supplicant \
- -Dnl80211 -iwlan0 -e/data/misc/wifi/entropy.bin \
- -c/data/misc/wifi/wpa_supplicant.conf \
- -O/data/misc/wifi/sockets -g@android:wpa_wlan0
+ -Dnl80211 -iwlan0 -e/data/misc/wifi/entropy.bin \
+ -c/data/misc/wifi/wpa_supplicant.conf \
+ -I/system/etc/wifi/wpa_supplicant.conf \
+ -O/data/misc/wifi/sockets \
+ -g@android:wpa_wlan0
# we will start as root and wpa_supplicant will switch to user wifi
# after setting up the capabilities required for WEXT
# user wifi
@@ -404,11 +418,8 @@ service iprenew_bt-pan /system/bin/dhcpcd -n
disabled
oneshot
-# bluetooth mac address
-service bdaddr /system/bin/bdaddr_read
+service macloader /system/bin/macloader
class main
- user root
- disabled
oneshot
# bugreport is triggered by holding down volume down, volume up and power
diff --git a/rootdir/lpm.rc b/rootdir/lpm.rc
deleted file mode 100644
index 755fd2a..0000000
--- a/rootdir/lpm.rc
+++ /dev/null
@@ -1,64 +0,0 @@
-on early-init
- start ueventd
-
-on init
- export PATH /sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin
- export LD_LIBRARY_PATH /vendor/lib:/system/lib
- export ANDROID_ROOT /system
- export ANDROID_DATA /data
- export ANDROID_CACHE /cache
- export SECONDARY_STORAGE /mnt/emmc
- export EXTERNAL_STORAGE /mnt/sdcard
-
- symlink /system/etc /etc
- mkdir /mnt 0775 root system
-
- mkdir /system
- mkdir /tmp
- mkdir /mnt 0775 root root
-
-
-on boot
-# CPU Frequency Governor
- write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor powersave
-
- ifup lo
- hostname localhost
- domainname localdomain
-
- class_start default
-
-service ueventd /sbin/ueventd
- class core
- critical
-
-service console /system/bin/sh
- class core
- console
-
-service adbd /sbin/adbd
- disabled
-
-service charger /charger
- class default
- user root
-
-# Always start adbd on userdebug and eng builds
-# In recovery, always run adbd as root.
-on property:ro.debuggable=1
- write /sys/class/android_usb/android0/enable 0
- write /sys/class/android_usb/android0/idVendor 04e8
- write /sys/class/android_usb/android0/idProduct 6860
- write /sys/class/android_usb/android0/functions adb
- write /sys/class/android_usb/android0/enable 1
- write /sys/class/android_usb/android0/iManufacturer $ro.product.manufacturer
- write /sys/class/android_usb/android0/iProduct $ro.product.model
- write /sys/class/android_usb/android0/iSerial $ro.serialno
- start adbd
- setprop service.adb.root 1
-
-# Restart adbd so it can run as root
-on property:service.adb.root=1
- write /sys/class/android_usb/android0/enable 0
- restart adbd
- write /sys/class/android_usb/android0/enable 1