summaryrefslogtreecommitdiffstats
path: root/net/ipv6/protocol.c
diff options
context:
space:
mode:
authorAlexey Dobriyan2009-09-14 14:22:28 +0200
committerDavid S. Miller2009-09-15 02:03:05 +0200
commit41135cc836a1abeb12ca1416bdb29e87ad021153 (patch)
tree01c402f2fb9ac494dc3655a17e92072b170b7c1f /net/ipv6/protocol.c
parentnet: constify struct net_protocol (diff)
downloadkernel-qcow2-linux-41135cc836a1abeb12ca1416bdb29e87ad021153.tar.gz
kernel-qcow2-linux-41135cc836a1abeb12ca1416bdb29e87ad021153.tar.xz
kernel-qcow2-linux-41135cc836a1abeb12ca1416bdb29e87ad021153.zip
net: constify struct inet6_protocol
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/protocol.c')
-rw-r--r--net/ipv6/protocol.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/ipv6/protocol.c b/net/ipv6/protocol.c
index 568864f722ca..1fa3468f0f32 100644
--- a/net/ipv6/protocol.c
+++ b/net/ipv6/protocol.c
@@ -25,11 +25,11 @@
#include <linux/spinlock.h>
#include <net/protocol.h>
-struct inet6_protocol *inet6_protos[MAX_INET_PROTOS];
+const struct inet6_protocol *inet6_protos[MAX_INET_PROTOS];
static DEFINE_SPINLOCK(inet6_proto_lock);
-int inet6_add_protocol(struct inet6_protocol *prot, unsigned char protocol)
+int inet6_add_protocol(const struct inet6_protocol *prot, unsigned char protocol)
{
int ret, hash = protocol & (MAX_INET_PROTOS - 1);
@@ -53,7 +53,7 @@ EXPORT_SYMBOL(inet6_add_protocol);
* Remove a protocol from the hash tables.
*/
-int inet6_del_protocol(struct inet6_protocol *prot, unsigned char protocol)
+int inet6_del_protocol(const struct inet6_protocol *prot, unsigned char protocol)
{
int ret, hash = protocol & (MAX_INET_PROTOS - 1);