Skip to content

Commit

Permalink
ixgbe: Only clear adapter_stopped if ixgbe_setup_fc succeeded
Browse files Browse the repository at this point in the history
A logic error here results in the adapter_stopped flag only being
cleared when ixgbe_setup_fc returns an error. Correct the logic.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
  • Loading branch information
Mark Rustad authored and Jeff Kirsher committed Sep 24, 2015
1 parent 9de7605 commit 3507a9b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/net/ethernet/intel/ixgbe/ixgbe_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -297,13 +297,13 @@ s32 ixgbe_start_hw_generic(struct ixgbe_hw *hw)

/* Setup flow control */
ret_val = ixgbe_setup_fc(hw);
if (!ret_val)
return 0;
if (ret_val)
return ret_val;

/* Clear adapter stopped flag */
hw->adapter_stopped = false;

return ret_val;
return 0;
}

/**
Expand Down

0 comments on commit 3507a9b

Please sign in to comment.