qed: Don't config min BW on 100g on link flap
authorYuval Mintz <Yuval.Mintz@qlogic.com>
Thu, 26 May 2016 08:01:24 +0000 (11:01 +0300)
committerDavid S. Miller <davem@davemloft.net>
Thu, 26 May 2016 19:27:33 +0000 (12:27 -0700)
Currently 100g devices don't support minimum/maximum BW configurations,
yet link flaps might cause the driver to attempt to do such a
configuration. Prevent this just as we do for the maximum BW.

Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qed/qed_dev.c

index 579c6d500865c5af645ff1e13c92fa485a5a01da..2d89e8c16b3277b74c2570ba145297caa872b079 100644 (file)
@@ -2105,6 +2105,13 @@ void qed_configure_vp_wfq_on_link_change(struct qed_dev *cdev, u32 min_pf_rate)
 {
        int i;
 
+       if (cdev->num_hwfns > 1) {
+               DP_VERBOSE(cdev,
+                          NETIF_MSG_LINK,
+                          "WFQ configuration is not supported for this device\n");
+               return;
+       }
+
        for_each_hwfn(cdev, i) {
                struct qed_hwfn *p_hwfn = &cdev->hwfns[i];