Nitin Gupta | 16a4bfb | 2010-06-01 13:31:24 +0530 | [diff] [blame] | 1 | config ZRAM |
| 2 | tristate "Compressed RAM block device support" |
Sergey Senozhatsky | ebaf9ab | 2016-07-26 15:22:45 -0700 | [diff] [blame] | 3 | depends on BLOCK && SYSFS && ZSMALLOC && CRYPTO |
| 4 | select CRYPTO_LZO |
Nitin Gupta | 16a4bfb | 2010-06-01 13:31:24 +0530 | [diff] [blame] | 5 | default n |
| 6 | help |
| 7 | Creates virtual block devices called /dev/zramX (X = 0, 1, ...). |
| 8 | Pages written to these disks are compressed and stored in memory |
| 9 | itself. These disks allow very fast I/O and compression provides |
| 10 | good amounts of memory savings. |
| 11 | |
| 12 | It has several use cases, for example: /tmp storage, use as swap |
| 13 | disks and maybe many more. |
| 14 | |
Minchan Kim | f1dcb85 | 2018-06-07 17:05:49 -0700 | [diff] [blame] | 15 | See Documentation/blockdev/zram.txt for more information. |
Minchan Kim | bc6f4ed | 2017-09-06 16:20:10 -0700 | [diff] [blame] | 16 | |
| 17 | config ZRAM_WRITEBACK |
Minchan Kim | 86d820b | 2018-12-28 00:36:47 -0800 | [diff] [blame] | 18 | bool "Write back incompressible or idle page to backing device" |
Minchan Kim | bc6f4ed | 2017-09-06 16:20:10 -0700 | [diff] [blame] | 19 | depends on ZRAM |
| 20 | default n |
| 21 | help |
| 22 | With incompressible page, there is no memory saving to keep it |
| 23 | in memory. Instead, write it out to backing device. |
| 24 | For this feature, admin should set up backing device via |
| 25 | /sys/block/zramX/backing_dev. |
| 26 | |
Minchan Kim | 86d820b | 2018-12-28 00:36:47 -0800 | [diff] [blame] | 27 | With /sys/block/zramX/{idle,writeback}, application could ask |
| 28 | idle page's writeback to the backing device to save in memory. |
| 29 | |
Minchan Kim | f1dcb85 | 2018-06-07 17:05:49 -0700 | [diff] [blame] | 30 | See Documentation/blockdev/zram.txt for more information. |
| 31 | |
| 32 | config ZRAM_MEMORY_TRACKING |
| 33 | bool "Track zRam block status" |
| 34 | depends on ZRAM && DEBUG_FS |
| 35 | help |
| 36 | With this feature, admin can track the state of allocated blocks |
| 37 | of zRAM. Admin could see the information via |
| 38 | /sys/kernel/debug/zram/zramX/block_state. |
| 39 | |
| 40 | See Documentation/blockdev/zram.txt for more information. |