lkml.org 
[lkml]   [2022]   [Oct]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCHv3 4/8] zram: Introduce recompress sysfs knob
On Sun,  9 Oct 2022 18:07:16 +0900 Sergey Senozhatsky <senozhatsky@chromium.org> wrote:

> Allow zram to recompress (using secondary compression streams)
> pages. We support three modes:
>
> 1) IDLE pages recompression is activated by `idle` mode
>
> echo idle > /sys/block/zram0/recompress
>
> 2) Since there may be many idle pages user-space may pass a size
> watermark value and we will recompress IDLE pages only of equal
> or greater size:
>
> echo 888 > /sys/block/zram0/recompress

It's helpful to describe the units ("bytes") here and in the
docmentation.

> 3) HUGE pages recompression is activated by `huge` mode
>
> echo huge > /sys/block/zram0/recompress
>
> 4) HUGE_IDLE pages recompression is activated by `huge_idle` mode
>
> echo huge_idle > /sys/block/zram0/recompress
>
> ...
>
> + if (IS_ERR((void *)handle_next)) {

IS_ERR_VALUE() avoids castsing back and forth.


\
 
 \ /
  Last update: 2022-10-18 02:15    [W:0.159 / U:0.352 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site