aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/udp.h
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-04-18 18:02:35 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2008-04-18 18:02:35 -0700
commit334d094504c2fe1c44211ecb49146ae6bca8c321 (patch)
treed3c0f68e4b9f8e3d2ccc39e7dfe5de0534a5fad9 /include/net/udp.h
parentx86 PAT: fix mmap() of holes (diff)
parent[NET]: Fix and allocate less memory for ->priv'less netdevices (diff)
downloadlinux-dev-334d094504c2fe1c44211ecb49146ae6bca8c321.tar.xz
linux-dev-334d094504c2fe1c44211ecb49146ae6bca8c321.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6.26
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6.26: (1090 commits) [NET]: Fix and allocate less memory for ->priv'less netdevices [IPV6]: Fix dangling references on error in fib6_add(). [NETLABEL]: Fix NULL deref in netlbl_unlabel_staticlist_gen() if ifindex not found [PKT_SCHED]: Fix datalen check in tcf_simp_init(). [INET]: Uninline the __inet_inherit_port call. [INET]: Drop the inet_inherit_port() call. SCTP: Initialize partial_bytes_acked to 0, when all of the data is acked. [netdrvr] forcedeth: internal simplifications; changelog removal phylib: factor out get_phy_id from within get_phy_device PHY: add BCM5464 support to broadcom PHY driver cxgb3: Fix __must_check warning with dev_dbg. tc35815: Statistics cleanup natsemi: fix MMIO for PPC 44x platforms [TIPC]: Cleanup of TIPC reference table code [TIPC]: Optimized initialization of TIPC reference table [TIPC]: Remove inlining of reference table locking routines e1000: convert uint16_t style integers to u16 ixgb: convert uint16_t style integers to u16 sb1000.c: make const arrays static sb1000.c: stop inlining largish static functions ...
Diffstat (limited to 'include/net/udp.h')
-rw-r--r--include/net/udp.h15
1 files changed, 8 insertions, 7 deletions
diff --git a/include/net/udp.h b/include/net/udp.h
index c6669c0a74c7..3e55a99b0ba3 100644
--- a/include/net/udp.h
+++ b/include/net/udp.h
@@ -115,7 +115,7 @@ static inline void udp_lib_unhash(struct sock *sk)
write_lock_bh(&udp_hash_lock);
if (sk_del_node_init(sk)) {
inet_sk(sk)->num = 0;
- sock_prot_inuse_add(sk->sk_prot, -1);
+ sock_prot_inuse_add(sock_net(sk), sk->sk_prot, -1);
}
write_unlock_bh(&udp_hash_lock);
}
@@ -125,6 +125,8 @@ static inline void udp_lib_close(struct sock *sk, long timeout)
sk_common_release(sk);
}
+extern int udp_lib_get_port(struct sock *sk, unsigned short snum,
+ int (*)(const struct sock*,const struct sock*));
/* net/ipv4/udp.c */
extern int udp_get_port(struct sock *sk, unsigned short snum,
@@ -183,24 +185,23 @@ DECLARE_SNMP_STAT(struct udp_mib, udplite_stats_in6);
/* /proc */
struct udp_seq_afinfo {
- struct module *owner;
char *name;
sa_family_t family;
struct hlist_head *hashtable;
- int (*seq_show) (struct seq_file *m, void *v);
- struct file_operations *seq_fops;
+ struct file_operations seq_fops;
+ struct seq_operations seq_ops;
};
struct udp_iter_state {
+ struct seq_net_private p;
sa_family_t family;
struct hlist_head *hashtable;
int bucket;
- struct seq_operations seq_ops;
};
#ifdef CONFIG_PROC_FS
-extern int udp_proc_register(struct udp_seq_afinfo *afinfo);
-extern void udp_proc_unregister(struct udp_seq_afinfo *afinfo);
+extern int udp_proc_register(struct net *net, struct udp_seq_afinfo *afinfo);
+extern void udp_proc_unregister(struct net *net, struct udp_seq_afinfo *afinfo);
extern int udp4_proc_init(void);
extern void udp4_proc_exit(void);