aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/netdevice.h
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2008-09-30 05:22:14 -0400
committerDavid S. Miller <davem@davemloft.net>2008-09-30 05:22:14 -0400
commitcf04a4c764cd3e651a64b3e667bb6a673ead99e1 (patch)
tree61fc379e33ca08e68326b9f76577fd2a57435034 /include/linux/netdevice.h
parentdb4148da2cc84c31419b5e3ae3115ac6e11817a1 (diff)
netdev: use const for some name functions
dev_change_name and netdev_drivername should use const char on parameters that are read-only input values. The strcpy to newname is not needed since newname is not used later in function. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/netdevice.h')
-rw-r--r--include/linux/netdevice.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index d675df08b946..9cfd20be8b7f 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -1225,7 +1225,7 @@ extern int dev_ioctl(struct net *net, unsigned int cmd, void __user *);
1225extern int dev_ethtool(struct net *net, struct ifreq *); 1225extern int dev_ethtool(struct net *net, struct ifreq *);
1226extern unsigned dev_get_flags(const struct net_device *); 1226extern unsigned dev_get_flags(const struct net_device *);
1227extern int dev_change_flags(struct net_device *, unsigned); 1227extern int dev_change_flags(struct net_device *, unsigned);
1228extern int dev_change_name(struct net_device *, char *); 1228extern int dev_change_name(struct net_device *, const char *);
1229extern int dev_set_alias(struct net_device *, const char *, size_t); 1229extern int dev_set_alias(struct net_device *, const char *, size_t);
1230extern int dev_change_net_namespace(struct net_device *, 1230extern int dev_change_net_namespace(struct net_device *,
1231 struct net *, const char *); 1231 struct net *, const char *);
@@ -1670,7 +1670,7 @@ extern void dev_seq_stop(struct seq_file *seq, void *v);
1670extern int netdev_class_create_file(struct class_attribute *class_attr); 1670extern int netdev_class_create_file(struct class_attribute *class_attr);
1671extern void netdev_class_remove_file(struct class_attribute *class_attr); 1671extern void netdev_class_remove_file(struct class_attribute *class_attr);
1672 1672
1673extern char *netdev_drivername(struct net_device *dev, char *buffer, int len); 1673extern char *netdev_drivername(const struct net_device *dev, char *buffer, int len);
1674 1674
1675extern void linkwatch_run_queue(void); 1675extern void linkwatch_run_queue(void);
1676 1676