mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-03-06 12:58:22 +03:00
cgroup: Also set io.bfq.weight
Current kernels with BFQ scheduler do not yet set their IO weight through "io.weight" but through "io.bfq.weight" (using a slightly different interface supporting only default weights, not per-device weights). This commit enables "IOWeight=" to just to that. This patch may be dropped at some time later. Github-Link: https://github.com/systemd/systemd/issues/7057 Signed-off-by: Kai Krakow <kai@kaishome.de>
This commit is contained in:
parent
06e93130b4
commit
2dbc45aea7
3
NEWS
3
NEWS
@ -429,6 +429,9 @@ CHANGES WITH 243 in spe:
|
|||||||
option that permits selecting the timout how long to wait for a
|
option that permits selecting the timout how long to wait for a
|
||||||
device with an encryption key before asking for the password.
|
device with an encryption key before asking for the password.
|
||||||
|
|
||||||
|
* IOWeight= has learnt to properly set the IO weight when using the
|
||||||
|
BFQ scheduler officially found in kernels 5.0+.
|
||||||
|
|
||||||
Contributions from: Aaron Barany, Adrian Bunk, Alan Jenkins, Andrej
|
Contributions from: Aaron Barany, Adrian Bunk, Alan Jenkins, Andrej
|
||||||
Valek, Anita Zhang, Arian van Putten, Balint Reczey, Bastien Nocera,
|
Valek, Anita Zhang, Arian van Putten, Balint Reczey, Bastien Nocera,
|
||||||
Ben Boeckel, Benjamin Robin, camoz, Chen Qi, Chris Chiu, Chris Down,
|
Ben Boeckel, Benjamin Robin, camoz, Chen Qi, Chris Chiu, Chris Down,
|
||||||
|
@ -1063,6 +1063,11 @@ static void cgroup_context_apply(
|
|||||||
xsprintf(buf, "default %" PRIu64 "\n", weight);
|
xsprintf(buf, "default %" PRIu64 "\n", weight);
|
||||||
(void) set_attribute_and_warn(u, "io", "io.weight", buf);
|
(void) set_attribute_and_warn(u, "io", "io.weight", buf);
|
||||||
|
|
||||||
|
/* FIXME: drop this when distro kernels properly support BFQ through "io.weight"
|
||||||
|
* See also: https://github.com/systemd/systemd/pull/13335 */
|
||||||
|
xsprintf(buf, "%" PRIu64 "\n", weight);
|
||||||
|
(void) set_attribute_and_warn(u, "io", "io.bfq.weight", buf);
|
||||||
|
|
||||||
if (has_io) {
|
if (has_io) {
|
||||||
CGroupIODeviceLatency *latency;
|
CGroupIODeviceLatency *latency;
|
||||||
CGroupIODeviceLimit *limit;
|
CGroupIODeviceLimit *limit;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user