diff options
author | Stephen Hemminger <shemminger@vyatta.com> | 2009-09-01 15:25:04 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-09-02 04:03:49 -0400 |
commit | 3b401a81c0d50ea9c718cf837f62cc2e6e79cc30 (patch) | |
tree | cfb386a92521ae614fc8d76932461f26d14e9fa3 | |
parent | b2e4b3debc327a5b53d9622e0b1785eea2ea2aad (diff) |
inet: inet_connection_sock_af_ops const
The function block inet_connect_sock_af_ops contains no data
make it constant.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | include/net/transp_v6.h | 2 | ||||
-rw-r--r-- | net/dccp/ipv4.c | 2 | ||||
-rw-r--r-- | net/dccp/ipv6.c | 8 | ||||
-rw-r--r-- | net/ipv4/tcp_ipv4.c | 2 | ||||
-rw-r--r-- | net/ipv6/tcp_ipv6.c | 8 |
5 files changed, 11 insertions, 11 deletions
diff --git a/include/net/transp_v6.h b/include/net/transp_v6.h index bfb240c6cf79..d65381cad0fc 100644 --- a/include/net/transp_v6.h +++ b/include/net/transp_v6.h | |||
@@ -51,7 +51,7 @@ extern int datagram_send_ctl(struct net *net, | |||
51 | /* | 51 | /* |
52 | * address family specific functions | 52 | * address family specific functions |
53 | */ | 53 | */ |
54 | extern struct inet_connection_sock_af_ops ipv4_specific; | 54 | extern const struct inet_connection_sock_af_ops ipv4_specific; |
55 | 55 | ||
56 | extern void inet6_destroy_sock(struct sock *sk); | 56 | extern void inet6_destroy_sock(struct sock *sk); |
57 | 57 | ||
diff --git a/net/dccp/ipv4.c b/net/dccp/ipv4.c index a0a36c9e6cce..d01c00de1ad0 100644 --- a/net/dccp/ipv4.c +++ b/net/dccp/ipv4.c | |||
@@ -880,7 +880,7 @@ discard_and_relse: | |||
880 | goto discard_it; | 880 | goto discard_it; |
881 | } | 881 | } |
882 | 882 | ||
883 | static struct inet_connection_sock_af_ops dccp_ipv4_af_ops = { | 883 | static const struct inet_connection_sock_af_ops dccp_ipv4_af_ops = { |
884 | .queue_xmit = ip_queue_xmit, | 884 | .queue_xmit = ip_queue_xmit, |
885 | .send_check = dccp_v4_send_check, | 885 | .send_check = dccp_v4_send_check, |
886 | .rebuild_header = inet_sk_rebuild_header, | 886 | .rebuild_header = inet_sk_rebuild_header, |
diff --git a/net/dccp/ipv6.c b/net/dccp/ipv6.c index 3e70faab2989..64f011cc4491 100644 --- a/net/dccp/ipv6.c +++ b/net/dccp/ipv6.c | |||
@@ -35,8 +35,8 @@ | |||
35 | 35 | ||
36 | /* The per-net dccp.v6_ctl_sk is used for sending RSTs and ACKs */ | 36 | /* The per-net dccp.v6_ctl_sk is used for sending RSTs and ACKs */ |
37 | 37 | ||
38 | static struct inet_connection_sock_af_ops dccp_ipv6_mapped; | 38 | static const struct inet_connection_sock_af_ops dccp_ipv6_mapped; |
39 | static struct inet_connection_sock_af_ops dccp_ipv6_af_ops; | 39 | static const struct inet_connection_sock_af_ops dccp_ipv6_af_ops; |
40 | 40 | ||
41 | static void dccp_v6_hash(struct sock *sk) | 41 | static void dccp_v6_hash(struct sock *sk) |
42 | { | 42 | { |
@@ -1055,7 +1055,7 @@ failure: | |||
1055 | return err; | 1055 | return err; |
1056 | } | 1056 | } |
1057 | 1057 | ||
1058 | static struct inet_connection_sock_af_ops dccp_ipv6_af_ops = { | 1058 | static const struct inet_connection_sock_af_ops dccp_ipv6_af_ops = { |
1059 | .queue_xmit = inet6_csk_xmit, | 1059 | .queue_xmit = inet6_csk_xmit, |
1060 | .send_check = dccp_v6_send_check, | 1060 | .send_check = dccp_v6_send_check, |
1061 | .rebuild_header = inet6_sk_rebuild_header, | 1061 | .rebuild_header = inet6_sk_rebuild_header, |
@@ -1076,7 +1076,7 @@ static struct inet_connection_sock_af_ops dccp_ipv6_af_ops = { | |||
1076 | /* | 1076 | /* |
1077 | * DCCP over IPv4 via INET6 API | 1077 | * DCCP over IPv4 via INET6 API |
1078 | */ | 1078 | */ |
1079 | static struct inet_connection_sock_af_ops dccp_ipv6_mapped = { | 1079 | static const struct inet_connection_sock_af_ops dccp_ipv6_mapped = { |
1080 | .queue_xmit = ip_queue_xmit, | 1080 | .queue_xmit = ip_queue_xmit, |
1081 | .send_check = dccp_v4_send_check, | 1081 | .send_check = dccp_v4_send_check, |
1082 | .rebuild_header = inet_sk_rebuild_header, | 1082 | .rebuild_header = inet_sk_rebuild_header, |
diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c index 3efbe94f022b..ce7d3b021ffc 100644 --- a/net/ipv4/tcp_ipv4.c +++ b/net/ipv4/tcp_ipv4.c | |||
@@ -1754,7 +1754,7 @@ int tcp_v4_tw_remember_stamp(struct inet_timewait_sock *tw) | |||
1754 | return 0; | 1754 | return 0; |
1755 | } | 1755 | } |
1756 | 1756 | ||
1757 | struct inet_connection_sock_af_ops ipv4_specific = { | 1757 | const struct inet_connection_sock_af_ops ipv4_specific = { |
1758 | .queue_xmit = ip_queue_xmit, | 1758 | .queue_xmit = ip_queue_xmit, |
1759 | .send_check = tcp_v4_send_check, | 1759 | .send_check = tcp_v4_send_check, |
1760 | .rebuild_header = inet_sk_rebuild_header, | 1760 | .rebuild_header = inet_sk_rebuild_header, |
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c index eadbc584e919..d73617e9708e 100644 --- a/net/ipv6/tcp_ipv6.c +++ b/net/ipv6/tcp_ipv6.c | |||
@@ -75,8 +75,8 @@ static void tcp_v6_reqsk_send_ack(struct sock *sk, struct sk_buff *skb, | |||
75 | 75 | ||
76 | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb); | 76 | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb); |
77 | 77 | ||
78 | static struct inet_connection_sock_af_ops ipv6_mapped; | 78 | static const struct inet_connection_sock_af_ops ipv6_mapped; |
79 | static struct inet_connection_sock_af_ops ipv6_specific; | 79 | static const struct inet_connection_sock_af_ops ipv6_specific; |
80 | #ifdef CONFIG_TCP_MD5SIG | 80 | #ifdef CONFIG_TCP_MD5SIG |
81 | static const struct tcp_sock_af_ops tcp_sock_ipv6_specific; | 81 | static const struct tcp_sock_af_ops tcp_sock_ipv6_specific; |
82 | static const struct tcp_sock_af_ops tcp_sock_ipv6_mapped_specific; | 82 | static const struct tcp_sock_af_ops tcp_sock_ipv6_mapped_specific; |
@@ -1760,7 +1760,7 @@ static int tcp_v6_remember_stamp(struct sock *sk) | |||
1760 | return 0; | 1760 | return 0; |
1761 | } | 1761 | } |
1762 | 1762 | ||
1763 | static struct inet_connection_sock_af_ops ipv6_specific = { | 1763 | static const struct inet_connection_sock_af_ops ipv6_specific = { |
1764 | .queue_xmit = inet6_csk_xmit, | 1764 | .queue_xmit = inet6_csk_xmit, |
1765 | .send_check = tcp_v6_send_check, | 1765 | .send_check = tcp_v6_send_check, |
1766 | .rebuild_header = inet6_sk_rebuild_header, | 1766 | .rebuild_header = inet6_sk_rebuild_header, |
@@ -1792,7 +1792,7 @@ static const struct tcp_sock_af_ops tcp_sock_ipv6_specific = { | |||
1792 | * TCP over IPv4 via INET6 API | 1792 | * TCP over IPv4 via INET6 API |
1793 | */ | 1793 | */ |
1794 | 1794 | ||
1795 | static struct inet_connection_sock_af_ops ipv6_mapped = { | 1795 | static const struct inet_connection_sock_af_ops ipv6_mapped = { |
1796 | .queue_xmit = ip_queue_xmit, | 1796 | .queue_xmit = ip_queue_xmit, |
1797 | .send_check = tcp_v4_send_check, | 1797 | .send_check = tcp_v4_send_check, |
1798 | .rebuild_header = inet_sk_rebuild_header, | 1798 | .rebuild_header = inet_sk_rebuild_header, |