diff options
author | Sergey Senozhatsky <sergey.senozhatsky@gmail.com> | 2014-04-08 02:38:17 +0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-08 03:36:01 +0400 |
commit | e46b8a030d76d3c94156c545c3f4c3676d813435 (patch) | |
tree | 9629389f89d3086a6428ec6a8e47bc59ddfcf3ec /drivers/block/zram/zram_drv.h | |
parent | fe8eb122c82b2049c460fc6df6e8583a2f935cff (diff) | |
download | linux-e46b8a030d76d3c94156c545c3f4c3676d813435.tar.xz |
zram: make compression algorithm selection possible
Add and document `comp_algorithm' device attribute. This attribute allows
to show supported compression and currently selected compression
algorithms:
cat /sys/block/zram0/comp_algorithm
[lzo] lz4
and change selected compression algorithm:
echo lzo > /sys/block/zram0/comp_algorithm
Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
Acked-by: Minchan Kim <minchan@kernel.org>
Cc: Jerome Marchand <jmarchan@redhat.com>
Cc: Nitin Gupta <ngupta@vflare.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/block/zram/zram_drv.h')
-rw-r--r-- | drivers/block/zram/zram_drv.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/block/zram/zram_drv.h b/drivers/block/zram/zram_drv.h index ccf36d11755a..7f21c145e317 100644 --- a/drivers/block/zram/zram_drv.h +++ b/drivers/block/zram/zram_drv.h @@ -101,5 +101,6 @@ struct zram { u64 disksize; /* bytes */ int max_comp_streams; struct zram_stats stats; + char compressor[10]; }; #endif |