dcb: data center bridging ops should be r/o
authorStephen Hemminger <shemminger@vyatta.com>
Mon, 5 Oct 2009 06:01:03 +0000 (06:01 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 7 Oct 2009 08:10:47 +0000 (01:10 -0700)
The data center bridging ops structure can be const

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ixgbe/ixgbe.h
drivers/net/ixgbe/ixgbe_dcb_nl.c
include/linux/netdevice.h

index 385be6016667a6fd1049538443d634627f32db03..28f32da794dd3936aa9b0c8d34870e867d97d896 100644 (file)
@@ -397,7 +397,7 @@ enum ixgbe_boards {
 extern struct ixgbe_info ixgbe_82598_info;
 extern struct ixgbe_info ixgbe_82599_info;
 #ifdef CONFIG_IXGBE_DCB
-extern struct dcbnl_rtnl_ops dcbnl_ops;
+extern const 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,
                               int tc_max);
index a6bc1ef28f92bdf8d390b5295df996ab56c8b145..3c7a79a7d7c6707414d612d6c53df6dfb49d6a91 100644 (file)
@@ -563,7 +563,7 @@ static u8 ixgbe_dcbnl_setapp(struct net_device *netdev,
        return rval;
 }
 
-struct dcbnl_rtnl_ops dcbnl_ops = {
+const struct dcbnl_rtnl_ops dcbnl_ops = {
        .getstate       = ixgbe_dcbnl_get_state,
        .setstate       = ixgbe_dcbnl_set_state,
        .getpermhwaddr  = ixgbe_dcbnl_get_perm_hw_addr,
index 94958c109761287798f187e1c2bb96abf0b5693e..b332eefebb1ba17d868bfb678a7f67f00ca109ac 100644 (file)
@@ -909,7 +909,7 @@ struct net_device
 
 #ifdef CONFIG_DCB
        /* Data Center Bridging netlink ops */
-       struct dcbnl_rtnl_ops *dcbnl_ops;
+       const struct dcbnl_rtnl_ops *dcbnl_ops;
 #endif
 
 #if defined(CONFIG_FCOE) || defined(CONFIG_FCOE_MODULE)