2010-07-07 13:06:13 +00:00
|
|
|
# CyanogenMod Extras
|
2013-07-28 02:52:40 +00:00
|
|
|
import /init.superuser.rc
|
2015-03-09 23:34:43 +00:00
|
|
|
import /init.prebundle.rc
|
2010-07-07 13:06:13 +00:00
|
|
|
|
2012-10-18 15:38:25 +00:00
|
|
|
on init
|
|
|
|
export ANDROID_CACHE /cache
|
|
|
|
export TERMINFO /system/etc/terminfo
|
|
|
|
|
|
|
|
on post-fs-data
|
|
|
|
mkdir /cache/dalvik-cache 0771 system system
|
|
|
|
chown system system /cache/dalvik-cache
|
|
|
|
chmod 0771 /cache/dalvik-cache
|
2013-05-12 10:58:01 +00:00
|
|
|
mkdir /data/.ssh 0750 root shell
|
2012-10-18 15:38:25 +00:00
|
|
|
|
2012-11-23 17:15:16 +00:00
|
|
|
# Run sysinit
|
|
|
|
start sysinit
|
|
|
|
|
2013-06-12 11:12:18 +00:00
|
|
|
on boot
|
2013-05-21 12:23:19 +00:00
|
|
|
# interactive governor
|
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/timer_rate
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/timer_rate
|
2014-11-19 00:48:30 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/timer_slack
|
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/timer_slack
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/min_sample_time
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/min_sample_time
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq
|
2014-11-19 00:48:30 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/target_loads
|
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/target_loads
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/go_hispeed_load
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/go_hispeed_load
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/above_hispeed_delay
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/above_hispeed_delay
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/boost
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/boost
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/boostpulse
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/boostpulse
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/input_boost
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/input_boost
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/boostpulse_duration
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/boostpulse_duration
|
2013-07-12 15:44:16 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/io_is_busy
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/io_is_busy
|
2014-01-14 17:44:07 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/sync_freq
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/sync_freq
|
2014-11-19 00:48:30 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/up_threshold_any_cpu_freq
|
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/up_threshold_any_cpu_freq
|
2014-01-14 17:44:07 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/up_threshold_any_cpu_load
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/up_threshold_any_cpu_load
|
2014-01-14 17:44:07 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/interactive/sampling_down_factor
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/interactive/sampling_down_factor
|
2014-01-14 17:44:07 +00:00
|
|
|
|
2013-05-21 12:23:19 +00:00
|
|
|
# ondemand governor
|
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/boostfreq
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/boostfreq
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/boostpulse
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/boostpulse
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/boosttime
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/boosttime
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/io_is_busy
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/io_is_busy
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/down_differential
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/down_differential
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/sampling_rate
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/sampling_rate
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/powersave_bias
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/powersave_bias
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/sampling_down_factor
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/sampling_down_factor
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/up_threshold
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/up_threshold
|
2013-10-04 11:31:56 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/input_boost
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/input_boost
|
2013-10-08 06:39:12 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/up_threshold_multi_core
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/up_threshold_multi_core
|
2013-10-08 06:39:12 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/down_differential_multi_core
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/down_differential_multi_core
|
2013-10-08 06:39:12 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/optimal_freq
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/optimal_freq
|
2013-10-08 06:39:12 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/sync_freq
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/sync_freq
|
2013-10-08 06:39:12 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpufreq/ondemand/up_threshold_any_cpu_load
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpufreq/ondemand/up_threshold_any_cpu_load
|
2013-05-21 12:23:19 +00:00
|
|
|
|
|
|
|
# Assume SMP uses shared cpufreq policy for all CPUs
|
|
|
|
chown system system /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
|
2013-05-21 12:23:19 +00:00
|
|
|
chown system system /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
|
2014-02-23 20:49:00 +00:00
|
|
|
chmod 0664 /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
|
2013-05-21 12:23:19 +00:00
|
|
|
|
2012-10-18 15:38:25 +00:00
|
|
|
chown system system /sys/block/mmcblk0/queue/scheduler
|
|
|
|
chmod 0664 /sys/block/mmcblk0/queue/scheduler
|
2015-01-03 05:44:43 +00:00
|
|
|
restorecon /sys/block/mmcblk0/queue/scheduler
|
2012-10-18 15:38:25 +00:00
|
|
|
|
2015-04-03 00:01:36 +00:00
|
|
|
chown system system /dev/cpuctl/cpu.notify_on_migrate
|
|
|
|
chmod 0664 /dev/cpuctl/cpu.notify_on_migrate
|
2013-10-02 18:28:28 +00:00
|
|
|
|
2014-05-20 21:52:30 +00:00
|
|
|
# Define TCP delayed ack settings for WiFi & LTE
|
|
|
|
chown system system /sys/kernel/ipv4/tcp_delack_seg
|
|
|
|
chown system system /sys/kernel/ipv4/tcp_use_userconfig
|
|
|
|
setprop net.tcp.delack.default 1
|
|
|
|
setprop net.tcp.delack.wifi 20
|
|
|
|
setprop net.tcp.delack.lte 8
|
|
|
|
setprop net.tcp.usercfg.default 0
|
|
|
|
setprop net.tcp.usercfg.wifi 1
|
|
|
|
setprop net.tcp.usercfg.lte 1
|
|
|
|
|
2012-10-18 15:38:25 +00:00
|
|
|
# adb over network
|
|
|
|
on property:service.adb.tcp.port=5555
|
|
|
|
stop adbd
|
|
|
|
start adbd
|
|
|
|
on property:service.adb.tcp.port=-1
|
|
|
|
stop adbd
|
|
|
|
start adbd
|
|
|
|
|
2012-11-23 17:15:16 +00:00
|
|
|
# sysinit (/system/etc/init.d)
|
|
|
|
service sysinit /system/bin/sysinit
|
|
|
|
user root
|
|
|
|
oneshot
|
2013-06-12 11:12:18 +00:00
|
|
|
disabled
|
2015-05-05 19:30:59 +00:00
|
|
|
|
|
|
|
# bugreport is triggered by holding down volume down, volume up and power
|
|
|
|
service bugreport /system/bin/dumpstate -d -p -B \
|
|
|
|
-o /data/data/com.android.shell/files/bugreports/bugreport
|
|
|
|
oneshot
|
|
|
|
disabled
|
|
|
|
keycodes 114 115 116
|