Commit 7d13cf1e authored by zhong jiang's avatar zhong jiang Committed by Johannes Berg

mac80211_hwsim: use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs fops

It is more clear to use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs file
operation rather than DEFINE_SIMPLE_ATTRIBUTE.

It is detected with the help of coccinelle.
Signed-off-by: default avatarzhong jiang <zhongjiang@huawei.com>
Link: https://lore.kernel.org/r/1572404462-45462-1-git-send-email-zhongjiang@huawei.comSigned-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 3f2aef10
......@@ -769,7 +769,7 @@ static int hwsim_fops_ps_write(void *dat, u64 val)
return 0;
}
DEFINE_SIMPLE_ATTRIBUTE(hwsim_fops_ps, hwsim_fops_ps_read, hwsim_fops_ps_write,
DEFINE_DEBUGFS_ATTRIBUTE(hwsim_fops_ps, hwsim_fops_ps_read, hwsim_fops_ps_write,
"%llu\n");
static int hwsim_write_simulate_radar(void *dat, u64 val)
......@@ -781,7 +781,7 @@ static int hwsim_write_simulate_radar(void *dat, u64 val)
return 0;
}
DEFINE_SIMPLE_ATTRIBUTE(hwsim_simulate_radar, NULL,
DEFINE_DEBUGFS_ATTRIBUTE(hwsim_simulate_radar, NULL,
hwsim_write_simulate_radar, "%llu\n");
static int hwsim_fops_group_read(void *dat, u64 *val)
......@@ -798,7 +798,7 @@ static int hwsim_fops_group_write(void *dat, u64 val)
return 0;
}
DEFINE_SIMPLE_ATTRIBUTE(hwsim_fops_group,
DEFINE_DEBUGFS_ATTRIBUTE(hwsim_fops_group,
hwsim_fops_group_read, hwsim_fops_group_write,
"%llx\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment