summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDima Zavin2011-11-04 14:45:52 -0500
committerDima Zavin2011-11-04 14:45:56 -0500
commit4a2539085062a715b0d345eb50ea48738423c909 (patch)
tree4411b0958c36879a33fdae9e54f6d13f4aac87a4
parent4f7c0843bbaa9cb4ec3a7890461cebbee689530a (diff)
downloadplatform-system-core-4a2539085062a715b0d345eb50ea48738423c909.tar.gz
platform-system-core-4a2539085062a715b0d345eb50ea48738423c909.tar.xz
platform-system-core-4a2539085062a715b0d345eb50ea48738423c909.zip
rootdir: init.rc: write default oom_adj before starting ueventdandroid-4.0.2_r1
Otherwise, ueventd's oom_adj value would have been 0 and it could easily get killed early during low memory events Change-Id: I1adbd18c37215b26ae77e70f7b8dbd1e143fc2d4 Signed-off-by: Dima Zavin <dima@android.com>
-rw-r--r--rootdir/init.rc6
1 files changed, 3 insertions, 3 deletions
diff --git a/rootdir/init.rc b/rootdir/init.rc
index 46af96c46..3f7cbc3c4 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -1,4 +1,7 @@
1on early-init 1on early-init
2 # Set init and its forked children's oom_adj.
3 write /proc/1/oom_adj -16
4
2 start ueventd 5 start ueventd
3 6
4# create mountpoints 7# create mountpoints
@@ -204,9 +207,6 @@ on boot
204 chown root system /sys/module/lowmemorykiller/parameters/minfree 207 chown root system /sys/module/lowmemorykiller/parameters/minfree
205 chmod 0664 /sys/module/lowmemorykiller/parameters/minfree 208 chmod 0664 /sys/module/lowmemorykiller/parameters/minfree
206 209
207 # Set init and its forked children's oom_adj.
208 write /proc/1/oom_adj -16
209
210 # Tweak background writeout 210 # Tweak background writeout
211 write /proc/sys/vm/dirty_expire_centisecs 200 211 write /proc/sys/vm/dirty_expire_centisecs 200
212 write /proc/sys/vm/dirty_background_ratio 5 212 write /proc/sys/vm/dirty_background_ratio 5