]> git.itanic.dy.fi Git - linux-stable/commit
block: make __get_task_ioprio() easier to read
authorJens Axboe <axboe@kernel.dk>
Mon, 8 Jan 2024 18:51:57 +0000 (11:51 -0700)
committerJens Axboe <axboe@kernel.dk>
Mon, 8 Jan 2024 19:27:46 +0000 (12:27 -0700)
commit53889bcaf536b3abedeaf104019877cee37dd08b
treea60aa7d8c61d9e626c4e0f6f6ab06dd680679d86
parent3b7cb745473aec7255d66e3854abaa9c3f46f952
block: make __get_task_ioprio() easier to read

We don't need to do any gymnastics if we don't have an io_context
assigned at all, so just return early with our default priority.

Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
include/linux/ioprio.h