hc
2024-10-12 a5969cabbb4660eab42b6ef0412cbbd1200cf14d
kernel/drivers/net/wireless/ath/ath9k/debug.h
....@@ -25,17 +25,17 @@
2525 struct fft_sample_tlv;
2626
2727 #ifdef CONFIG_ATH9K_DEBUGFS
28
-#define TX_STAT_INC(q, c) sc->debug.stats.txstats[q].c++
29
-#define RX_STAT_INC(c) (sc->debug.stats.rxstats.c++)
30
-#define RESET_STAT_INC(sc, type) sc->debug.stats.reset[type]++
31
-#define ANT_STAT_INC(i, c) sc->debug.stats.ant_stats[i].c++
32
-#define ANT_LNA_INC(i, c) sc->debug.stats.ant_stats[i].lna_recv_cnt[c]++;
28
+#define TX_STAT_INC(sc, q, c) do { (sc)->debug.stats.txstats[q].c++; } while (0)
29
+#define RX_STAT_INC(sc, c) do { (sc)->debug.stats.rxstats.c++; } while (0)
30
+#define RESET_STAT_INC(sc, type) do { (sc)->debug.stats.reset[type]++; } while (0)
31
+#define ANT_STAT_INC(sc, i, c) do { (sc)->debug.stats.ant_stats[i].c++; } while (0)
32
+#define ANT_LNA_INC(sc, i, c) do { (sc)->debug.stats.ant_stats[i].lna_recv_cnt[c]++; } while (0)
3333 #else
34
-#define TX_STAT_INC(q, c) do { } while (0)
35
-#define RX_STAT_INC(c)
36
-#define RESET_STAT_INC(sc, type) do { } while (0)
37
-#define ANT_STAT_INC(i, c) do { } while (0)
38
-#define ANT_LNA_INC(i, c) do { } while (0)
34
+#define TX_STAT_INC(sc, q, c) do { (void)(sc); } while (0)
35
+#define RX_STAT_INC(sc, c) do { (void)(sc); } while (0)
36
+#define RESET_STAT_INC(sc, type) do { (void)(sc); } while (0)
37
+#define ANT_STAT_INC(sc, i, c) do { (void)(sc); } while (0)
38
+#define ANT_LNA_INC(sc, i, c) do { (void)(sc); } while (0)
3939 #endif
4040
4141 enum ath_reset_type {
....@@ -319,18 +319,10 @@
319319 void ath_debug_rate_stats(struct ath_softc *sc,
320320 struct ath_rx_status *rs,
321321 struct sk_buff *skb);
322
-void ath_debug_airtime(struct ath_softc *sc,
323
- struct ath_node *an,
324
- u32 rx, u32 tx);
325322 #else
326323 static inline void ath_debug_rate_stats(struct ath_softc *sc,
327324 struct ath_rx_status *rs,
328325 struct sk_buff *skb)
329
-{
330
-}
331
-static inline void ath_debug_airtime(struct ath_softc *sc,
332
- struct ath_node *an,
333
- u32 rx, u32 tx)
334326 {
335327 }
336328 #endif /* CONFIG_ATH9K_STATION_STATISTICS */