Maroc-OS/Merruk-Technology — pull request #5 by RafaelBaugis (2012-10-20 13:22:58+00:00)
Title: add zRAM feature

ramzswap is deprecated, this new method create a swap with compression in lzo inside the RAM

for use this creat a init.d script

#!/system/bin/sh

#########################################
### select favorite values zRAM Size. ###
#########################################
export size="72" #This value is in MB

#################################
### WONT CHANGE VALUES BELLOW ###
#################################

insmod /system/lib/modules/lzo_compress.ko
insmod /system/lib/modules/lzo_decompress.ko
insmod /system/lib/modules/zram.ko

echo $(($size*1024*1024)) > /sys/block/zram0/disksize

mkswap /dev/block/zram0
swapon /dev/block/zram0