diff options
| author | Sergey Senozhatsky <[email protected]> | 2022-11-09 20:50:38 +0900 |
|---|---|---|
| committer | Andrew Morton <[email protected]> | 2022-11-30 15:58:51 -0800 |
| commit | 84b33bf7888975d28c0e57011b75c445279c60ec (patch) | |
| tree | 2591e7dcc5b21269907da0e59c66422701058ac5 /tools/perf/scripts/python/flamegraph.py | |
| parent | 5561347aa598b6b12fb6069788ccec9b5e5ebec1 (diff) | |
zram: introduce recompress sysfs knob
Allow zram to recompress (using secondary compression streams)
pages.
Re-compression algorithms (we support up to 3 at this stage)
are selected via recomp_algorithm:
echo "algo=zstd priority=1" > /sys/block/zramX/recomp_algorithm
Please read documentation for more details.
We support several recompression modes:
1) IDLE pages recompression is activated by `idle` mode
echo "type=idle" > /sys/block/zram0/recompress
2) Since there may be many idle pages user-space may pass a size
threshold value (in bytes) and we will recompress pages only
of equal or greater size:
echo "threshold=888" > /sys/block/zram0/recompress
3) HUGE pages recompression is activated by `huge` mode
echo "type=huge" > /sys/block/zram0/recompress
4) HUGE_IDLE pages recompression is activated by `huge_idle` mode
echo "type=huge_idle" > /sys/block/zram0/recompress
[[email protected]: we should always zero out err variable in recompress loop[
Link: https://lkml.kernel.org/r/[email protected]
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Sergey Senozhatsky <[email protected]>
Acked-by: Minchan Kim <[email protected]>
Cc: Nathan Chancellor <[email protected]>
Cc: Alexey Romanov <[email protected]>
Cc: Nhat Pham <[email protected]>
Cc: Nitin Gupta <[email protected]>
Cc: Suleiman Souhlal <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/flamegraph.py')
0 files changed, 0 insertions, 0 deletions