Skip to content
Commit f25247d8 authored by Colin Ian King's avatar Colin Ian King Committed by David S. Miller
Browse files

net: phy: realtek: net: Fix less than zero comparison of a u16



The comparisons of the u16 values priv->phycr1 and priv->phycr2 to less
than zero always false because they are unsigned. Fix this by using an
int for the assignment and less than zero check.

Addresses-Coverity: ("Unsigned compared against 0")
Fixes: 0a4355c2 ("net: phy: realtek: add dt property to disable CLKOUT clock")
Fixes: d90db36a ("net: phy: realtek: add dt property to enable ALDPS mode")
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 345502af
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment