Smatch report for drivers/net/phy/marvell10g.c

Andrew Goodbody andrew.goodbody at linaro.org
Tue Aug 5 18:30:49 CEST 2025


I have these Smatch reports.

drivers/net/phy/marvell10g.c:384 mv3310_select_mactype() warn: was || 
intended here instead of &&?
drivers/net/phy/marvell10g.c:387 mv3310_select_mactype() warn: was || 
intended here instead of &&?
drivers/net/phy/marvell10g.c:390 mv3310_select_mactype() warn: was || 
intended here instead of &&?

Now there is obviously incorrect code there as it cannot work correctly 
as is, phydev->interface cannot equal two different enums at the same 
time, but simply swapping the && for || is not going to work either. 
Could anyone please point me in the direction of a fix?

Thanks,
Andrew


More information about the U-Boot mailing list