summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRussell King (Oracle) <rmk+kernel@armlinux.org.uk>2021-10-06 13:19:20 +0100
committerJakub Kicinski <kuba@kernel.org>2021-10-06 17:49:16 -0700
commit79365f36d1de87286bb4fc0abcb2a01678ef4bef (patch)
tree86863cc6016515a3f61464d48287e64f65621b12 /include
parent4c8270829928f8d9aa06955ce6bef5bc55ef059a (diff)
net: mdio: add mdiobus_modify_changed()
Add mdiobus_modify_changed() helper to reflect the phylib and similar equivalents. This will avoid this functionality being open-coded, as has already happened in phylink, and it looks like other users will be appearing soon. Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/mdio.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/mdio.h b/include/linux/mdio.h
index 5e6dc38f418e..f622888a4ba8 100644
--- a/include/linux/mdio.h
+++ b/include/linux/mdio.h
@@ -349,6 +349,8 @@ int mdiobus_write(struct mii_bus *bus, int addr, u32 regnum, u16 val);
int mdiobus_write_nested(struct mii_bus *bus, int addr, u32 regnum, u16 val);
int mdiobus_modify(struct mii_bus *bus, int addr, u32 regnum, u16 mask,
u16 set);
+int mdiobus_modify_changed(struct mii_bus *bus, int addr, u32 regnum,
+ u16 mask, u16 set);
static inline u32 mdiobus_c45_addr(int devad, u16 regnum)
{