From: John Garry Date: Fri, 19 Jul 2024 11:29:11 +0000 (+0000) Subject: block: Simplify definition of RQF_NAME() X-Git-Tag: v6.11-rc1~79^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2d61a6c2ca7aadce3771f81a3624848f97dcc39e;p=thirdparty%2Fkernel%2Flinux.git block: Simplify definition of RQF_NAME() Now that we have a bit index for RQF_x in __RQF_x, use __RQF_x to simplify the definition of RQF_NAME() by not using ilog2((__force u32()). Reviewed-by: Bart Van Assche Signed-off-by: John Garry Link: https://lore.kernel.org/r/20240719112912.3830443-15-john.g.garry@oracle.com Signed-off-by: Jens Axboe --- diff --git a/block/blk-mq-debugfs.c b/block/blk-mq-debugfs.c index a4accd79c225e..34ed099c34291 100644 --- a/block/blk-mq-debugfs.c +++ b/block/blk-mq-debugfs.c @@ -240,7 +240,7 @@ static const char *const cmd_flag_name[] = { }; #undef CMD_FLAG_NAME -#define RQF_NAME(name) [ilog2((__force u32)RQF_##name)] = #name +#define RQF_NAME(name) [__RQF_##name] = #name static const char *const rqf_name[] = { RQF_NAME(STARTED), RQF_NAME(FLUSH_SEQ),