net: stmmac: convert half-duplex support to positive logic
authorRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Thu, 24 Aug 2023 13:38:39 +0000 (14:38 +0100)
committerJakub Kicinski <kuba@kernel.org>
Sat, 26 Aug 2023 01:55:19 +0000 (18:55 -0700)
commit76649fc93f097785e9b173950d0fbb1d7a9c4a76
tree5797e4cd06038939f45ee5577a0441930d89f37a
parent64961f1b8ca1c6f515478887db70cd0e88f47af4
net: stmmac: convert half-duplex support to positive logic

Rather than detecting when half-duplex is not supported, and clearing
the MAC capabilities, reverse the if() condition and use it to set the
capabilities instead.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Link: https://lore.kernel.org/r/E1qZAXn-005pUb-SP@rmk-PC.armlinux.org.uk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c