aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/inet_hashtables.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2006-09-27 21:43:33 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2006-09-28 21:02:26 -0400
commitfb99c848e5ae6b8b2bc11f0f90c9e2bb3d702c0d (patch)
tree843afd532897b2034769c7260436c49455f0d34d /net/ipv4/inet_hashtables.c
parent4f765d842fa6e6fe15d555b247b640118d65b4dd (diff)
[IPV4]: annotate inet_lookup() and friends
inet_lookup() annotated along with helper functions (__inet_lookup(), __inet_lookup_established(), inet_lookup_established(), inet_lookup_listener(), __inet_lookup_listener() and inet_ehashfn()) Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/inet_hashtables.c')
-rw-r--r--net/ipv4/inet_hashtables.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/net/ipv4/inet_hashtables.c b/net/ipv4/inet_hashtables.c
index 729d1eb39483..244c4f445c7d 100644
--- a/net/ipv4/inet_hashtables.c
+++ b/net/ipv4/inet_hashtables.c
@@ -125,7 +125,7 @@ EXPORT_SYMBOL(inet_listen_wlock);
125 * wildcarded during the search since they can never be otherwise. 125 * wildcarded during the search since they can never be otherwise.
126 */ 126 */
127static struct sock *inet_lookup_listener_slow(const struct hlist_head *head, 127static struct sock *inet_lookup_listener_slow(const struct hlist_head *head,
128 const u32 daddr, 128 const __be32 daddr,
129 const unsigned short hnum, 129 const unsigned short hnum,
130 const int dif) 130 const int dif)
131{ 131{
@@ -137,7 +137,7 @@ static struct sock *inet_lookup_listener_slow(const struct hlist_head *head,
137 const struct inet_sock *inet = inet_sk(sk); 137 const struct inet_sock *inet = inet_sk(sk);
138 138
139 if (inet->num == hnum && !ipv6_only_sock(sk)) { 139 if (inet->num == hnum && !ipv6_only_sock(sk)) {
140 const __u32 rcv_saddr = inet->rcv_saddr; 140 const __be32 rcv_saddr = inet->rcv_saddr;
141 int score = sk->sk_family == PF_INET ? 1 : 0; 141 int score = sk->sk_family == PF_INET ? 1 : 0;
142 142
143 if (rcv_saddr) { 143 if (rcv_saddr) {
@@ -163,7 +163,7 @@ static struct sock *inet_lookup_listener_slow(const struct hlist_head *head,
163 163
164/* Optimize the common listener case. */ 164/* Optimize the common listener case. */
165struct sock *__inet_lookup_listener(struct inet_hashinfo *hashinfo, 165struct sock *__inet_lookup_listener(struct inet_hashinfo *hashinfo,
166 const u32 daddr, const unsigned short hnum, 166 const __be32 daddr, const unsigned short hnum,
167 const int dif) 167 const int dif)
168{ 168{
169 struct sock *sk = NULL; 169 struct sock *sk = NULL;
@@ -197,8 +197,8 @@ static int __inet_check_established(struct inet_timewait_death_row *death_row,
197{ 197{
198 struct inet_hashinfo *hinfo = death_row->hashinfo; 198 struct inet_hashinfo *hinfo = death_row->hashinfo;
199 struct inet_sock *inet = inet_sk(sk); 199 struct inet_sock *inet = inet_sk(sk);
200 u32 daddr = inet->rcv_saddr; 200 __be32 daddr = inet->rcv_saddr;
201 u32 saddr = inet->daddr; 201 __be32 saddr = inet->daddr;
202 int dif = sk->sk_bound_dev_if; 202 int dif = sk->sk_bound_dev_if;
203 INET_ADDR_COOKIE(acookie, saddr, daddr) 203 INET_ADDR_COOKIE(acookie, saddr, daddr)
204 const __portpair ports = INET_COMBINED_PORTS(inet->dport, lport); 204 const __portpair ports = INET_COMBINED_PORTS(inet->dport, lport);