Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

test suite: use %zu to print size_t

On 32-bit, we can't use %lu to print a size_t variable and gcc warns us
about it. Shame it doesn't warn about it on 64-bit.

Link: https://lkml.kernel.org/r/20250403003311.359917-1-Liam.Howlett@oracle.com
Fixes: cc86e0c2f306 ("radix tree test suite: add support for slab bulk APIs")
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>

authored by

Matthew Wilcox (Oracle) and committed by
Andrew Morton
a30951d0 be8254f6

+2 -2
+2 -2
tools/testing/shared/linux.c
··· 150 150 void kmem_cache_free_bulk(struct kmem_cache *cachep, size_t size, void **list) 151 151 { 152 152 if (kmalloc_verbose) 153 - pr_debug("Bulk free %p[0-%lu]\n", list, size - 1); 153 + pr_debug("Bulk free %p[0-%zu]\n", list, size - 1); 154 154 155 155 pthread_mutex_lock(&cachep->lock); 156 156 for (int i = 0; i < size; i++) ··· 168 168 size_t i; 169 169 170 170 if (kmalloc_verbose) 171 - pr_debug("Bulk alloc %lu\n", size); 171 + pr_debug("Bulk alloc %zu\n", size); 172 172 173 173 pthread_mutex_lock(&cachep->lock); 174 174 if (cachep->nr_objs >= size) {