diff options
| -rw-r--r-- | include/net/udp.h | 3 | ||||
| -rw-r--r-- | net/ipv6/udp.c | 8 |
2 files changed, 11 insertions, 0 deletions
diff --git a/include/net/udp.h b/include/net/udp.h index a184d3496b13..200b82848c9a 100644 --- a/include/net/udp.h +++ b/include/net/udp.h | |||
| @@ -183,6 +183,9 @@ extern int udp_lib_setsockopt(struct sock *sk, int level, int optname, | |||
| 183 | extern struct sock *udp4_lib_lookup(struct net *net, __be32 saddr, __be16 sport, | 183 | extern struct sock *udp4_lib_lookup(struct net *net, __be32 saddr, __be16 sport, |
| 184 | __be32 daddr, __be16 dport, | 184 | __be32 daddr, __be16 dport, |
| 185 | int dif); | 185 | int dif); |
| 186 | extern struct sock *udp6_lib_lookup(struct net *net, const struct in6_addr *saddr, __be16 sport, | ||
| 187 | const struct in6_addr *daddr, __be16 dport, | ||
| 188 | int dif); | ||
| 186 | 189 | ||
| 187 | /* | 190 | /* |
| 188 | * SNMP statistics for UDP and UDP-Lite | 191 | * SNMP statistics for UDP and UDP-Lite |
diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c index 33e368318d47..c84dad432114 100644 --- a/net/ipv6/udp.c +++ b/net/ipv6/udp.c | |||
| @@ -320,6 +320,14 @@ static struct sock *__udp6_lib_lookup_skb(struct sk_buff *skb, | |||
| 320 | udptable); | 320 | udptable); |
| 321 | } | 321 | } |
| 322 | 322 | ||
| 323 | struct sock *udp6_lib_lookup(struct net *net, const struct in6_addr *saddr, __be16 sport, | ||
| 324 | const struct in6_addr *daddr, __be16 dport, int dif) | ||
| 325 | { | ||
| 326 | return __udp6_lib_lookup(net, saddr, sport, daddr, dport, dif, &udp_table); | ||
| 327 | } | ||
| 328 | EXPORT_SYMBOL_GPL(udp6_lib_lookup); | ||
| 329 | |||
| 330 | |||
| 323 | /* | 331 | /* |
| 324 | * This should be easy, if there is something there we | 332 | * This should be easy, if there is something there we |
| 325 | * return it, otherwise we block. | 333 | * return it, otherwise we block. |
