Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

of_mdio: Correct check against CONFIG_OF

CONFIG_OF_MDIO is actually what triggers the build of drivers/of/of_mdio.c, so
providing inline stubs when CONFIG_OF_MDIO=y should be based on that symbol as
well.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Florian Fainelli and committed by
David S. Miller
e6e14f63 5952fde1

+2 -2
+2 -2
include/linux/of_mdio.h
··· 12 12 #include <linux/phy.h> 13 13 #include <linux/of.h> 14 14 15 - #ifdef CONFIG_OF 15 + #if IS_ENABLED(CONFIG_OF_MDIO) 16 16 extern int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np); 17 17 extern struct phy_device *of_phy_find_device(struct device_node *phy_np); 18 18 extern struct phy_device *of_phy_connect(struct net_device *dev, ··· 32 32 extern void of_phy_deregister_fixed_link(struct device_node *np); 33 33 extern bool of_phy_is_fixed_link(struct device_node *np); 34 34 35 - #else /* CONFIG_OF */ 35 + #else /* CONFIG_OF_MDIO */ 36 36 static inline int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np) 37 37 { 38 38 /*