-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow multiple whitespace-separated compression-algorithm=s, and give the ones after the first one to /recomp_algorithm #200
Conversation
5683547
to
fcaa5e6
Compare
Thank you so much I'll test it as soon as I can. |
fcaa5e6
to
15e5371
Compare
Rebased |
15e5371
to
cac07b6
Compare
Sorry for the delay. I got the notification and then forgot to look at this. Code-wise this looks good, but I'm not convinced that this is the right interface. I wonder if the interface shouldn't be inverted, allowing the user to list each "recompression level" separately, with a list of options. But I'm not sure how to express this concisely. |
I didn't really notice this because the interface is kinda iffy ( I can't think of a multi-key system that'd be any good. Maybe
for echo a > /sys/block/zram0/comp_algorithm
echo algo=b priority=1 > /sys/block/zramX/recomp_algorithm
echo type=huge threshold=1000 priority=1 > /sys/block/zramX/recompress
echo algo=c priority=2 > /sys/block/zramX/recomp_algorithm
echo threshold=3000 > /sys/block/zramX/recompress ? |
That seems pretty nice. |
cac07b6
to
8b9be6d
Compare
Added |
8b9be6d
to
fdaaca0
Compare
As a side-effect we also support |
4d41ae3
to
0b8a0c3
Compare
…al,recomp,params) Ref: systemd#178 (comment)
0b8a0c3
to
62505cc
Compare
LGTM. Let's wait for feedback from the reporter. |
OK, let's do this. It'd be good to some testing on a real system, but we can do this later. |
LGTM, have tested few parameters. Seems to work as expected. Thank you both. |
Ref: #178 (comment)
I've tested the error case, @OmegaSquad82 needs to test the "actually setting it" case.
A config like
was previously "compress with
a b c
" (naturally invalid) and is now "compress witha
, recompress withb
thenc
"