]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
ixgbevf: make ethtool ops and strings const
authorStephen Hemminger <shemminger@vyatta.com>
Wed, 18 Jan 2012 22:13:32 +0000 (22:13 +0000)
committerJoe Jin <joe.jin@oracle.com>
Thu, 17 May 2012 15:56:43 +0000 (23:56 +0800)
(cherry picked from commit b47aca135d6df5f676c768368baf3c099f054fcd)
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Tested-by: Sibai Li <sibai.li@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Joe Jin <joe.jin@oracle.com>
drivers/net/ixgbevf/ethtool.c

index 149fa520d7f2100dbb91e7bde9fe602e9f7df593..d1c91c8202a5d150d900f81eccde788a17fb57bd 100644 (file)
@@ -56,7 +56,8 @@ struct ixgbe_stats {
                            offsetof(struct ixgbevf_adapter, m),         \
                            offsetof(struct ixgbevf_adapter, b),         \
                            offsetof(struct ixgbevf_adapter, r)
-static struct ixgbe_stats ixgbe_gstrings_stats[] = {
+
+static const struct ixgbe_stats ixgbe_gstrings_stats[] = {
        {"rx_packets", IXGBEVF_STAT(stats.vfgprc, stats.base_vfgprc,
                                    stats.saved_reset_vfgprc)},
        {"tx_packets", IXGBEVF_STAT(stats.vfgptc, stats.base_vfgptc,
@@ -671,7 +672,7 @@ static int ixgbevf_nway_reset(struct net_device *netdev)
        return 0;
 }
 
-static struct ethtool_ops ixgbevf_ethtool_ops = {
+static const struct ethtool_ops ixgbevf_ethtool_ops = {
        .get_settings           = ixgbevf_get_settings,
        .get_drvinfo            = ixgbevf_get_drvinfo,
        .get_regs_len           = ixgbevf_get_regs_len,