Skip to contentSkip to conversation

drivers/net/wireless/ath/ath10k/mac.c:1264:8: warning: format '%zd' expects argument of type 'signed size_t', but argument 4 has type 'long int'

ath9k-devel Kalle Valo 1 participant 1 message Jul 5, 2013 2 messages not in the archive Qualcomm Atheros ATH10K wireless driver

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): 51d510b8.PYCVZD+C0DOiz9UB%[email protected]

A message that is not in the archive (sent off-list or not yet received): 20130704080448.GD17178@localhost

Kalle Valo

author
#2 lore raw

Hi Fengguang,

Quoted 8 lines · Fengguang Wu

FYI, there are new compile warnings show up in

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next master
head:   fa1383200d289afdff2f5678eb89483daa537465
commit: 5e3dd157d7e70f0e3cea3f2573ed69fb156a19d5 ath10k: mac80211 driver for Qualcomm Atheros 802.11ac CQA98xx devices
date:   3 weeks ago
config: make ARCH=microblaze allyesconfig
Quoted 6 lines

All warnings:

drivers/net/wireless/ath/ath10k/mac.c: In function 'ath10k_update_channel_list':

Quoted 1 line
Quoted 1 line

drivers/net/wireless/ath/ath10k/mac.c:1264:8: warning: format '%zd' expects argument of type 'signed size_t', but argument 4 has type 'long int' [-Wformat=]

           ch->max_antenna_gain, ch->mode);
           ^

Thanks for the report. Unfortunately I can't reproduce the warning myself, but can you please try if the patch below fixes it?

Kalle

drivers/net/wireless/ath/ath10k/mac.c +1 -1
index da5c333..1ce6ecd 100644
@@ -1261,7 +1261,7 @@ static int ath10k_update_channel_list(struct ath10k *ar)
                                continue;
 
                        ath10k_dbg(ATH10K_DBG_WMI,
-                                  "%s: [%zd/%d] freq %d maxpower %d regpower %d antenna %d mode %d\n",
+                                  "%s: [%d/%d] freq %d maxpower %d regpower %d antenna %d mode %d\n",
                                   __func__, ch - arg.channels, arg.n_channels,
                                   ch->freq, ch->max_power, ch->max_reg_power,
                                   ch->max_antenna_gain, ch->mode);