* [PATCH] block: fix type for printf argument
@ 2026-01-02 14:49 Ben Dooks
0 siblings, 0 replies; only message in thread
From: Ben Dooks @ 2026-01-02 14:49 UTC (permalink / raw)
To: linux-kernel, linux-block; +Cc: Jens Axboe, Ben Dooks
When making the block-%d id, the type should be %u. Fixes:
block/bio.c:92:62: warning: incorrect type in argument 4 (different types)
block/bio.c:92:62: expected int
block/bio.c:92:62: got unsigned int size
Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
---
block/bio.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/block/bio.c b/block/bio.c
index b3a79285c278..198b966d71b8 100644
--- a/block/bio.c
+++ b/block/bio.c
@@ -89,7 +89,7 @@ static struct bio_slab *create_bio_slab(unsigned int size)
if (!bslab)
return NULL;
- snprintf(bslab->name, sizeof(bslab->name), "bio-%d", size);
+ snprintf(bslab->name, sizeof(bslab->name), "bio-%u", size);
bslab->slab = kmem_cache_create(bslab->name, size,
ARCH_KMALLOC_MINALIGN,
SLAB_HWCACHE_ALIGN | SLAB_TYPESAFE_BY_RCU, NULL);
--
2.37.2.352.g3c44437643
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-01-02 14:49 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-01-02 14:49 [PATCH] block: fix type for printf argument Ben Dooks
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®