diff options
Diffstat (limited to 'drivers/net/wireless/iwlwifi')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-rs.c | 11 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-debugfs.c | 12 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-trans-pcie.c | 12 |
3 files changed, 9 insertions, 26 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c index 53f8c51cfcd..7e590b349dd 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c | |||
@@ -3083,11 +3083,6 @@ static void rs_free_sta(void *priv_r, struct ieee80211_sta *sta, | |||
3083 | } | 3083 | } |
3084 | 3084 | ||
3085 | #ifdef CONFIG_MAC80211_DEBUGFS | 3085 | #ifdef CONFIG_MAC80211_DEBUGFS |
3086 | static int open_file_generic(struct inode *inode, struct file *file) | ||
3087 | { | ||
3088 | file->private_data = inode->i_private; | ||
3089 | return 0; | ||
3090 | } | ||
3091 | static void rs_dbgfs_set_mcs(struct iwl_lq_sta *lq_sta, | 3086 | static void rs_dbgfs_set_mcs(struct iwl_lq_sta *lq_sta, |
3092 | u32 *rate_n_flags, int index) | 3087 | u32 *rate_n_flags, int index) |
3093 | { | 3088 | { |
@@ -3226,7 +3221,7 @@ static ssize_t rs_sta_dbgfs_scale_table_read(struct file *file, | |||
3226 | static const struct file_operations rs_sta_dbgfs_scale_table_ops = { | 3221 | static const struct file_operations rs_sta_dbgfs_scale_table_ops = { |
3227 | .write = rs_sta_dbgfs_scale_table_write, | 3222 | .write = rs_sta_dbgfs_scale_table_write, |
3228 | .read = rs_sta_dbgfs_scale_table_read, | 3223 | .read = rs_sta_dbgfs_scale_table_read, |
3229 | .open = open_file_generic, | 3224 | .open = simple_open, |
3230 | .llseek = default_llseek, | 3225 | .llseek = default_llseek, |
3231 | }; | 3226 | }; |
3232 | static ssize_t rs_sta_dbgfs_stats_table_read(struct file *file, | 3227 | static ssize_t rs_sta_dbgfs_stats_table_read(struct file *file, |
@@ -3269,7 +3264,7 @@ static ssize_t rs_sta_dbgfs_stats_table_read(struct file *file, | |||
3269 | 3264 | ||
3270 | static const struct file_operations rs_sta_dbgfs_stats_table_ops = { | 3265 | static const struct file_operations rs_sta_dbgfs_stats_table_ops = { |
3271 | .read = rs_sta_dbgfs_stats_table_read, | 3266 | .read = rs_sta_dbgfs_stats_table_read, |
3272 | .open = open_file_generic, | 3267 | .open = simple_open, |
3273 | .llseek = default_llseek, | 3268 | .llseek = default_llseek, |
3274 | }; | 3269 | }; |
3275 | 3270 | ||
@@ -3295,7 +3290,7 @@ static ssize_t rs_sta_dbgfs_rate_scale_data_read(struct file *file, | |||
3295 | 3290 | ||
3296 | static const struct file_operations rs_sta_dbgfs_rate_scale_data_ops = { | 3291 | static const struct file_operations rs_sta_dbgfs_rate_scale_data_ops = { |
3297 | .read = rs_sta_dbgfs_rate_scale_data_read, | 3292 | .read = rs_sta_dbgfs_rate_scale_data_read, |
3298 | .open = open_file_generic, | 3293 | .open = simple_open, |
3299 | .llseek = default_llseek, | 3294 | .llseek = default_llseek, |
3300 | }; | 3295 | }; |
3301 | 3296 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-debugfs.c b/drivers/net/wireless/iwlwifi/iwl-debugfs.c index b7b1c04f2fb..2bbaebd99ad 100644 --- a/drivers/net/wireless/iwlwifi/iwl-debugfs.c +++ b/drivers/net/wireless/iwlwifi/iwl-debugfs.c | |||
@@ -84,17 +84,11 @@ static ssize_t iwl_dbgfs_##name##_write(struct file *file, \ | |||
84 | size_t count, loff_t *ppos); | 84 | size_t count, loff_t *ppos); |
85 | 85 | ||
86 | 86 | ||
87 | static int iwl_dbgfs_open_file_generic(struct inode *inode, struct file *file) | ||
88 | { | ||
89 | file->private_data = inode->i_private; | ||
90 | return 0; | ||
91 | } | ||
92 | |||
93 | #define DEBUGFS_READ_FILE_OPS(name) \ | 87 | #define DEBUGFS_READ_FILE_OPS(name) \ |
94 | DEBUGFS_READ_FUNC(name); \ | 88 | DEBUGFS_READ_FUNC(name); \ |
95 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ | 89 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ |
96 | .read = iwl_dbgfs_##name##_read, \ | 90 | .read = iwl_dbgfs_##name##_read, \ |
97 | .open = iwl_dbgfs_open_file_generic, \ | 91 | .open = simple_open, \ |
98 | .llseek = generic_file_llseek, \ | 92 | .llseek = generic_file_llseek, \ |
99 | }; | 93 | }; |
100 | 94 | ||
@@ -102,7 +96,7 @@ static const struct file_operations iwl_dbgfs_##name##_ops = { \ | |||
102 | DEBUGFS_WRITE_FUNC(name); \ | 96 | DEBUGFS_WRITE_FUNC(name); \ |
103 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ | 97 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ |
104 | .write = iwl_dbgfs_##name##_write, \ | 98 | .write = iwl_dbgfs_##name##_write, \ |
105 | .open = iwl_dbgfs_open_file_generic, \ | 99 | .open = simple_open, \ |
106 | .llseek = generic_file_llseek, \ | 100 | .llseek = generic_file_llseek, \ |
107 | }; | 101 | }; |
108 | 102 | ||
@@ -113,7 +107,7 @@ static const struct file_operations iwl_dbgfs_##name##_ops = { \ | |||
113 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ | 107 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ |
114 | .write = iwl_dbgfs_##name##_write, \ | 108 | .write = iwl_dbgfs_##name##_write, \ |
115 | .read = iwl_dbgfs_##name##_read, \ | 109 | .read = iwl_dbgfs_##name##_read, \ |
116 | .open = iwl_dbgfs_open_file_generic, \ | 110 | .open = simple_open, \ |
117 | .llseek = generic_file_llseek, \ | 111 | .llseek = generic_file_llseek, \ |
118 | }; | 112 | }; |
119 | 113 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c b/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c index b4f796c82e1..4d7b30d3e64 100644 --- a/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c +++ b/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c | |||
@@ -1898,17 +1898,11 @@ static ssize_t iwl_dbgfs_##name##_write(struct file *file, \ | |||
1898 | size_t count, loff_t *ppos); | 1898 | size_t count, loff_t *ppos); |
1899 | 1899 | ||
1900 | 1900 | ||
1901 | static int iwl_dbgfs_open_file_generic(struct inode *inode, struct file *file) | ||
1902 | { | ||
1903 | file->private_data = inode->i_private; | ||
1904 | return 0; | ||
1905 | } | ||
1906 | |||
1907 | #define DEBUGFS_READ_FILE_OPS(name) \ | 1901 | #define DEBUGFS_READ_FILE_OPS(name) \ |
1908 | DEBUGFS_READ_FUNC(name); \ | 1902 | DEBUGFS_READ_FUNC(name); \ |
1909 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ | 1903 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ |
1910 | .read = iwl_dbgfs_##name##_read, \ | 1904 | .read = iwl_dbgfs_##name##_read, \ |
1911 | .open = iwl_dbgfs_open_file_generic, \ | 1905 | .open = simple_open, \ |
1912 | .llseek = generic_file_llseek, \ | 1906 | .llseek = generic_file_llseek, \ |
1913 | }; | 1907 | }; |
1914 | 1908 | ||
@@ -1916,7 +1910,7 @@ static const struct file_operations iwl_dbgfs_##name##_ops = { \ | |||
1916 | DEBUGFS_WRITE_FUNC(name); \ | 1910 | DEBUGFS_WRITE_FUNC(name); \ |
1917 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ | 1911 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ |
1918 | .write = iwl_dbgfs_##name##_write, \ | 1912 | .write = iwl_dbgfs_##name##_write, \ |
1919 | .open = iwl_dbgfs_open_file_generic, \ | 1913 | .open = simple_open, \ |
1920 | .llseek = generic_file_llseek, \ | 1914 | .llseek = generic_file_llseek, \ |
1921 | }; | 1915 | }; |
1922 | 1916 | ||
@@ -1926,7 +1920,7 @@ static const struct file_operations iwl_dbgfs_##name##_ops = { \ | |||
1926 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ | 1920 | static const struct file_operations iwl_dbgfs_##name##_ops = { \ |
1927 | .write = iwl_dbgfs_##name##_write, \ | 1921 | .write = iwl_dbgfs_##name##_write, \ |
1928 | .read = iwl_dbgfs_##name##_read, \ | 1922 | .read = iwl_dbgfs_##name##_read, \ |
1929 | .open = iwl_dbgfs_open_file_generic, \ | 1923 | .open = simple_open, \ |
1930 | .llseek = generic_file_llseek, \ | 1924 | .llseek = generic_file_llseek, \ |
1931 | }; | 1925 | }; |
1932 | 1926 | ||