[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date: Wed, 11 Nov 2009 21:16:14 +0200
From: Octavian Purdila <opurdila@...acom.com>
To: netdev@...r.kernel.org
Subject: [PATCH] [next-next-2.6] net: configurable device name hash
Signed-off-by: Octavian Purdila <opurdila@...acom.com>
diff --git a/include/net/net_namespace.h b/include/net/net_namespace.h
index 0addd45..8a129d5 100644
--- a/include/net/net_namespace.h
+++ b/include/net/net_namespace.h
@@ -29,8 +29,7 @@ struct net_generic;
struct sock;
-#define NETDEV_HASHBITS 8
-#define NETDEV_HASHENTRIES (1 << NETDEV_HASHBITS)
+#define NETDEV_HASHENTRIES (1 << CONFIG_NETDEV_HASHBITS)
struct net {
atomic_t count; /* To decided when the network
diff --git a/net/Kconfig b/net/Kconfig
index 041c35e..f5db7b2 100644
--- a/net/Kconfig
+++ b/net/Kconfig
@@ -45,6 +45,13 @@ config COMPAT_NETLINK_MESSAGES
menu "Networking options"
+config NETDEV_HASHBITS
+ int "Network device hash size"
+ range 8 20
+ default 8
+ help
+ Select network device hash size as a power of 2.
+
source "net/packet/Kconfig"
source "net/unix/Kconfig"
source "net/xfrm/Kconfig"
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists