diff options
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/debug.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/debug.c | 37 |
1 files changed, 16 insertions, 21 deletions
diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wireless/ath/ath9k/debug.c index 35d1c8e91d1c..ff47b32ecaf4 100644 --- a/drivers/net/wireless/ath/ath9k/debug.c +++ b/drivers/net/wireless/ath/ath9k/debug.c | |||
@@ -26,11 +26,6 @@ | |||
26 | #define REG_READ_D(_ah, _reg) \ | 26 | #define REG_READ_D(_ah, _reg) \ |
27 | ath9k_hw_common(_ah)->ops->read((_ah), (_reg)) | 27 | ath9k_hw_common(_ah)->ops->read((_ah), (_reg)) |
28 | 28 | ||
29 | static int ath9k_debugfs_open(struct inode *inode, struct file *file) | ||
30 | { | ||
31 | file->private_data = inode->i_private; | ||
32 | return 0; | ||
33 | } | ||
34 | 29 | ||
35 | static ssize_t ath9k_debugfs_read_buf(struct file *file, char __user *user_buf, | 30 | static ssize_t ath9k_debugfs_read_buf(struct file *file, char __user *user_buf, |
36 | size_t count, loff_t *ppos) | 31 | size_t count, loff_t *ppos) |
@@ -83,7 +78,7 @@ static ssize_t write_file_debug(struct file *file, const char __user *user_buf, | |||
83 | static const struct file_operations fops_debug = { | 78 | static const struct file_operations fops_debug = { |
84 | .read = read_file_debug, | 79 | .read = read_file_debug, |
85 | .write = write_file_debug, | 80 | .write = write_file_debug, |
86 | .open = ath9k_debugfs_open, | 81 | .open = simple_open, |
87 | .owner = THIS_MODULE, | 82 | .owner = THIS_MODULE, |
88 | .llseek = default_llseek, | 83 | .llseek = default_llseek, |
89 | }; | 84 | }; |
@@ -129,7 +124,7 @@ static ssize_t write_file_tx_chainmask(struct file *file, const char __user *use | |||
129 | static const struct file_operations fops_tx_chainmask = { | 124 | static const struct file_operations fops_tx_chainmask = { |
130 | .read = read_file_tx_chainmask, | 125 | .read = read_file_tx_chainmask, |
131 | .write = write_file_tx_chainmask, | 126 | .write = write_file_tx_chainmask, |
132 | .open = ath9k_debugfs_open, | 127 | .open = simple_open, |
133 | .owner = THIS_MODULE, | 128 | .owner = THIS_MODULE, |
134 | .llseek = default_llseek, | 129 | .llseek = default_llseek, |
135 | }; | 130 | }; |
@@ -172,7 +167,7 @@ static ssize_t write_file_rx_chainmask(struct file *file, const char __user *use | |||
172 | static const struct file_operations fops_rx_chainmask = { | 167 | static const struct file_operations fops_rx_chainmask = { |
173 | .read = read_file_rx_chainmask, | 168 | .read = read_file_rx_chainmask, |
174 | .write = write_file_rx_chainmask, | 169 | .write = write_file_rx_chainmask, |
175 | .open = ath9k_debugfs_open, | 170 | .open = simple_open, |
176 | .owner = THIS_MODULE, | 171 | .owner = THIS_MODULE, |
177 | .llseek = default_llseek, | 172 | .llseek = default_llseek, |
178 | }; | 173 | }; |
@@ -223,7 +218,7 @@ static ssize_t write_file_disable_ani(struct file *file, | |||
223 | static const struct file_operations fops_disable_ani = { | 218 | static const struct file_operations fops_disable_ani = { |
224 | .read = read_file_disable_ani, | 219 | .read = read_file_disable_ani, |
225 | .write = write_file_disable_ani, | 220 | .write = write_file_disable_ani, |
226 | .open = ath9k_debugfs_open, | 221 | .open = simple_open, |
227 | .owner = THIS_MODULE, | 222 | .owner = THIS_MODULE, |
228 | .llseek = default_llseek, | 223 | .llseek = default_llseek, |
229 | }; | 224 | }; |
@@ -324,7 +319,7 @@ static ssize_t read_file_dma(struct file *file, char __user *user_buf, | |||
324 | 319 | ||
325 | static const struct file_operations fops_dma = { | 320 | static const struct file_operations fops_dma = { |
326 | .read = read_file_dma, | 321 | .read = read_file_dma, |
327 | .open = ath9k_debugfs_open, | 322 | .open = simple_open, |
328 | .owner = THIS_MODULE, | 323 | .owner = THIS_MODULE, |
329 | .llseek = default_llseek, | 324 | .llseek = default_llseek, |
330 | }; | 325 | }; |
@@ -446,7 +441,7 @@ static ssize_t read_file_interrupt(struct file *file, char __user *user_buf, | |||
446 | 441 | ||
447 | static const struct file_operations fops_interrupt = { | 442 | static const struct file_operations fops_interrupt = { |
448 | .read = read_file_interrupt, | 443 | .read = read_file_interrupt, |
449 | .open = ath9k_debugfs_open, | 444 | .open = simple_open, |
450 | .owner = THIS_MODULE, | 445 | .owner = THIS_MODULE, |
451 | .llseek = default_llseek, | 446 | .llseek = default_llseek, |
452 | }; | 447 | }; |
@@ -852,28 +847,28 @@ void ath_debug_stat_tx(struct ath_softc *sc, struct ath_buf *bf, | |||
852 | 847 | ||
853 | static const struct file_operations fops_xmit = { | 848 | static const struct file_operations fops_xmit = { |
854 | .read = read_file_xmit, | 849 | .read = read_file_xmit, |
855 | .open = ath9k_debugfs_open, | 850 | .open = simple_open, |
856 | .owner = THIS_MODULE, | 851 | .owner = THIS_MODULE, |
857 | .llseek = default_llseek, | 852 | .llseek = default_llseek, |
858 | }; | 853 | }; |
859 | 854 | ||
860 | static const struct file_operations fops_stations = { | 855 | static const struct file_operations fops_stations = { |
861 | .read = read_file_stations, | 856 | .read = read_file_stations, |
862 | .open = ath9k_debugfs_open, | 857 | .open = simple_open, |
863 | .owner = THIS_MODULE, | 858 | .owner = THIS_MODULE, |
864 | .llseek = default_llseek, | 859 | .llseek = default_llseek, |
865 | }; | 860 | }; |
866 | 861 | ||
867 | static const struct file_operations fops_misc = { | 862 | static const struct file_operations fops_misc = { |
868 | .read = read_file_misc, | 863 | .read = read_file_misc, |
869 | .open = ath9k_debugfs_open, | 864 | .open = simple_open, |
870 | .owner = THIS_MODULE, | 865 | .owner = THIS_MODULE, |
871 | .llseek = default_llseek, | 866 | .llseek = default_llseek, |
872 | }; | 867 | }; |
873 | 868 | ||
874 | static const struct file_operations fops_reset = { | 869 | static const struct file_operations fops_reset = { |
875 | .read = read_file_reset, | 870 | .read = read_file_reset, |
876 | .open = ath9k_debugfs_open, | 871 | .open = simple_open, |
877 | .owner = THIS_MODULE, | 872 | .owner = THIS_MODULE, |
878 | .llseek = default_llseek, | 873 | .llseek = default_llseek, |
879 | }; | 874 | }; |
@@ -1016,7 +1011,7 @@ void ath_debug_stat_rx(struct ath_softc *sc, struct ath_rx_status *rs) | |||
1016 | 1011 | ||
1017 | static const struct file_operations fops_recv = { | 1012 | static const struct file_operations fops_recv = { |
1018 | .read = read_file_recv, | 1013 | .read = read_file_recv, |
1019 | .open = ath9k_debugfs_open, | 1014 | .open = simple_open, |
1020 | .owner = THIS_MODULE, | 1015 | .owner = THIS_MODULE, |
1021 | .llseek = default_llseek, | 1016 | .llseek = default_llseek, |
1022 | }; | 1017 | }; |
@@ -1055,7 +1050,7 @@ static ssize_t write_file_regidx(struct file *file, const char __user *user_buf, | |||
1055 | static const struct file_operations fops_regidx = { | 1050 | static const struct file_operations fops_regidx = { |
1056 | .read = read_file_regidx, | 1051 | .read = read_file_regidx, |
1057 | .write = write_file_regidx, | 1052 | .write = write_file_regidx, |
1058 | .open = ath9k_debugfs_open, | 1053 | .open = simple_open, |
1059 | .owner = THIS_MODULE, | 1054 | .owner = THIS_MODULE, |
1060 | .llseek = default_llseek, | 1055 | .llseek = default_llseek, |
1061 | }; | 1056 | }; |
@@ -1102,7 +1097,7 @@ static ssize_t write_file_regval(struct file *file, const char __user *user_buf, | |||
1102 | static const struct file_operations fops_regval = { | 1097 | static const struct file_operations fops_regval = { |
1103 | .read = read_file_regval, | 1098 | .read = read_file_regval, |
1104 | .write = write_file_regval, | 1099 | .write = write_file_regval, |
1105 | .open = ath9k_debugfs_open, | 1100 | .open = simple_open, |
1106 | .owner = THIS_MODULE, | 1101 | .owner = THIS_MODULE, |
1107 | .llseek = default_llseek, | 1102 | .llseek = default_llseek, |
1108 | }; | 1103 | }; |
@@ -1191,7 +1186,7 @@ static ssize_t read_file_dump_nfcal(struct file *file, char __user *user_buf, | |||
1191 | 1186 | ||
1192 | static const struct file_operations fops_dump_nfcal = { | 1187 | static const struct file_operations fops_dump_nfcal = { |
1193 | .read = read_file_dump_nfcal, | 1188 | .read = read_file_dump_nfcal, |
1194 | .open = ath9k_debugfs_open, | 1189 | .open = simple_open, |
1195 | .owner = THIS_MODULE, | 1190 | .owner = THIS_MODULE, |
1196 | .llseek = default_llseek, | 1191 | .llseek = default_llseek, |
1197 | }; | 1192 | }; |
@@ -1219,7 +1214,7 @@ static ssize_t read_file_base_eeprom(struct file *file, char __user *user_buf, | |||
1219 | 1214 | ||
1220 | static const struct file_operations fops_base_eeprom = { | 1215 | static const struct file_operations fops_base_eeprom = { |
1221 | .read = read_file_base_eeprom, | 1216 | .read = read_file_base_eeprom, |
1222 | .open = ath9k_debugfs_open, | 1217 | .open = simple_open, |
1223 | .owner = THIS_MODULE, | 1218 | .owner = THIS_MODULE, |
1224 | .llseek = default_llseek, | 1219 | .llseek = default_llseek, |
1225 | }; | 1220 | }; |
@@ -1247,7 +1242,7 @@ static ssize_t read_file_modal_eeprom(struct file *file, char __user *user_buf, | |||
1247 | 1242 | ||
1248 | static const struct file_operations fops_modal_eeprom = { | 1243 | static const struct file_operations fops_modal_eeprom = { |
1249 | .read = read_file_modal_eeprom, | 1244 | .read = read_file_modal_eeprom, |
1250 | .open = ath9k_debugfs_open, | 1245 | .open = simple_open, |
1251 | .owner = THIS_MODULE, | 1246 | .owner = THIS_MODULE, |
1252 | .llseek = default_llseek, | 1247 | .llseek = default_llseek, |
1253 | }; | 1248 | }; |