diff options
author | Sujith <Sujith.Manoharan@atheros.com> | 2009-02-09 02:57:03 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-02-13 13:44:58 -0500 |
commit | 17d7904de85125c62c7258d7cb21207f26d04048 (patch) | |
tree | 298d52125b29534c6dfcf79d6eb643c2261e82df /drivers/net/wireless/ath9k/debug.c | |
parent | ee6e8d1c234e62e503f2dd8137643b24cf424886 (diff) |
ath9k: Remove all the sc_ prefixes
This patch removes the useless sc_ prefixes for all variables.
Also, refer to interfaces as VIFs and not as VAPs anymore.
Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath9k/debug.c')
-rw-r--r-- | drivers/net/wireless/ath9k/debug.c | 130 |
1 files changed, 65 insertions, 65 deletions
diff --git a/drivers/net/wireless/ath9k/debug.c b/drivers/net/wireless/ath9k/debug.c index c9b47b351504..daca5ce91452 100644 --- a/drivers/net/wireless/ath9k/debug.c +++ b/drivers/net/wireless/ath9k/debug.c | |||
@@ -24,7 +24,7 @@ void DPRINTF(struct ath_softc *sc, int dbg_mask, const char *fmt, ...) | |||
24 | if (!sc) | 24 | if (!sc) |
25 | return; | 25 | return; |
26 | 26 | ||
27 | if (sc->sc_debug.debug_mask & dbg_mask) { | 27 | if (sc->debug.debug_mask & dbg_mask) { |
28 | va_list args; | 28 | va_list args; |
29 | 29 | ||
30 | va_start(args, fmt); | 30 | va_start(args, fmt); |
@@ -130,41 +130,41 @@ static const struct file_operations fops_dma = { | |||
130 | void ath_debug_stat_interrupt(struct ath_softc *sc, enum ath9k_int status) | 130 | void ath_debug_stat_interrupt(struct ath_softc *sc, enum ath9k_int status) |
131 | { | 131 | { |
132 | if (status) | 132 | if (status) |
133 | sc->sc_debug.stats.istats.total++; | 133 | sc->debug.stats.istats.total++; |
134 | if (status & ATH9K_INT_RX) | 134 | if (status & ATH9K_INT_RX) |
135 | sc->sc_debug.stats.istats.rxok++; | 135 | sc->debug.stats.istats.rxok++; |
136 | if (status & ATH9K_INT_RXEOL) | 136 | if (status & ATH9K_INT_RXEOL) |
137 | sc->sc_debug.stats.istats.rxeol++; | 137 | sc->debug.stats.istats.rxeol++; |
138 | if (status & ATH9K_INT_RXORN) | 138 | if (status & ATH9K_INT_RXORN) |
139 | sc->sc_debug.stats.istats.rxorn++; | 139 | sc->debug.stats.istats.rxorn++; |
140 | if (status & ATH9K_INT_TX) | 140 | if (status & ATH9K_INT_TX) |
141 | sc->sc_debug.stats.istats.txok++; | 141 | sc->debug.stats.istats.txok++; |
142 | if (status & ATH9K_INT_TXURN) | 142 | if (status & ATH9K_INT_TXURN) |
143 | sc->sc_debug.stats.istats.txurn++; | 143 | sc->debug.stats.istats.txurn++; |
144 | if (status & ATH9K_INT_MIB) | 144 | if (status & ATH9K_INT_MIB) |
145 | sc->sc_debug.stats.istats.mib++; | 145 | sc->debug.stats.istats.mib++; |
146 | if (status & ATH9K_INT_RXPHY) | 146 | if (status & ATH9K_INT_RXPHY) |
147 | sc->sc_debug.stats.istats.rxphyerr++; | 147 | sc->debug.stats.istats.rxphyerr++; |
148 | if (status & ATH9K_INT_RXKCM) | 148 | if (status & ATH9K_INT_RXKCM) |
149 | sc->sc_debug.stats.istats.rx_keycache_miss++; | 149 | sc->debug.stats.istats.rx_keycache_miss++; |
150 | if (status & ATH9K_INT_SWBA) | 150 | if (status & ATH9K_INT_SWBA) |
151 | sc->sc_debug.stats.istats.swba++; | 151 | sc->debug.stats.istats.swba++; |
152 | if (status & ATH9K_INT_BMISS) | 152 | if (status & ATH9K_INT_BMISS) |
153 | sc->sc_debug.stats.istats.bmiss++; | 153 | sc->debug.stats.istats.bmiss++; |
154 | if (status & ATH9K_INT_BNR) | 154 | if (status & ATH9K_INT_BNR) |
155 | sc->sc_debug.stats.istats.bnr++; | 155 | sc->debug.stats.istats.bnr++; |
156 | if (status & ATH9K_INT_CST) | 156 | if (status & ATH9K_INT_CST) |
157 | sc->sc_debug.stats.istats.cst++; | 157 | sc->debug.stats.istats.cst++; |
158 | if (status & ATH9K_INT_GTT) | 158 | if (status & ATH9K_INT_GTT) |
159 | sc->sc_debug.stats.istats.gtt++; | 159 | sc->debug.stats.istats.gtt++; |
160 | if (status & ATH9K_INT_TIM) | 160 | if (status & ATH9K_INT_TIM) |
161 | sc->sc_debug.stats.istats.tim++; | 161 | sc->debug.stats.istats.tim++; |
162 | if (status & ATH9K_INT_CABEND) | 162 | if (status & ATH9K_INT_CABEND) |
163 | sc->sc_debug.stats.istats.cabend++; | 163 | sc->debug.stats.istats.cabend++; |
164 | if (status & ATH9K_INT_DTIMSYNC) | 164 | if (status & ATH9K_INT_DTIMSYNC) |
165 | sc->sc_debug.stats.istats.dtimsync++; | 165 | sc->debug.stats.istats.dtimsync++; |
166 | if (status & ATH9K_INT_DTIM) | 166 | if (status & ATH9K_INT_DTIM) |
167 | sc->sc_debug.stats.istats.dtim++; | 167 | sc->debug.stats.istats.dtim++; |
168 | } | 168 | } |
169 | 169 | ||
170 | static ssize_t read_file_interrupt(struct file *file, char __user *user_buf, | 170 | static ssize_t read_file_interrupt(struct file *file, char __user *user_buf, |
@@ -175,41 +175,41 @@ static ssize_t read_file_interrupt(struct file *file, char __user *user_buf, | |||
175 | unsigned int len = 0; | 175 | unsigned int len = 0; |
176 | 176 | ||
177 | len += snprintf(buf + len, sizeof(buf) - len, | 177 | len += snprintf(buf + len, sizeof(buf) - len, |
178 | "%8s: %10u\n", "RX", sc->sc_debug.stats.istats.rxok); | 178 | "%8s: %10u\n", "RX", sc->debug.stats.istats.rxok); |
179 | len += snprintf(buf + len, sizeof(buf) - len, | 179 | len += snprintf(buf + len, sizeof(buf) - len, |
180 | "%8s: %10u\n", "RXEOL", sc->sc_debug.stats.istats.rxeol); | 180 | "%8s: %10u\n", "RXEOL", sc->debug.stats.istats.rxeol); |
181 | len += snprintf(buf + len, sizeof(buf) - len, | 181 | len += snprintf(buf + len, sizeof(buf) - len, |
182 | "%8s: %10u\n", "RXORN", sc->sc_debug.stats.istats.rxorn); | 182 | "%8s: %10u\n", "RXORN", sc->debug.stats.istats.rxorn); |
183 | len += snprintf(buf + len, sizeof(buf) - len, | 183 | len += snprintf(buf + len, sizeof(buf) - len, |
184 | "%8s: %10u\n", "TX", sc->sc_debug.stats.istats.txok); | 184 | "%8s: %10u\n", "TX", sc->debug.stats.istats.txok); |
185 | len += snprintf(buf + len, sizeof(buf) - len, | 185 | len += snprintf(buf + len, sizeof(buf) - len, |
186 | "%8s: %10u\n", "TXURN", sc->sc_debug.stats.istats.txurn); | 186 | "%8s: %10u\n", "TXURN", sc->debug.stats.istats.txurn); |
187 | len += snprintf(buf + len, sizeof(buf) - len, | 187 | len += snprintf(buf + len, sizeof(buf) - len, |
188 | "%8s: %10u\n", "MIB", sc->sc_debug.stats.istats.mib); | 188 | "%8s: %10u\n", "MIB", sc->debug.stats.istats.mib); |
189 | len += snprintf(buf + len, sizeof(buf) - len, | 189 | len += snprintf(buf + len, sizeof(buf) - len, |
190 | "%8s: %10u\n", "RXPHY", sc->sc_debug.stats.istats.rxphyerr); | 190 | "%8s: %10u\n", "RXPHY", sc->debug.stats.istats.rxphyerr); |
191 | len += snprintf(buf + len, sizeof(buf) - len, | 191 | len += snprintf(buf + len, sizeof(buf) - len, |
192 | "%8s: %10u\n", "RXKCM", sc->sc_debug.stats.istats.rx_keycache_miss); | 192 | "%8s: %10u\n", "RXKCM", sc->debug.stats.istats.rx_keycache_miss); |
193 | len += snprintf(buf + len, sizeof(buf) - len, | 193 | len += snprintf(buf + len, sizeof(buf) - len, |
194 | "%8s: %10u\n", "SWBA", sc->sc_debug.stats.istats.swba); | 194 | "%8s: %10u\n", "SWBA", sc->debug.stats.istats.swba); |
195 | len += snprintf(buf + len, sizeof(buf) - len, | 195 | len += snprintf(buf + len, sizeof(buf) - len, |
196 | "%8s: %10u\n", "BMISS", sc->sc_debug.stats.istats.bmiss); | 196 | "%8s: %10u\n", "BMISS", sc->debug.stats.istats.bmiss); |
197 | len += snprintf(buf + len, sizeof(buf) - len, | 197 | len += snprintf(buf + len, sizeof(buf) - len, |
198 | "%8s: %10u\n", "BNR", sc->sc_debug.stats.istats.bnr); | 198 | "%8s: %10u\n", "BNR", sc->debug.stats.istats.bnr); |
199 | len += snprintf(buf + len, sizeof(buf) - len, | 199 | len += snprintf(buf + len, sizeof(buf) - len, |
200 | "%8s: %10u\n", "CST", sc->sc_debug.stats.istats.cst); | 200 | "%8s: %10u\n", "CST", sc->debug.stats.istats.cst); |
201 | len += snprintf(buf + len, sizeof(buf) - len, | 201 | len += snprintf(buf + len, sizeof(buf) - len, |
202 | "%8s: %10u\n", "GTT", sc->sc_debug.stats.istats.gtt); | 202 | "%8s: %10u\n", "GTT", sc->debug.stats.istats.gtt); |
203 | len += snprintf(buf + len, sizeof(buf) - len, | 203 | len += snprintf(buf + len, sizeof(buf) - len, |
204 | "%8s: %10u\n", "TIM", sc->sc_debug.stats.istats.tim); | 204 | "%8s: %10u\n", "TIM", sc->debug.stats.istats.tim); |
205 | len += snprintf(buf + len, sizeof(buf) - len, | 205 | len += snprintf(buf + len, sizeof(buf) - len, |
206 | "%8s: %10u\n", "CABEND", sc->sc_debug.stats.istats.cabend); | 206 | "%8s: %10u\n", "CABEND", sc->debug.stats.istats.cabend); |
207 | len += snprintf(buf + len, sizeof(buf) - len, | 207 | len += snprintf(buf + len, sizeof(buf) - len, |
208 | "%8s: %10u\n", "DTIMSYNC", sc->sc_debug.stats.istats.dtimsync); | 208 | "%8s: %10u\n", "DTIMSYNC", sc->debug.stats.istats.dtimsync); |
209 | len += snprintf(buf + len, sizeof(buf) - len, | 209 | len += snprintf(buf + len, sizeof(buf) - len, |
210 | "%8s: %10u\n", "DTIM", sc->sc_debug.stats.istats.dtim); | 210 | "%8s: %10u\n", "DTIM", sc->debug.stats.istats.dtim); |
211 | len += snprintf(buf + len, sizeof(buf) - len, | 211 | len += snprintf(buf + len, sizeof(buf) - len, |
212 | "%8s: %10u\n", "TOTAL", sc->sc_debug.stats.istats.total); | 212 | "%8s: %10u\n", "TOTAL", sc->debug.stats.istats.total); |
213 | 213 | ||
214 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); | 214 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); |
215 | } | 215 | } |
@@ -231,7 +231,7 @@ static void ath_debug_stat_11n_rc(struct ath_softc *sc, struct sk_buff *skb) | |||
231 | final_ts_idx = tx_info_priv->tx.ts_rateindex; | 231 | final_ts_idx = tx_info_priv->tx.ts_rateindex; |
232 | idx = sc->cur_rate_table->info[rates[final_ts_idx].idx].dot11rate; | 232 | idx = sc->cur_rate_table->info[rates[final_ts_idx].idx].dot11rate; |
233 | 233 | ||
234 | sc->sc_debug.stats.n_rcstats[idx].success++; | 234 | sc->debug.stats.n_rcstats[idx].success++; |
235 | } | 235 | } |
236 | 236 | ||
237 | static void ath_debug_stat_legacy_rc(struct ath_softc *sc, struct sk_buff *skb) | 237 | static void ath_debug_stat_legacy_rc(struct ath_softc *sc, struct sk_buff *skb) |
@@ -245,7 +245,7 @@ static void ath_debug_stat_legacy_rc(struct ath_softc *sc, struct sk_buff *skb) | |||
245 | final_ts_idx = tx_info_priv->tx.ts_rateindex; | 245 | final_ts_idx = tx_info_priv->tx.ts_rateindex; |
246 | idx = rates[final_ts_idx].idx; | 246 | idx = rates[final_ts_idx].idx; |
247 | 247 | ||
248 | sc->sc_debug.stats.legacy_rcstats[idx].success++; | 248 | sc->debug.stats.legacy_rcstats[idx].success++; |
249 | } | 249 | } |
250 | 250 | ||
251 | void ath_debug_stat_rc(struct ath_softc *sc, struct sk_buff *skb) | 251 | void ath_debug_stat_rc(struct ath_softc *sc, struct sk_buff *skb) |
@@ -263,8 +263,8 @@ void ath_debug_stat_retries(struct ath_softc *sc, int rix, | |||
263 | if (conf_is_ht(&sc->hw->conf)) { | 263 | if (conf_is_ht(&sc->hw->conf)) { |
264 | int idx = sc->cur_rate_table->info[rix].dot11rate; | 264 | int idx = sc->cur_rate_table->info[rix].dot11rate; |
265 | 265 | ||
266 | sc->sc_debug.stats.n_rcstats[idx].xretries += xretries; | 266 | sc->debug.stats.n_rcstats[idx].xretries += xretries; |
267 | sc->sc_debug.stats.n_rcstats[idx].retries += retries; | 267 | sc->debug.stats.n_rcstats[idx].retries += retries; |
268 | } | 268 | } |
269 | } | 269 | } |
270 | 270 | ||
@@ -283,9 +283,9 @@ static ssize_t ath_read_file_stat_11n_rc(struct file *file, | |||
283 | for (i = 0; i <= 15; i++) { | 283 | for (i = 0; i <= 15; i++) { |
284 | len += snprintf(buf + len, sizeof(buf) - len, | 284 | len += snprintf(buf + len, sizeof(buf) - len, |
285 | "%5s%3d: %8u %8u %8u\n", "MCS", i, | 285 | "%5s%3d: %8u %8u %8u\n", "MCS", i, |
286 | sc->sc_debug.stats.n_rcstats[i].success, | 286 | sc->debug.stats.n_rcstats[i].success, |
287 | sc->sc_debug.stats.n_rcstats[i].retries, | 287 | sc->debug.stats.n_rcstats[i].retries, |
288 | sc->sc_debug.stats.n_rcstats[i].xretries); | 288 | sc->debug.stats.n_rcstats[i].xretries); |
289 | } | 289 | } |
290 | 290 | ||
291 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); | 291 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); |
@@ -305,7 +305,7 @@ static ssize_t ath_read_file_stat_legacy_rc(struct file *file, | |||
305 | for (i = 0; i < sc->cur_rate_table->rate_cnt; i++) { | 305 | for (i = 0; i < sc->cur_rate_table->rate_cnt; i++) { |
306 | len += snprintf(buf + len, sizeof(buf) - len, "%5u: %12u\n", | 306 | len += snprintf(buf + len, sizeof(buf) - len, "%5u: %12u\n", |
307 | sc->cur_rate_table->info[i].ratekbps / 1000, | 307 | sc->cur_rate_table->info[i].ratekbps / 1000, |
308 | sc->sc_debug.stats.legacy_rcstats[i].success); | 308 | sc->debug.stats.legacy_rcstats[i].success); |
309 | } | 309 | } |
310 | 310 | ||
311 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); | 311 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); |
@@ -330,34 +330,34 @@ static const struct file_operations fops_rcstat = { | |||
330 | 330 | ||
331 | int ath9k_init_debug(struct ath_softc *sc) | 331 | int ath9k_init_debug(struct ath_softc *sc) |
332 | { | 332 | { |
333 | sc->sc_debug.debug_mask = ath9k_debug; | 333 | sc->debug.debug_mask = ath9k_debug; |
334 | 334 | ||
335 | sc->sc_debug.debugfs_root = debugfs_create_dir(KBUILD_MODNAME, NULL); | 335 | sc->debug.debugfs_root = debugfs_create_dir(KBUILD_MODNAME, NULL); |
336 | if (!sc->sc_debug.debugfs_root) | 336 | if (!sc->debug.debugfs_root) |
337 | goto err; | 337 | goto err; |
338 | 338 | ||
339 | sc->sc_debug.debugfs_phy = debugfs_create_dir(wiphy_name(sc->hw->wiphy), | 339 | sc->debug.debugfs_phy = debugfs_create_dir(wiphy_name(sc->hw->wiphy), |
340 | sc->sc_debug.debugfs_root); | 340 | sc->debug.debugfs_root); |
341 | if (!sc->sc_debug.debugfs_phy) | 341 | if (!sc->debug.debugfs_phy) |
342 | goto err; | 342 | goto err; |
343 | 343 | ||
344 | sc->sc_debug.debugfs_dma = debugfs_create_file("dma", S_IRUGO, | 344 | sc->debug.debugfs_dma = debugfs_create_file("dma", S_IRUGO, |
345 | sc->sc_debug.debugfs_phy, sc, &fops_dma); | 345 | sc->debug.debugfs_phy, sc, &fops_dma); |
346 | if (!sc->sc_debug.debugfs_dma) | 346 | if (!sc->debug.debugfs_dma) |
347 | goto err; | 347 | goto err; |
348 | 348 | ||
349 | sc->sc_debug.debugfs_interrupt = debugfs_create_file("interrupt", | 349 | sc->debug.debugfs_interrupt = debugfs_create_file("interrupt", |
350 | S_IRUGO, | 350 | S_IRUGO, |
351 | sc->sc_debug.debugfs_phy, | 351 | sc->debug.debugfs_phy, |
352 | sc, &fops_interrupt); | 352 | sc, &fops_interrupt); |
353 | if (!sc->sc_debug.debugfs_interrupt) | 353 | if (!sc->debug.debugfs_interrupt) |
354 | goto err; | 354 | goto err; |
355 | 355 | ||
356 | sc->sc_debug.debugfs_rcstat = debugfs_create_file("rcstat", | 356 | sc->debug.debugfs_rcstat = debugfs_create_file("rcstat", |
357 | S_IRUGO, | 357 | S_IRUGO, |
358 | sc->sc_debug.debugfs_phy, | 358 | sc->debug.debugfs_phy, |
359 | sc, &fops_rcstat); | 359 | sc, &fops_rcstat); |
360 | if (!sc->sc_debug.debugfs_rcstat) | 360 | if (!sc->debug.debugfs_rcstat) |
361 | goto err; | 361 | goto err; |
362 | 362 | ||
363 | return 0; | 363 | return 0; |
@@ -368,9 +368,9 @@ err: | |||
368 | 368 | ||
369 | void ath9k_exit_debug(struct ath_softc *sc) | 369 | void ath9k_exit_debug(struct ath_softc *sc) |
370 | { | 370 | { |
371 | debugfs_remove(sc->sc_debug.debugfs_rcstat); | 371 | debugfs_remove(sc->debug.debugfs_rcstat); |
372 | debugfs_remove(sc->sc_debug.debugfs_interrupt); | 372 | debugfs_remove(sc->debug.debugfs_interrupt); |
373 | debugfs_remove(sc->sc_debug.debugfs_dma); | 373 | debugfs_remove(sc->debug.debugfs_dma); |
374 | debugfs_remove(sc->sc_debug.debugfs_phy); | 374 | debugfs_remove(sc->debug.debugfs_phy); |
375 | debugfs_remove(sc->sc_debug.debugfs_root); | 375 | debugfs_remove(sc->debug.debugfs_root); |
376 | } | 376 | } |