From: Colin King <hidden> Date: 2021-06-09 10:24:58
From: Colin Ian King <redacted>
The comparison of the u16 priv->phy_addr < 0 is always false because
phy_addr is unsigned. Fix this by assigning the return from the call
to function asix_read_phy_addr to int ret and using this for the
less than zero error check comparison.
Addresses-Coverity: ("Unsigned compared against 0")
Fixes: e532a096be0e ("net: usb: asix: ax88772: add phylib support")
Signed-off-by: Colin Ian King <redacted>
---
V2: Add new line, return ret instead of priv->phy_addr on error return path
---
drivers/net/usb/asix_devices.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
From: Colin King <hidden> Date: 2021-06-09 10:25:03
From: Colin Ian King <redacted>
The comparison of the u16 priv->phy_addr < 0 is always false because
phy_addr is unsigned. Fix this by assigning the return from the call
to function asix_read_phy_addr to int ret and using this for the
less than zero error check comparison.
Fixes: 7e88b11a862a ("net: usb: asix: refactor asix_read_phy_addr() and handle errors on return")
Addresses-Coverity: ("Unsigned compared against 0")
Signed-off-by: Colin Ian King <redacted>
---
V2: fix up return check.
---
drivers/net/usb/ax88172a.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
Hello:
This series was applied to netdev/net-next.git (refs/heads/master):
On Wed, 9 Jun 2021 11:24:47 +0100 you wrote:
From: Colin Ian King <redacted>
The comparison of the u16 priv->phy_addr < 0 is always false because
phy_addr is unsigned. Fix this by assigning the return from the call
to function asix_read_phy_addr to int ret and using this for the
less than zero error check comparison.
[...]