1 /* SPDX-License-Identifier: GPL-2.0-only */ 1 /* SPDX-License-Identifier: GPL-2.0-only */ 2 /* 2 /* 3 * FWNODE helper for the MDIO (Ethernet PHY) A 3 * FWNODE helper for the MDIO (Ethernet PHY) API 4 */ 4 */ 5 5 6 #ifndef __LINUX_FWNODE_MDIO_H 6 #ifndef __LINUX_FWNODE_MDIO_H 7 #define __LINUX_FWNODE_MDIO_H 7 #define __LINUX_FWNODE_MDIO_H 8 8 9 #include <linux/phy.h> 9 #include <linux/phy.h> 10 10 11 #if IS_ENABLED(CONFIG_FWNODE_MDIO) 11 #if IS_ENABLED(CONFIG_FWNODE_MDIO) 12 int fwnode_mdiobus_phy_device_register(struct 12 int fwnode_mdiobus_phy_device_register(struct mii_bus *mdio, 13 struct 13 struct phy_device *phy, 14 struct 14 struct fwnode_handle *child, u32 addr); 15 15 16 int fwnode_mdiobus_register_phy(struct mii_bus 16 int fwnode_mdiobus_register_phy(struct mii_bus *bus, 17 struct fwnode_ 17 struct fwnode_handle *child, u32 addr); 18 18 19 #else /* CONFIG_FWNODE_MDIO */ 19 #else /* CONFIG_FWNODE_MDIO */ 20 int fwnode_mdiobus_phy_device_register(struct 20 int fwnode_mdiobus_phy_device_register(struct mii_bus *mdio, 21 struct 21 struct phy_device *phy, 22 struct 22 struct fwnode_handle *child, u32 addr) 23 { 23 { 24 return -EINVAL; 24 return -EINVAL; 25 } 25 } 26 26 27 static inline int fwnode_mdiobus_register_phy( 27 static inline int fwnode_mdiobus_register_phy(struct mii_bus *bus, 28 28 struct fwnode_handle *child, 29 29 u32 addr) 30 { 30 { 31 return -EINVAL; 31 return -EINVAL; 32 } 32 } 33 #endif 33 #endif 34 34 35 #endif /* __LINUX_FWNODE_MDIO_H */ 35 #endif /* __LINUX_FWNODE_MDIO_H */ 36 36
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.