summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRussell King (Oracle) <rmk+kernel@armlinux.org.uk>2025-10-29 00:03:41 +0000
committerJakub Kicinski <kuba@kernel.org>2025-10-29 17:18:22 -0700
commitf9326b139b4c77128564574ea2d7b83c8a758114 (patch)
tree3ecbfeaf5edd267e2c4fcc4e1cb4e3133e834ca9
parent7b510ea8e58eb0ead6bc41fd0f15ec064312dcbf (diff)
net: stmmac: use != rather than ^ for comparing dev_id
Use the more usual not-equals rather than exclusive-or operator when comparing the dev_id in stmmac_hwif_find(). Reviewed-by: Andrew Lunn <andrew@lunn.ch> Tested-by: Maxime Chevallier <maxime.chevallier@bootlin.com> Tested-by: Mohd Ayaan Anwar <mohd.anwar@oss.qualcomm.com> Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> Link: https://patch.msgid.link/E1vDtfB-0000000CCCR-25rr@rmk-PC.armlinux.org.uk Signed-off-by: Jakub Kicinski <kuba@kernel.org>
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/hwif.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/hwif.c b/drivers/net/ethernet/stmicro/stmmac/hwif.c
index 892cef79c4d1..e1f99b9d9d7f 100644
--- a/drivers/net/ethernet/stmicro/stmmac/hwif.c
+++ b/drivers/net/ethernet/stmicro/stmmac/hwif.c
@@ -314,7 +314,7 @@ stmmac_hwif_find(enum dwmac_core_type core_type, u8 snpsver, u8 dev_id)
if (snpsver < entry->min_id)
continue;
if (core_type == DWMAC_CORE_XGMAC &&
- (dev_id ^ entry->dev_id))
+ dev_id != entry->dev_id)
continue;
return entry;