Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1102ab5f authored by Nathan Huckleberry's avatar Nathan Huckleberry Committed by Harshit Jain
Browse files

BACKPORT: dm verity: enable WQ_HIGHPRI on verify_wq



WQ_HIGHPRI increases throughput and decreases disk latency when using
dm-verity. This is important in Android for camera startup speed.

The following tests were run by doing 60 seconds of random reads using
a dm-verity device backed by two ramdisks.

Without WQ_HIGHPRI
lat (usec): min=13, max=3947, avg=69.53, stdev=50.55
READ: bw=51.1MiB/s (53.6MB/s), 51.1MiB/s-51.1MiB/s (53.6MB/s-53.6MB/s)

With WQ_HIGHPRI:
lat (usec): min=13, max=7854, avg=31.15, stdev=30.42
READ: bw=116MiB/s (121MB/s), 116MiB/s-116MiB/s (121MB/s-121MB/s)

Further testing was done by measuring how long it takes to open a
camera on an Android device.

Without WQ_HIGHPRI
Total verity work queue wait times (ms):
880.960, 789.517, 898.852

With WQ_HIGHPRI:
Total verity work queue wait times (ms):
528.824, 439.191, 433.300

The average time to open the camera is reduced by 350ms (or 40-50%).

Signed-off-by: default avatarNathan Huckleberry <nhuck@google.com>
Signed-off-by: default avatarMike Snitzer <snitzer@kernel.org>

Bug: 233247259
(cherry picked from commit afd41fff9c73ccc3757e94ad727d2a9ac4d7f6cb)
[nhuck: Resolved minor conflict in drivers/md/dm-verity-target.c ]
Signed-off-by: default avatarNathan Huckleberry <nhuck@google.com>
(cherry picked from https://android-review.googlesource.com/q/commit:fd4631f8568f5bf16ac5c8b0686d40fad6e4e047)
Merged-In: I7d600c924b4a3e793b9a26c2852139683061a831

Change-Id: Ib858d388aa24e4a625085804c097ad66aa179a14
(cherry picked from commit d0a293d5e0b5bffe7a3eb03d3c28ebc5bbbd17d0)
(cherry picked from commit 4f8376242f5d5375ead01fae25208fd1074678f5)
(cherry picked from commit 7404e78d327368732d2ca758e70313fec1cc4549)
(cherry picked from commit 316c24df038a9f13b78d0cde4d244d62a5cc127e)
parent 38c7de54
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment