]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum: Fix EEPROM access in case of SFP/SFP+
authorArkadi Sharshevsky <arkadis@mellanox.com>
Mon, 11 Sep 2017 07:42:26 +0000 (09:42 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 11 Sep 2017 17:40:59 +0000 (10:40 -0700)
commitf9faec9f0bc98537c6533b60d429727d6e2515ac
tree3e412a8f1eead1ad0342e5529d8e9f79793372d5
parentb794374406550effee380ffcb5eb41dfa425d726
mlxsw: spectrum: Fix EEPROM access in case of SFP/SFP+

The current code does not handle correctly the access to the upper page
in case of SFP/SFP+ EEPROM. In that case the offset should be local
and the I2C address should be changed.

Fixes: 39213ca4afc2 ("mlxsw: spectrum: Add support for access cable info via ethtool")
Reported-by: Florian Klink <flokli@flokli.de>
Signed-off-by: Arkadi Sharshevsky <arkadis@mellanox.com>
Reviewed-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum.c