Make foreground and background I/O priority different

The default I/O priority is "best effort" so the combination of "none"
and "restrict-to-be" is not sufficient to make foreground and background
I/O priorities different. This CL makes sure that foreground and
background I/O priorities are different.

As one can see, this CL has the intended effect in Cuttlefish:
$ adb -s 0.0.0.0:6520 shell 'cd /dev/blkio && grep -aH . blkio.prio.class background/blkio.prio.class'
blkio.prio.class:promote-to-rt
background/blkio.prio.class:restrict-to-be

Bug: 186902601
Change-Id: I24d30d360280d8c398684b0b5e88635f658ff870
Signed-off-by: Bart Van Assche <bvanassche@google.com>
This commit is contained in:
Bart Van Assche 2024-03-11 16:14:47 -07:00
parent a08ad4b1e5
commit 7f3fe0aaf2

View file

@ -247,6 +247,7 @@ on init
write /dev/blkio/background/blkio.bfq.weight 10
write /dev/blkio/blkio.group_idle 0
write /dev/blkio/background/blkio.group_idle 0
write /dev/blkio/blkio.prio.class promote-to-rt
write /dev/blkio/background/blkio.prio.class restrict-to-be
restorecon_recursive /mnt