config ZRAM
tristate "Compressed RAM block device support"
- depends on BLOCK && SYSFS && ZSMALLOC && CRYPTO
- select CRYPTO_LZO
+ depends on BLOCK && SYSFS && CRYPTO
+ select CRYPTO_LZ4
+ select ZPOOL
default n
help
Creates virtual block devices called /dev/zramX (X = 0, 1, ...).
/sys/kernel/debug/zram/zramX/block_state.
See Documentation/blockdev/zram.txt for more information.
+
+config ZRAM_DEFAULT_COMP_ALGORITHM
+ string "Default ZRAM compression algorithm"
+ default "lz4"
+
+if ZRAM
+
+choice
+ prompt "Default zRAM compressed memory allocator"
+ default ZRAM_DEFAULT_ZSMALLOC
+ help
+ Select the compressed memory allocator that will be used by default
+ for all devices.
+
+ config ZRAM_DEFAULT_ZBUD
+ bool "zbud"
+ select ZBUD
+
+ config ZRAM_DEFAULT_Z3FOLD
+ bool "z3fold"
+ select Z3FOLD
+
+ config ZRAM_DEFAULT_ZSMALLOC
+ bool "zsmalloc"
+ select ZSMALLOC
+
+endchoice
+
+config ZRAM_DEFAULT_POOL
+ string
+ default "zbud" if ZRAM_DEFAULT_ZBUD
+ default "z3fold" if ZRAM_DEFAULT_Z3FOLD
+ default "zsmalloc" if ZRAM_DEFAULT_ZSMALLOC
+
+endif