iwm: plug set-but-not-used vars

Sponsored by:	Rubicon Communications, LLC ("Netgate")
This commit is contained in:
Mateusz Guzik 2022-04-22 22:16:25 +00:00
parent 2f2a5ecdf8
commit f7daf71038
2 changed files with 12 additions and 1 deletions

View file

@ -3056,7 +3056,12 @@ static int
iwm_get_noise(struct iwm_softc *sc,
const struct iwm_statistics_rx_non_phy *stats)
{
int i, total, nbant, noise;
int i, noise;
#ifdef IWM_DEBUG
int nbant, total;
#else
int nbant __unused, total __unused;
#endif
total = nbant = noise = 0;
for (i = 0; i < 3; i++) {
@ -5487,12 +5492,14 @@ iwm_handle_rxb(struct iwm_softc *sc, struct mbuf *m)
break;
case IWM_SCAN_ITERATION_COMPLETE_UMAC: {
#ifdef IWM_DEBUG
struct iwm_umac_scan_iter_complete_notif *notif;
notif = (void *)pkt->data;
IWM_DPRINTF(sc, IWM_DEBUG_SCAN, "UMAC scan iteration "
"complete, status=0x%x, %d channels scanned\n",
notif->status, notif->scanned_channels);
#endif
break;
}
@ -5522,6 +5529,7 @@ iwm_handle_rxb(struct iwm_softc *sc, struct mbuf *m)
break;
case IWM_SCD_QUEUE_CFG: {
#ifdef IWM_DEBUG
struct iwm_scd_txq_cfg_rsp *rsp;
rsp = (void *)pkt->data;
@ -5530,6 +5538,7 @@ iwm_handle_rxb(struct iwm_softc *sc, struct mbuf *m)
"tid=%d scd_queue=%d\n",
rsp->token, rsp->sta_id, rsp->tid,
rsp->scd_queue);
#endif
break;
}

View file

@ -187,6 +187,7 @@ iwm_te_handle_notif(struct iwm_softc *sc,
le32toh(notif->action));
if (!le32toh(notif->status)) {
#ifdef IWM_DEBUG
const char *msg;
if (notif->action & htole32(IWM_TE_V2_NOTIF_HOST_EVENT_START))
@ -195,6 +196,7 @@ iwm_te_handle_notif(struct iwm_softc *sc,
msg = "Time Event end notification failure";
IWM_DPRINTF(sc, IWM_DEBUG_TE, "%s\n", msg);
#endif
}
if (le32toh(notif->action) & IWM_TE_V2_NOTIF_HOST_EVENT_END) {