aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/netdevice.h
diff options
context:
space:
mode:
authorstephen hemminger <shemminger@vyatta.com>2012-09-17 06:03:26 -0400
committerDavid S. Miller <davem@davemloft.net>2012-09-19 16:35:22 -0400
commit6b6e27255f29a6191ef8ad96bfcc392ab2ef6c71 (patch)
treea5ccefbbb2862f3777b83eefd1d10a2f550345f8 /include/linux/netdevice.h
parent1d3ff76759b70e201e6b379c37ac106c487ff506 (diff)
netdev: make address const in device address management
The internal functions for add/deleting addresses don't change their argument. 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.h28
1 files changed, 14 insertions, 14 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index ae3153c0db0a..82264e717e53 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -907,10 +907,10 @@ struct netdev_fcoe_hbainfo {
907 * Must return >0 or -errno if it changed dev->features itself. 907 * Must return >0 or -errno if it changed dev->features itself.
908 * 908 *
909 * int (*ndo_fdb_add)(struct ndmsg *ndm, struct net_device *dev, 909 * int (*ndo_fdb_add)(struct ndmsg *ndm, struct net_device *dev,
910 * unsigned char *addr, u16 flags) 910 * const unsigned char *addr, u16 flags)
911 * Adds an FDB entry to dev for addr. 911 * Adds an FDB entry to dev for addr.
912 * int (*ndo_fdb_del)(struct ndmsg *ndm, struct net_device *dev, 912 * int (*ndo_fdb_del)(struct ndmsg *ndm, struct net_device *dev,
913 * unsigned char *addr) 913 * const unsigned char *addr)
914 * Deletes the FDB entry from dev coresponding to addr. 914 * Deletes the FDB entry from dev coresponding to addr.
915 * int (*ndo_fdb_dump)(struct sk_buff *skb, struct netlink_callback *cb, 915 * int (*ndo_fdb_dump)(struct sk_buff *skb, struct netlink_callback *cb,
916 * struct net_device *dev, int idx) 916 * struct net_device *dev, int idx)
@@ -1017,11 +1017,11 @@ struct net_device_ops {
1017 1017
1018 int (*ndo_fdb_add)(struct ndmsg *ndm, 1018 int (*ndo_fdb_add)(struct ndmsg *ndm,
1019 struct net_device *dev, 1019 struct net_device *dev,
1020 unsigned char *addr, 1020 const unsigned char *addr,
1021 u16 flags); 1021 u16 flags);
1022 int (*ndo_fdb_del)(struct ndmsg *ndm, 1022 int (*ndo_fdb_del)(struct ndmsg *ndm,
1023 struct net_device *dev, 1023 struct net_device *dev,
1024 unsigned char *addr); 1024 const unsigned char *addr);
1025 int (*ndo_fdb_dump)(struct sk_buff *skb, 1025 int (*ndo_fdb_dump)(struct sk_buff *skb,
1026 struct netlink_callback *cb, 1026 struct netlink_callback *cb,
1027 struct net_device *dev, 1027 struct net_device *dev,
@@ -2561,9 +2561,9 @@ extern void __hw_addr_flush(struct netdev_hw_addr_list *list);
2561extern void __hw_addr_init(struct netdev_hw_addr_list *list); 2561extern void __hw_addr_init(struct netdev_hw_addr_list *list);
2562 2562
2563/* Functions used for device addresses handling */ 2563/* Functions used for device addresses handling */
2564extern int dev_addr_add(struct net_device *dev, unsigned char *addr, 2564extern int dev_addr_add(struct net_device *dev, const unsigned char *addr,
2565 unsigned char addr_type); 2565 unsigned char addr_type);
2566extern int dev_addr_del(struct net_device *dev, unsigned char *addr, 2566extern int dev_addr_del(struct net_device *dev, const unsigned char *addr,
2567 unsigned char addr_type); 2567 unsigned char addr_type);
2568extern int dev_addr_add_multiple(struct net_device *to_dev, 2568extern int dev_addr_add_multiple(struct net_device *to_dev,
2569 struct net_device *from_dev, 2569 struct net_device *from_dev,
@@ -2575,20 +2575,20 @@ extern void dev_addr_flush(struct net_device *dev);
2575extern int dev_addr_init(struct net_device *dev); 2575extern int dev_addr_init(struct net_device *dev);
2576 2576
2577/* Functions used for unicast addresses handling */ 2577/* Functions used for unicast addresses handling */
2578extern int dev_uc_add(struct net_device *dev, unsigned char *addr); 2578extern int dev_uc_add(struct net_device *dev, const unsigned char *addr);
2579extern int dev_uc_add_excl(struct net_device *dev, unsigned char *addr); 2579extern int dev_uc_add_excl(struct net_device *dev, const unsigned char *addr);
2580extern int dev_uc_del(struct net_device *dev, unsigned char *addr); 2580extern int dev_uc_del(struct net_device *dev, const unsigned char *addr);
2581extern int dev_uc_sync(struct net_device *to, struct net_device *from); 2581extern int dev_uc_sync(struct net_device *to, struct net_device *from);
2582extern void dev_uc_unsync(struct net_device *to, struct net_device *from); 2582extern void dev_uc_unsync(struct net_device *to, struct net_device *from);
2583extern void dev_uc_flush(struct net_device *dev); 2583extern void dev_uc_flush(struct net_device *dev);
2584extern void dev_uc_init(struct net_device *dev); 2584extern void dev_uc_init(struct net_device *dev);
2585 2585
2586/* Functions used for multicast addresses handling */ 2586/* Functions used for multicast addresses handling */
2587extern int dev_mc_add(struct net_device *dev, unsigned char *addr); 2587extern int dev_mc_add(struct net_device *dev, const unsigned char *addr);
2588extern int dev_mc_add_global(struct net_device *dev, unsigned char *addr); 2588extern int dev_mc_add_global(struct net_device *dev, const unsigned char *addr);
2589extern int dev_mc_add_excl(struct net_device *dev, unsigned char *addr); 2589extern int dev_mc_add_excl(struct net_device *dev, const unsigned char *addr);
2590extern int dev_mc_del(struct net_device *dev, unsigned char *addr); 2590extern int dev_mc_del(struct net_device *dev, const unsigned char *addr);
2591extern int dev_mc_del_global(struct net_device *dev, unsigned char *addr); 2591extern int dev_mc_del_global(struct net_device *dev, const unsigned char *addr);
2592extern int dev_mc_sync(struct net_device *to, struct net_device *from); 2592extern int dev_mc_sync(struct net_device *to, struct net_device *from);
2593extern void dev_mc_unsync(struct net_device *to, struct net_device *from); 2593extern void dev_mc_unsync(struct net_device *to, struct net_device *from);
2594extern void dev_mc_flush(struct net_device *dev); 2594extern void dev_mc_flush(struct net_device *dev);