Skip to contentSkip to conversation

DCB: fix kconfig option

PATCH Superseded Jeff Kirsher 2 participants 3 messages Nov 24, 2008 – Nov 25, 2008

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 DCB: fix kconfig option

Since the netlink option for DCB is necessary to actually be useful, simplified the Kconfig option. In addition, added useful help text for the Kconfig option.

---

 drivers/net/Kconfig            |    4 ++--
 drivers/net/ixgbe/Makefile     |    2 +-
 drivers/net/ixgbe/ixgbe.h      |    2 +-
 drivers/net/ixgbe/ixgbe_main.c |   10 +++++-----
 include/linux/netdevice.h      |    4 ++--
 net/Makefile                   |    4 ++--
 net/dcb/Kconfig                |   24 +++++++++++++++++-------
 net/dcb/dcbnl.c                |    2 +-
 8 files changed, 31 insertions(+), 21 deletions(-)
drivers/net/Kconfig +2 -2
index efd461d..75f9f7f 100644
@@ -2451,10 +2451,10 @@ config IXGBE_DCA
 	  driver.  DCA is a method for warming the CPU cache before data
 	  is used, with the intent of lessening the impact of cache misses.
 
-config IXGBE_DCBNL
+config IXGBE_DCB
 	bool "Data Center Bridging (DCB) Support"
 	default n
-	depends on IXGBE && DCBNL
+	depends on IXGBE && DCB
 	---help---
 	  Say Y here if you want to use Data Center Bridging (DCB) in the
 	  driver.
drivers/net/ixgbe/Makefile +1 -1
index 3228e50..6e7ef76 100644
@@ -35,4 +35,4 @@ obj-$(CONFIG_IXGBE) += ixgbe.o
 ixgbe-objs := ixgbe_main.o ixgbe_common.o ixgbe_ethtool.o \
               ixgbe_82598.o ixgbe_phy.o
 
-ixgbe-$(CONFIG_IXGBE_DCBNL) +=  ixgbe_dcb.o ixgbe_dcb_82598.o ixgbe_dcb_nl.o
+ixgbe-$(CONFIG_IXGBE_DCB) +=  ixgbe_dcb.o ixgbe_dcb_82598.o ixgbe_dcb_nl.o
drivers/net/ixgbe/ixgbe.h +1 -1
index 9509aee..6cbf26e 100644
@@ -327,7 +327,7 @@ enum ixgbe_boards {
 };
 
 extern struct ixgbe_info ixgbe_82598_info;
-#ifdef CONFIG_IXGBE_DCBNL
+#ifdef CONFIG_IXGBE_DCB
 extern struct dcbnl_rtnl_ops dcbnl_ops;
 extern int ixgbe_copy_dcb_cfg(struct ixgbe_dcb_config *src_dcb_cfg,
                               struct ixgbe_dcb_config *dst_dcb_cfg,
drivers/net/ixgbe/ixgbe_main.c +5 -5
index 6620397..667a646 100644
@@ -1914,7 +1914,7 @@ static void ixgbe_napi_disable_all(struct ixgbe_adapter *adapter)
 	}
 }
 
-#ifdef CONFIG_IXGBE_DCBNL
+#ifdef CONFIG_IXGBE_DCB
 /*
  * ixgbe_configure_dcb - Configure DCB hardware
  * @adapter: ixgbe adapter struct
@@ -1960,7 +1960,7 @@ static void ixgbe_configure(struct ixgbe_adapter *adapter)
 	ixgbe_set_rx_mode(netdev);
 
 	ixgbe_restore_vlan(adapter);
-#ifdef CONFIG_IXGBE_DCBNL
+#ifdef CONFIG_IXGBE_DCB
 	if (adapter->flags & IXGBE_FLAG_DCB_ENABLED) {
 		netif_set_gso_max_size(netdev, 32768);
 		ixgbe_configure_dcb(adapter);
@@ -2749,7 +2749,7 @@ static int __devinit ixgbe_sw_init(struct ixgbe_adapter *adapter)
 	struct ixgbe_hw *hw = &adapter->hw;
 	struct pci_dev *pdev = adapter->pdev;
 	unsigned int rss;
-#ifdef CONFIG_IXGBE_DCBNL
+#ifdef CONFIG_IXGBE_DCB
 	int j;
 	struct tc_configuration *tc;
 #endif
@@ -2768,7 +2768,7 @@ static int __devinit ixgbe_sw_init(struct ixgbe_adapter *adapter)
 	adapter->flags |= IXGBE_FLAG_RSS_ENABLED;
 	adapter->ring_feature[RING_F_DCB].indices = IXGBE_MAX_DCB_INDICES;
 
-#ifdef CONFIG_IXGBE_DCBNL
+#ifdef CONFIG_IXGBE_DCB
 	/* Configure DCB traffic classes */
 	for (j = 0; j < MAX_TRAFFIC_CLASS; j++) {
 		tc = &adapter->dcb_cfg.tc_config[j];
@@ -4120,7 +4120,7 @@ static int __devinit ixgbe_probe(struct pci_dev *pdev,
 	if (adapter->flags & IXGBE_FLAG_DCB_ENABLED)
 		adapter->flags &= ~IXGBE_FLAG_RSS_ENABLED;
 
-#ifdef CONFIG_IXGBE_DCBNL
+#ifdef CONFIG_IXGBE_DCB
 	netdev->dcbnl_ops = &dcbnl_ops;
 #endif
 
include/linux/netdevice.h +2 -2
index 6095af5..65cfb01 100644
@@ -43,7 +43,7 @@
 
 #include <net/net_namespace.h>
 #include <net/dsa.h>
-#ifdef CONFIG_DCBNL
+#ifdef CONFIG_DCB
 #include <net/dcbnl.h>
 #endif
 
@@ -846,7 +846,7 @@ struct net_device
 #define GSO_MAX_SIZE		65536
 	unsigned int		gso_max_size;
 
-#ifdef CONFIG_DCBNL
+#ifdef CONFIG_DCB
 	/* Data Center Bridging netlink ops */
 	struct dcbnl_rtnl_ops *dcbnl_ops;
 #endif
net/Makefile +2 -2
index e5af3dc..4ccc0c7 100644
@@ -56,8 +56,8 @@ obj-$(CONFIG_NETLABEL)		+= netlabel/
 obj-$(CONFIG_IUCV)		+= iucv/
 obj-$(CONFIG_RFKILL)		+= rfkill/
 obj-$(CONFIG_NET_9P)		+= 9p/
-ifeq ($(CONFIG_DCBNL),y)
-obj-$(CONFIG_DCB)		+= dcb/
+ifeq ($(CONFIG_DCB),)
+obj-y				+= dcb/
 endif
 
 ifeq ($(CONFIG_NET),y)
net/dcb/Kconfig +17 -7
index bdf3880..a250498 100644
@@ -1,12 +1,22 @@
 config DCB
-        tristate "Data Center Bridging support"
-
-config DCBNL
-	bool "Data Center Bridging netlink interface support"
-	depends on DCB
+        bool "Data Center Bridging support"
 	default n
 	---help---
-	  This option turns on the netlink interface
-	  (dcbnl) for Data Center Bridging capable devices.
+	  This enables support for configuring Data Center Bridging (DCB)
+	  features on DCB capable Ethernet adapters via rtnetlink.  Say 'Y'
+	  if you have a DCB capable Ethernet adapter which supports this
+	  interface and you are connected to a DCB capable switch.
+
+	  DCB is a collection of Ethernet enhancements which allow DCB capable
+	  NICs and switches to support network traffic with differing
+	  requirements (highly reliable, no drops vs. best effort vs. low
+	  latency) to co-exist on Ethernet.
+
+	  DCB features include:
+	    Enhanced Transmission Selection (aka Priority Grouping) - provides a
+	      framework for assigning bandwidth guarantees to traffic classes.
+	    Priority-based Flow Control (PFC) - a MAC control pause frame which
+	      works at the granularity of the 802.1p priority instead of the
+	      link (802.3x).
 
 	  If unsure, say N.
net/dcb/dcbnl.c +1 -1
index b2bda3f..79a351d 100644
@@ -48,7 +48,7 @@
  */
 
 MODULE_AUTHOR("Lucy Liu, <[email protected]>");
-MODULE_DESCRIPTION("Data Center Bridging generic netlink interface");
+MODULE_DESCRIPTION("Data Center Bridging netlink interface");
 MODULE_LICENSE("GPL");
 
 /**************** DCB attribute policies *************************************/
#1 lore raw
Quoted 22 lines · Jeff Kirsher

Since the netlink option for DCB is necessary to actually be useful, simplified the Kconfig option. In addition, added useful help text for the Kconfig option.

---

 drivers/net/Kconfig            |    4 ++--
 drivers/net/ixgbe/Makefile     |    2 +-
 drivers/net/ixgbe/ixgbe.h      |    2 +-
 drivers/net/ixgbe/ixgbe_main.c |   10 +++++-----
 include/linux/netdevice.h      |    4 ++--
 net/Makefile                   |    4 ++--
 net/dcb/Kconfig                |   24 +++++++++++++++++-------
 net/dcb/dcbnl.c                |    2 +-
 8 files changed, 31 insertions(+), 21 deletions(-)
net/Makefile +0 -0
index e5af3dc..4ccc0c7 100644

net/Makefile obj-$(CONFIG_NETLABEL) += netlabel/ · line 59

Quoted 6 lines
net/Makefile +1 -2
@@ -56,8 +56,8 @@ obj-$(CONFIG_NETLABEL)		+= netlabel/
 obj-$(CONFIG_IUCV)		+= iucv/
 obj-$(CONFIG_RFKILL)		+= rfkill/
 obj-$(CONFIG_NET_9P)		+= 9p/
-ifeq ($(CONFIG_DCBNL),y)
-obj-$(CONFIG_DCB)		+= dcb/
+ifeq ($(CONFIG_DCB),)

ifeq {empty/nothing} ? or ifeq y ?

Quoted 9 lines
net/Makefile +1 -0
+obj-y				+= dcb/
 endif
 
 ifeq ($(CONFIG_NET),y)
net/dcb/Kconfig +0 -0
index bdf3880..a250498 100644

net/dcb/Kconfig line 2

Quoted 7 lines
net/dcb/Kconfig +1 -5
@@ -1,12 +1,22 @@
 config DCB
-        tristate "Data Center Bridging support"
-
-config DCBNL
-	bool "Data Center Bridging netlink interface support"
-	depends on DCB
+        bool "Data Center Bridging support"

Accidental conversion of tab to spaces.

Quoted 22 lines
net/dcb/Kconfig +16 -2
 	default n
 	---help---
-	  This option turns on the netlink interface
-	  (dcbnl) for Data Center Bridging capable devices.
+	  This enables support for configuring Data Center Bridging (DCB)
+	  features on DCB capable Ethernet adapters via rtnetlink.  Say 'Y'
+	  if you have a DCB capable Ethernet adapter which supports this
+	  interface and you are connected to a DCB capable switch.
+
+	  DCB is a collection of Ethernet enhancements which allow DCB capable
+	  NICs and switches to support network traffic with differing
+	  requirements (highly reliable, no drops vs. best effort vs. low
+	  latency) to co-exist on Ethernet.
+
+	  DCB features include:
+	    Enhanced Transmission Selection (aka Priority Grouping) - provides a
+	      framework for assigning bandwidth guarantees to traffic classes.
+	    Priority-based Flow Control (PFC) - a MAC control pause frame which
+	      works at the granularity of the 802.1p priority instead of the
+	      link (802.3x).
 
 	  If unsure, say N.
Signature · 1 line
~Randy
#2 lore raw
Quoted 18 lines · Randy Dunlap
Quoted 16 lines · Jeff Kirsher

Since the netlink option for DCB is necessary to actually be useful, simplified the Kconfig option. In addition, added useful help text for the Kconfig option.

---

 drivers/net/Kconfig            |    4 ++--
 drivers/net/ixgbe/Makefile     |    2 +-
 drivers/net/ixgbe/ixgbe.h      |    2 +-
 drivers/net/ixgbe/ixgbe_main.c |   10 +++++-----
 include/linux/netdevice.h      |    4 ++--
 net/Makefile                   |    4 ++--
 net/dcb/Kconfig                |   24 +++++++++++++++++-------
 net/dcb/dcbnl.c                |    2 +-
 8 files changed, 31 insertions(+), 21 deletions(-)
Quoted 13 lines

net/Makefile obj-$(CONFIG_NETLABEL) += netlabel/ · line 59

Quoted 11 lines
net/Makefile +1 -2
index e5af3dc..4ccc0c7 100644
@@ -56,8 +56,8 @@ obj-$(CONFIG_NETLABEL)              += netlabel/
 obj-$(CONFIG_IUCV)           += iucv/
 obj-$(CONFIG_RFKILL)         += rfkill/
 obj-$(CONFIG_NET_9P)         += 9p/
-ifeq ($(CONFIG_DCBNL),y)
-obj-$(CONFIG_DCB)            += dcb/
+ifeq ($(CONFIG_DCB),)

ifeq {empty/nothing} ? or ifeq y ?

Good catch, interesting that I did not catch that during compile testing.

Quoted 18 lines
Quoted 9 lines
net/Makefile +1 -0
+obj-y                                += dcb/
 endif
 
 ifeq ($(CONFIG_NET),y)
net/dcb/Kconfig +0 -0
index bdf3880..a250498 100644

net/dcb/Kconfig line 2

Quoted 7 lines
net/dcb/Kconfig +1 -5
@@ -1,12 +1,22 @@
 config DCB
-        tristate "Data Center Bridging support"
-
-config DCBNL
-     bool "Data Center Bridging netlink interface support"
-     depends on DCB
+        bool "Data Center Bridging support"

Accidental conversion of tab to spaces.

Thanks, again.

Quoted 21 lines
Quoted 21 lines
net/dcb/Kconfig +16 -2
      default n
      ---help---
-       This option turns on the netlink interface
-       (dcbnl) for Data Center Bridging capable devices.
+       This enables support for configuring Data Center Bridging (DCB)
+       features on DCB capable Ethernet adapters via rtnetlink.  Say 'Y'
+       if you have a DCB capable Ethernet adapter which supports this
+       interface and you are connected to a DCB capable switch.
+
+       DCB is a collection of Ethernet enhancements which allow DCB capable
+       NICs and switches to support network traffic with differing
+       requirements (highly reliable, no drops vs. best effort vs. low
+       latency) to co-exist on Ethernet.
+
+       DCB features include:
+         Enhanced Transmission Selection (aka Priority Grouping) - provides a
+           framework for assigning bandwidth guarantees to traffic classes.
+         Priority-based Flow Control (PFC) - a MAC control pause frame which
+           works at the granularity of the 802.1p priority instead of the
+           link (802.3x).
 
Quoted 6 lines

net/dcb/Kconfig line 22

Quoted 1 line
net/dcb/Kconfig +0 -0
        If unsure, say N.

--
~Randy
--

Fixed and sending an updated patch.

Signature · 2 lines
Cheers,
Jeff