Commit 4101dec9 authored by Jan Engelhardt's avatar Jan Engelhardt Committed by David S. Miller

net: constify VFTs

Signed-off-by: default avatarJan Engelhardt <jengelh@medozas.de>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 991990a1
...@@ -3369,7 +3369,7 @@ static int bond_info_seq_show(struct seq_file *seq, void *v) ...@@ -3369,7 +3369,7 @@ static int bond_info_seq_show(struct seq_file *seq, void *v)
return 0; return 0;
} }
static struct seq_operations bond_info_seq_ops = { static const struct seq_operations bond_info_seq_ops = {
.start = bond_info_seq_start, .start = bond_info_seq_start,
.next = bond_info_seq_next, .next = bond_info_seq_next,
.stop = bond_info_seq_stop, .stop = bond_info_seq_stop,
......
...@@ -443,7 +443,7 @@ static int bpq_seq_show(struct seq_file *seq, void *v) ...@@ -443,7 +443,7 @@ static int bpq_seq_show(struct seq_file *seq, void *v)
return 0; return 0;
} }
static struct seq_operations bpq_seqops = { static const struct seq_operations bpq_seqops = {
.start = bpq_seq_start, .start = bpq_seq_start,
.next = bpq_seq_next, .next = bpq_seq_next,
.stop = bpq_seq_stop, .stop = bpq_seq_stop,
......
...@@ -2074,7 +2074,7 @@ static int scc_net_seq_show(struct seq_file *seq, void *v) ...@@ -2074,7 +2074,7 @@ static int scc_net_seq_show(struct seq_file *seq, void *v)
return 0; return 0;
} }
static struct seq_operations scc_net_seq_ops = { static const struct seq_operations scc_net_seq_ops = {
.start = scc_net_seq_start, .start = scc_net_seq_start,
.next = scc_net_seq_next, .next = scc_net_seq_next,
.stop = scc_net_seq_stop, .stop = scc_net_seq_stop,
......
...@@ -783,7 +783,7 @@ static int yam_seq_show(struct seq_file *seq, void *v) ...@@ -783,7 +783,7 @@ static int yam_seq_show(struct seq_file *seq, void *v)
return 0; return 0;
} }
static struct seq_operations yam_seqops = { static const struct seq_operations yam_seqops = {
.start = yam_seq_start, .start = yam_seq_start,
.next = yam_seq_next, .next = yam_seq_next,
.stop = yam_seq_stop, .stop = yam_seq_stop,
......
...@@ -1030,7 +1030,7 @@ static void pppoe_seq_stop(struct seq_file *seq, void *v) ...@@ -1030,7 +1030,7 @@ static void pppoe_seq_stop(struct seq_file *seq, void *v)
read_unlock_bh(&pppoe_hash_lock); read_unlock_bh(&pppoe_hash_lock);
} }
static struct seq_operations pppoe_seq_ops = { static const struct seq_operations pppoe_seq_ops = {
.start = pppoe_seq_start, .start = pppoe_seq_start,
.next = pppoe_seq_next, .next = pppoe_seq_next,
.stop = pppoe_seq_stop, .stop = pppoe_seq_stop,
......
...@@ -2517,7 +2517,7 @@ static int pppol2tp_seq_show(struct seq_file *m, void *v) ...@@ -2517,7 +2517,7 @@ static int pppol2tp_seq_show(struct seq_file *m, void *v)
return 0; return 0;
} }
static struct seq_operations pppol2tp_seq_ops = { static const struct seq_operations pppol2tp_seq_ops = {
.start = pppol2tp_seq_start, .start = pppol2tp_seq_start,
.next = pppol2tp_seq_next, .next = pppol2tp_seq_next,
.stop = pppol2tp_seq_stop, .stop = pppol2tp_seq_stop,
...@@ -2565,7 +2565,7 @@ static int pppol2tp_proc_release(struct inode *inode, struct file *file) ...@@ -2565,7 +2565,7 @@ static int pppol2tp_proc_release(struct inode *inode, struct file *file)
return seq_release(inode, file); return seq_release(inode, file);
} }
static struct file_operations pppol2tp_proc_fops = { static const struct file_operations pppol2tp_proc_fops = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.open = pppol2tp_proc_open, .open = pppol2tp_proc_open,
.read = seq_read, .read = seq_read,
......
...@@ -165,7 +165,7 @@ static int reg_show(struct seq_file *seq, void *p) ...@@ -165,7 +165,7 @@ static int reg_show(struct seq_file *seq, void *p)
return 0; return 0;
} }
static struct seq_operations register_seq_ops = { static const struct seq_operations register_seq_ops = {
.start = reg_start, .start = reg_start,
.next = reg_next, .next = reg_next,
.stop = reg_stop, .stop = reg_stop,
......
...@@ -629,7 +629,7 @@ static ssize_t lbs_rdrf_write(struct file *file, ...@@ -629,7 +629,7 @@ static ssize_t lbs_rdrf_write(struct file *file,
res = -EFAULT; res = -EFAULT;
goto out_unlock; goto out_unlock;
} }
priv->rf_offset = simple_strtoul((char *)buf, NULL, 16); priv->rf_offset = simple_strtoul(buf, NULL, 16);
res = count; res = count;
out_unlock: out_unlock:
free_page(addr); free_page(addr);
...@@ -680,12 +680,12 @@ static ssize_t lbs_wrrf_write(struct file *file, ...@@ -680,12 +680,12 @@ static ssize_t lbs_wrrf_write(struct file *file,
} }
struct lbs_debugfs_files { struct lbs_debugfs_files {
char *name; const char *name;
int perm; int perm;
struct file_operations fops; struct file_operations fops;
}; };
static struct lbs_debugfs_files debugfs_files[] = { static const struct lbs_debugfs_files debugfs_files[] = {
{ "info", 0444, FOPS(lbs_dev_info, write_file_dummy), }, { "info", 0444, FOPS(lbs_dev_info, write_file_dummy), },
{ "getscantable", 0444, FOPS(lbs_getscantable, { "getscantable", 0444, FOPS(lbs_getscantable,
write_file_dummy), }, write_file_dummy), },
...@@ -693,7 +693,7 @@ static struct lbs_debugfs_files debugfs_files[] = { ...@@ -693,7 +693,7 @@ static struct lbs_debugfs_files debugfs_files[] = {
lbs_sleepparams_write), }, lbs_sleepparams_write), },
}; };
static struct lbs_debugfs_files debugfs_events_files[] = { static const struct lbs_debugfs_files debugfs_events_files[] = {
{"low_rssi", 0644, FOPS(lbs_lowrssi_read, {"low_rssi", 0644, FOPS(lbs_lowrssi_read,
lbs_lowrssi_write), }, lbs_lowrssi_write), },
{"low_snr", 0644, FOPS(lbs_lowsnr_read, {"low_snr", 0644, FOPS(lbs_lowsnr_read,
...@@ -708,7 +708,7 @@ static struct lbs_debugfs_files debugfs_events_files[] = { ...@@ -708,7 +708,7 @@ static struct lbs_debugfs_files debugfs_events_files[] = {
lbs_highsnr_write), }, lbs_highsnr_write), },
}; };
static struct lbs_debugfs_files debugfs_regs_files[] = { static const struct lbs_debugfs_files debugfs_regs_files[] = {
{"rdmac", 0644, FOPS(lbs_rdmac_read, lbs_rdmac_write), }, {"rdmac", 0644, FOPS(lbs_rdmac_read, lbs_rdmac_write), },
{"wrmac", 0600, FOPS(NULL, lbs_wrmac_write), }, {"wrmac", 0600, FOPS(NULL, lbs_wrmac_write), },
{"rdbbp", 0644, FOPS(lbs_rdbbp_read, lbs_rdbbp_write), }, {"rdbbp", 0644, FOPS(lbs_rdbbp_read, lbs_rdbbp_write), },
...@@ -735,7 +735,7 @@ void lbs_debugfs_remove(void) ...@@ -735,7 +735,7 @@ void lbs_debugfs_remove(void)
void lbs_debugfs_init_one(struct lbs_private *priv, struct net_device *dev) void lbs_debugfs_init_one(struct lbs_private *priv, struct net_device *dev)
{ {
int i; int i;
struct lbs_debugfs_files *files; const struct lbs_debugfs_files *files;
if (!lbs_dir) if (!lbs_dir)
goto exit; goto exit;
...@@ -938,7 +938,7 @@ static ssize_t lbs_debugfs_write(struct file *f, const char __user *buf, ...@@ -938,7 +938,7 @@ static ssize_t lbs_debugfs_write(struct file *f, const char __user *buf,
return (ssize_t)cnt; return (ssize_t)cnt;
} }
static struct file_operations lbs_debug_fops = { static const struct file_operations lbs_debug_fops = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.open = open_file_generic, .open = open_file_generic,
.write = lbs_debugfs_write, .write = lbs_debugfs_write,
......
...@@ -1125,7 +1125,7 @@ static int strip_seq_show(struct seq_file *seq, void *v) ...@@ -1125,7 +1125,7 @@ static int strip_seq_show(struct seq_file *seq, void *v)
} }
static struct seq_operations strip_seq_ops = { static const struct seq_operations strip_seq_ops = {
.start = strip_seq_start, .start = strip_seq_start,
.next = strip_seq_next, .next = strip_seq_next,
.stop = strip_seq_stop, .stop = strip_seq_stop,
......
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