diff options
author | Janusz Dziedzic <janusz.dziedzic@tieto.com> | 2013-10-14 05:06:04 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2013-10-18 14:03:54 -0400 |
commit | d265214b614aac62cdb8baed7ed3d77494cc9bdc (patch) | |
tree | bb67a739092baf61e7cea155e1c53801bb1cce1d /drivers/net/wireless/ath/ath9k/dfs_debug.c | |
parent | 95a5992e43046104ca92c6fb93a80d140d1aa7ce (diff) |
ath9k: dfs move ath_dfs_pool_stats
Move ath_dfs_pool_stats to dfs_pattern_detector
code to be not specyfic only for ath9k.
Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com>
Reviewed-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/dfs_debug.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/dfs_debug.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath/ath9k/dfs_debug.c b/drivers/net/wireless/ath/ath9k/dfs_debug.c index 821599135d8a..990c37630725 100644 --- a/drivers/net/wireless/ath/ath9k/dfs_debug.c +++ b/drivers/net/wireless/ath/ath9k/dfs_debug.c | |||
@@ -20,16 +20,16 @@ | |||
20 | 20 | ||
21 | #include "ath9k.h" | 21 | #include "ath9k.h" |
22 | #include "dfs_debug.h" | 22 | #include "dfs_debug.h" |
23 | #include "dfs_pattern_detector.h" | ||
23 | 24 | ||
24 | 25 | static struct ath_dfs_pool_stats dfs_pool_stats = { 0 }; | |
25 | struct ath_dfs_pool_stats global_dfs_pool_stats = { 0 }; | ||
26 | 26 | ||
27 | #define ATH9K_DFS_STAT(s, p) \ | 27 | #define ATH9K_DFS_STAT(s, p) \ |
28 | len += scnprintf(buf + len, size - len, "%28s : %10u\n", s, \ | 28 | len += scnprintf(buf + len, size - len, "%28s : %10u\n", s, \ |
29 | sc->debug.stats.dfs_stats.p); | 29 | sc->debug.stats.dfs_stats.p); |
30 | #define ATH9K_DFS_POOL_STAT(s, p) \ | 30 | #define ATH9K_DFS_POOL_STAT(s, p) \ |
31 | len += scnprintf(buf + len, size - len, "%28s : %10u\n", s, \ | 31 | len += scnprintf(buf + len, size - len, "%28s : %10u\n", s, \ |
32 | global_dfs_pool_stats.p); | 32 | dfs_pool_stats.p); |
33 | 33 | ||
34 | static ssize_t read_file_dfs(struct file *file, char __user *user_buf, | 34 | static ssize_t read_file_dfs(struct file *file, char __user *user_buf, |
35 | size_t count, loff_t *ppos) | 35 | size_t count, loff_t *ppos) |
@@ -44,6 +44,9 @@ static ssize_t read_file_dfs(struct file *file, char __user *user_buf, | |||
44 | if (buf == NULL) | 44 | if (buf == NULL) |
45 | return -ENOMEM; | 45 | return -ENOMEM; |
46 | 46 | ||
47 | if (sc->dfs_detector) | ||
48 | dfs_pool_stats = sc->dfs_detector->get_stats(sc->dfs_detector); | ||
49 | |||
47 | len += scnprintf(buf + len, size - len, "DFS support for " | 50 | len += scnprintf(buf + len, size - len, "DFS support for " |
48 | "macVersion = 0x%x, macRev = 0x%x: %s\n", | 51 | "macVersion = 0x%x, macRev = 0x%x: %s\n", |
49 | hw_ver->macVersion, hw_ver->macRev, | 52 | hw_ver->macVersion, hw_ver->macRev, |