[DCCP]: Move dccp_hashinfo from ipv4.c to the core
authorArnaldo Carvalho de Melo <acme@mandriva.com>
Tue, 21 Mar 2006 05:24:19 +0000 (21:24 -0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 21 Mar 2006 05:24:19 +0000 (21:24 -0800)
As it is used by both ipv4 and ipv6.

Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/dccp/ipv4.c
net/dccp/proto.c

index f087593d64d30484b447b662196710e21ed73031..a7332f0f85c46cbaa15819e870fca585fc44b292 100644 (file)
 #include "dccp.h"
 #include "feat.h"
 
-struct inet_hashinfo __cacheline_aligned dccp_hashinfo = {
-       .lhash_lock     = RW_LOCK_UNLOCKED,
-       .lhash_users    = ATOMIC_INIT(0),
-       .lhash_wait = __WAIT_QUEUE_HEAD_INITIALIZER(dccp_hashinfo.lhash_wait),
-};
-
-EXPORT_SYMBOL_GPL(dccp_hashinfo);
-
 static int dccp_v4_get_port(struct sock *sk, const unsigned short snum)
 {
        return inet_csk_get_port(&dccp_hashinfo, sk, snum,
index 64806fbf44de7667ececbc749a10e485432bc4a4..3ba1ff43579886c38a20b5552ea9abe1167c9e78 100644 (file)
@@ -47,6 +47,14 @@ atomic_t dccp_orphan_count = ATOMIC_INIT(0);
 
 EXPORT_SYMBOL_GPL(dccp_orphan_count);
 
+struct inet_hashinfo __cacheline_aligned dccp_hashinfo = {
+       .lhash_lock     = RW_LOCK_UNLOCKED,
+       .lhash_users    = ATOMIC_INIT(0),
+       .lhash_wait = __WAIT_QUEUE_HEAD_INITIALIZER(dccp_hashinfo.lhash_wait),
+};
+
+EXPORT_SYMBOL_GPL(dccp_hashinfo);
+
 static struct net_protocol dccp_protocol = {
        .handler        = dccp_v4_rcv,
        .err_handler    = dccp_v4_err,