Skip to content

Commit

Permalink
ramdisk: Configure zRAM and KSM
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanich committed Nov 25, 2014
1 parent 6886be8 commit 39253f5
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
5 changes: 4 additions & 1 deletion rootdir/etc/fstab.pyramid
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#<src> <mnt_point> <type> <mnt_flags> <fs_mgr_flags>
#/dev/block/platform/msm_sdcc.1/by-name/dsps /firmware_dsps vfat ro,shortname=lower wait
/dev/block/platform/msm_sdcc.1/by-name/radio /firmware_radio vfat ro,shortname=lower wait
/dev/block/platform/msm_sdcc.1/by-name/adsp /firmware_q6 vfat ro,shortname=lower wait
/dev/block/platform/msm_sdcc.1/by-name/adsp /firmware_q6 vfat ro,shortname=lower wait
#/dev/block/platform/msm_sdcc.1/by-name/wcnss /firmware_wcnss vfat ro,shortname=lower wait

/dev/block/platform/msm_sdcc.1/by-name/boot /boot emmc defaults defaults
Expand All @@ -18,3 +18,6 @@

# USB storage
/devices/platform/msm_hsusb_host.0/usb1 auto auto defaults voldmanaged=usbdisk:auto

# zRAM
/dev/block/zram0 none swap defaults zramsize=256271974
8 changes: 8 additions & 0 deletions rootdir/etc/init.pyramid.rc
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ on fs

# mount all mmc partitions
mount_all /fstab.pyramid
swapon_all /fstab.pyramid

mkdir /data/tombstones 0771 system system
symlink /data/tombstones /tombstones
Expand Down Expand Up @@ -235,6 +236,13 @@ on boot
chown system system /sys/module/mdp/parameters/mdp_gamma_cooler_colors
chmod 0664 /sys/module/mdp/parameters/mdp_gamma_cooler_colors

# zRAM (read only 1 page at a time)
write /proc/sys/vm/page-cluster 0

# UKSM
write /sys/kernel/mm/uksm/sleep_millisecs 500
write /sys/kernel/mm/uksm/run 1

# Services start here
service qcamerasvr /system/bin/mm-qcamera-daemon
class main
Expand Down

0 comments on commit 39253f5

Please sign in to comment.