From: ian Date: Tue, 20 Oct 2015 03:25:17 +0000 (+0000) Subject: Fix printf format to allow for bus_size_t not being u_long on all platforms. X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=e4cc0fc7e47772da11f6429cd72b00999c1ba56b;p=people%2Fjulieng%2Ffreebsd.git Fix printf format to allow for bus_size_t not being u_long on all platforms. --- diff --git a/sys/kern/subr_busdma_bufalloc.c b/sys/kern/subr_busdma_bufalloc.c index b0b1ba826d48..c8980e1a52d7 100644 --- a/sys/kern/subr_busdma_bufalloc.c +++ b/sys/kern/subr_busdma_bufalloc.c @@ -94,8 +94,8 @@ busdma_bufalloc_create(const char *name, bus_size_t minimum_alignment, for (i = 0, bz = ba->buf_zones, cursize = ba->min_size; i < nitems(ba->buf_zones) && cursize <= MAX_ZONE_BUFSIZE; ++i, ++bz, cursize <<= 1) { - snprintf(bz->name, sizeof(bz->name), "dma %.10s %lu", - name, cursize); + snprintf(bz->name, sizeof(bz->name), "dma %.10s %ju", + name, (uintmax_t)cursize); bz->size = cursize; bz->umazone = uma_zcreate(bz->name, bz->size, NULL, NULL, NULL, NULL, bz->size - 1, zcreate_flags);