ixgbe: Fix to get FDMI HBA attributes information with X550
authorUsha Ketineni <usha.k.ketineni@intel.com>
Tue, 8 Dec 2015 12:01:18 +0000 (04:01 -0800)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Fri, 8 Jan 2016 12:11:21 +0000 (04:11 -0800)
Check whether the FCOE support is enabled for the devices to get the
 FDMI HBA attributes information instead of checking each device id.
Also, add Model string information for X550.

Signed-off-by: Usha Ketineni <usha.k.ketineni@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/ixgbe/ixgbe_fcoe.c

index 598293790ae612db88728d473494ba1360b86b8a..df1647fa892aa585194a00fa2b7b4e36ac5164bb 100644 (file)
@@ -996,8 +996,7 @@ int ixgbe_fcoe_get_hbainfo(struct net_device *netdev,
                return -EINVAL;
 
        /* Don't return information on unsupported devices */
-       if (hw->mac.type != ixgbe_mac_82599EB &&
-           hw->mac.type != ixgbe_mac_X540)
+       if (!(adapter->flags & IXGBE_FLAG_FCOE_ENABLED))
                return -EINVAL;
 
        /* Manufacturer */
@@ -1043,6 +1042,10 @@ int ixgbe_fcoe_get_hbainfo(struct net_device *netdev,
                snprintf(info->model,
                         sizeof(info->model),
                         "Intel 82599");
+       } else if (hw->mac.type == ixgbe_mac_X550) {
+               snprintf(info->model,
+                        sizeof(info->model),
+                        "Intel X550");
        } else {
                snprintf(info->model,
                         sizeof(info->model),
This page took 0.025285 seconds and 5 git commands to generate.