The `max_comp_streams` attribute of zram devices has been deprecated and
all writes were silently ignored by the kernel since 2016. It was
finally removed in 6.15, causing zramctl to fail on ENOENT, when it
should just ignore the error.
Signed-off-by: Jiang XueQian <jiangxueqian@gmail.com>
err(EXIT_FAILURE, _("%s: failed to reset"), zram->devname);
if (nstreams &&
- zram_set_u64parm(zram, "max_comp_streams", nstreams))
+ zram_set_u64parm(zram, "max_comp_streams", nstreams) &&
+ errno != ENOENT)
err(EXIT_FAILURE, _("%s: failed to set number of streams"), zram->devname);
if (algorithm &&