Skip to content

Commit

Permalink
ixgbe: Correct error path in semaphore handling
Browse files Browse the repository at this point in the history
The timeout path is supposed to release the semaphore, so do that.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@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 449e21a commit 5967fe2
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c
Original file line number Diff line number Diff line change
Expand Up @@ -711,6 +711,11 @@ static s32 ixgbe_get_swfw_sync_semaphore(struct ixgbe_hw *hw)
usleep_range(50, 100);
}

/* Release semaphores and return error if SW NVM semaphore
* was not granted because we do not have access to the EEPROM
*/
hw_dbg(hw, "REGSMP Software NVM semaphore not granted\n");
ixgbe_release_swfw_sync_semaphore(hw);
return IXGBE_ERR_EEPROM;
}

Expand Down

0 comments on commit 5967fe2

Please sign in to comment.