aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/debugfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/mac80211/debugfs.c')
-rw-r--r--net/mac80211/debugfs.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/net/mac80211/debugfs.c b/net/mac80211/debugfs.c
index cc5b7a6e7e0..778e5916d7c 100644
--- a/net/mac80211/debugfs.c
+++ b/net/mac80211/debugfs.c
@@ -15,12 +15,6 @@
15#include "rate.h" 15#include "rate.h"
16#include "debugfs.h" 16#include "debugfs.h"
17 17
18int mac80211_open_file_generic(struct inode *inode, struct file *file)
19{
20 file->private_data = inode->i_private;
21 return 0;
22}
23
24#define DEBUGFS_FORMAT_BUFFER_SIZE 100 18#define DEBUGFS_FORMAT_BUFFER_SIZE 100
25 19
26int mac80211_format_buffer(char __user *userbuf, size_t count, 20int mac80211_format_buffer(char __user *userbuf, size_t count,
@@ -50,7 +44,7 @@ static ssize_t name## _read(struct file *file, char __user *userbuf, \
50#define DEBUGFS_READONLY_FILE_OPS(name) \ 44#define DEBUGFS_READONLY_FILE_OPS(name) \
51static const struct file_operations name## _ops = { \ 45static const struct file_operations name## _ops = { \
52 .read = name## _read, \ 46 .read = name## _read, \
53 .open = mac80211_open_file_generic, \ 47 .open = simple_open, \
54 .llseek = generic_file_llseek, \ 48 .llseek = generic_file_llseek, \
55}; 49};
56 50
@@ -93,7 +87,7 @@ static ssize_t reset_write(struct file *file, const char __user *user_buf,
93 87
94static const struct file_operations reset_ops = { 88static const struct file_operations reset_ops = {
95 .write = reset_write, 89 .write = reset_write,
96 .open = mac80211_open_file_generic, 90 .open = simple_open,
97 .llseek = noop_llseek, 91 .llseek = noop_llseek,
98}; 92};
99 93
@@ -254,7 +248,7 @@ static ssize_t stats_ ##name## _read(struct file *file, \
254 \ 248 \
255static const struct file_operations stats_ ##name## _ops = { \ 249static const struct file_operations stats_ ##name## _ops = { \
256 .read = stats_ ##name## _read, \ 250 .read = stats_ ##name## _read, \
257 .open = mac80211_open_file_generic, \ 251 .open = simple_open, \
258 .llseek = generic_file_llseek, \ 252 .llseek = generic_file_llseek, \
259}; 253};
260 254