aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Rustad <mark.d.rustad@intel.com>2014-07-22 06:50:36 +0000
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2014-07-25 18:45:15 -0700
commitd819fc52117e18e9e331edc8fe7bd623279825d0 (patch)
tree6327601586f48cb961999ca2e20026c69635d44d
parentac3d2e5a9ef2f4d8f57c50070c4883ecb7cec29f (diff)
downloadlinux-linaro-stable-d819fc52117e18e9e331edc8fe7bd623279825d0.tar.gz
ixgbe: Convert some udelays to usleep_range
Convert some udelay calls to the preferred usleep_range. 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>
-rw-r--r--drivers/net/ethernet/intel/ixgbe/ixgbe_common.c6
-rw-r--r--drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c4
2 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_common.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_common.c
index 3f318c52e053..db759f98f9f0 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_common.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_common.c
@@ -1386,7 +1386,7 @@ static s32 ixgbe_get_eeprom_semaphore(struct ixgbe_hw *hw)
status = 0;
break;
}
- udelay(50);
+ usleep_range(50, 100);
}
if (i == timeout) {
@@ -1399,7 +1399,7 @@ static s32 ixgbe_get_eeprom_semaphore(struct ixgbe_hw *hw)
*/
ixgbe_release_eeprom_semaphore(hw);
- udelay(50);
+ usleep_range(50, 100);
/*
* one last try
* If the SMBI bit is 0 when we read it, then the bit will be
@@ -1427,7 +1427,7 @@ static s32 ixgbe_get_eeprom_semaphore(struct ixgbe_hw *hw)
if (swsm & IXGBE_SWSM_SWESMBI)
break;
- udelay(50);
+ usleep_range(50, 100);
}
/*
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c
index 40dd798e1290..942ad13c684a 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c
@@ -699,7 +699,7 @@ static s32 ixgbe_get_swfw_sync_semaphore(struct ixgbe_hw *hw)
status = 0;
break;
}
- udelay(50);
+ usleep_range(50, 100);
}
/* Now get the semaphore between SW/FW through the REGSMP bit */
@@ -709,7 +709,7 @@ static s32 ixgbe_get_swfw_sync_semaphore(struct ixgbe_hw *hw)
if (!(swsm & IXGBE_SWFW_REGSMP))
break;
- udelay(50);
+ usleep_range(50, 100);
}
} else {
hw_dbg(hw, "Software semaphore SMBI between device drivers not granted.\n");