Skip to content

Commit

Permalink
fm10k: don't protect fm10k_queue_mac_request by fm10k_host_mbx_ready
Browse files Browse the repository at this point in the history
We don't actually need to check if the host mbx is ready when queuing
MAC requests, because these are not handled by a special queue which
queues up requests until the mailbox is capable of handling them.

Pull these requests outside the fm10k_host_mbx_ready() check, as it is
not necessary.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Krishneil Singh <krishneil.k.singh@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
  • Loading branch information
Jacob Keller authored and Jeff Kirsher committed May 9, 2018
1 parent 454ca38 commit 0a3e92d
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions drivers/net/ethernet/intel/fm10k/fm10k_netdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -1537,12 +1537,12 @@ static void *fm10k_dfwd_add_station(struct net_device *dev,

glort = l2_accel->dglort + 1 + i;

if (fm10k_host_mbx_ready(interface)) {
if (fm10k_host_mbx_ready(interface))
hw->mac.ops.update_xcast_mode(hw, glort,
FM10K_XCAST_MODE_NONE);
fm10k_queue_mac_request(interface, glort, sdev->dev_addr,
hw->mac.default_vid, true);
}

fm10k_queue_mac_request(interface, glort, sdev->dev_addr,
hw->mac.default_vid, true);

for (vid = fm10k_find_next_vlan(interface, 0);
vid < VLAN_N_VID;
Expand Down Expand Up @@ -1583,12 +1583,12 @@ static void fm10k_dfwd_del_station(struct net_device *dev, void *priv)

glort = l2_accel->dglort + 1 + i;

if (fm10k_host_mbx_ready(interface)) {
if (fm10k_host_mbx_ready(interface))
hw->mac.ops.update_xcast_mode(hw, glort,
FM10K_XCAST_MODE_NONE);
fm10k_queue_mac_request(interface, glort, sdev->dev_addr,
hw->mac.default_vid, false);
}

fm10k_queue_mac_request(interface, glort, sdev->dev_addr,
hw->mac.default_vid, false);

for (vid = fm10k_find_next_vlan(interface, 0);
vid < VLAN_N_VID;
Expand Down

0 comments on commit 0a3e92d

Please sign in to comment.