ksz884x: fix return value of netdev_set_eeprom
ksz884x: fix return value of netdev_set_eeprom netdev_set_eeprom() confused ethtool by just returning 1 on error instead of a proper -EINVAL. Signed-off-by: Jens Rottmann <JRottmann@LiPPERTEmbedded.de> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
8e039d84b3
commit
4881a4f89a
1 changed files with 1 additions and 1 deletions
|
@ -6322,7 +6322,7 @@ static int netdev_set_eeprom(struct net_device *dev,
|
|||
int len;
|
||||
|
||||
if (eeprom->magic != EEPROM_MAGIC)
|
||||
return 1;
|
||||
return -EINVAL;
|
||||
|
||||
len = (eeprom->offset + eeprom->len + 1) / 2;
|
||||
for (i = eeprom->offset / 2; i < len; i++)
|
||||
|
|
Loading…
Reference in a new issue