summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/ixgbe/ixgbe_phy.c
diff options
context:
space:
mode:
authorMark Rustad <mark.d.rustad@intel.com>2015-08-09 01:18:17 +0200
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2015-09-24 07:24:55 +0200
commit6ee8c9a70d65ee37251465348501a067138050d7 (patch)
tree236535436890ba5658c4bfac8613b9a2ae589f47 /drivers/net/ethernet/intel/ixgbe/ixgbe_phy.c
parentnet/ethoc: support big-endian register layout (diff)
downloadlinux-6ee8c9a70d65ee37251465348501a067138050d7.tar.xz
linux-6ee8c9a70d65ee37251465348501a067138050d7.zip
ixgbe: Clear I2C destination location
Clear the destination location for I2C data initially so that the received data will not be affected by previous attempts. This could have returned wrong data in certain retry sequences. 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>
Diffstat (limited to 'drivers/net/ethernet/intel/ixgbe/ixgbe_phy.c')
-rw-r--r--drivers/net/ethernet/intel/ixgbe/ixgbe_phy.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_phy.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_phy.c
index 315f0597fbc0..88ade175185a 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_phy.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_phy.c
@@ -2026,6 +2026,7 @@ static s32 ixgbe_clock_in_i2c_byte(struct ixgbe_hw *hw, u8 *data)
s32 i;
bool bit = false;
+ *data = 0;
for (i = 7; i >= 0; i--) {
ixgbe_clock_in_i2c_bit(hw, &bit);
*data |= bit << i;