Skip to content

Commit

Permalink
wl18xx: use %zu for size_t arguments in printk calls
Browse files Browse the repository at this point in the history
After 934b9d1 (wl18xx: avoid some -Wformat warnings) there was still
a warning with (at least) ARM gcc version 4.4.1:

drivers/net/wireless/ti/wl18xx/main.c: In function 'wl18xx_conf_init':
drivers/net/wireless/ti/wl18xx/main.c:1026: warning: format '%ld' expects type 'long int', but argument 2 has type 'unsigned int'

Fix this by using %zu for the both formats, since the fw->size and the
macro (derived from sizeof()) are size_t.

Signed-off-by: Luciano Coelho <[email protected]>
  • Loading branch information
Luciano Coelho committed Jun 21, 2012
1 parent 93fb19b commit 4184407
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/wireless/ti/wl18xx/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1023,8 +1023,8 @@ static int wl18xx_conf_init(struct wl1271 *wl, struct device *dev)
}

if (fw->size != WL18XX_CONF_SIZE) {
wl1271_error("configuration binary file size is wrong, "
"expected %d got %d", WL18XX_CONF_SIZE, fw->size);
wl1271_error("configuration binary file size is wrong, expected %zu got %zu",
WL18XX_CONF_SIZE, fw->size);
ret = -EINVAL;
goto out;
}
Expand Down

0 comments on commit 4184407

Please sign in to comment.