summaryrefslogtreecommitdiff
path: root/include/linux/of_mdio.h
diff options
context:
space:
mode:
authorFlorian Fainelli <f.fainelli@gmail.com>2017-03-23 20:01:17 +0300
committerDavid S. Miller <davem@davemloft.net>2017-03-24 22:51:04 +0300
commite6e14f63d744cede856ba5d517d6b266c9cfbf41 (patch)
treefa04397a4090922679d42a6b616c9ee8e57877d6 /include/linux/of_mdio.h
parent5952fde10c35ecfefb0c3e61536170798d4a51c9 (diff)
downloadlinux-e6e14f63d744cede856ba5d517d6b266c9cfbf41.tar.xz
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>
Diffstat (limited to 'include/linux/of_mdio.h')
-rw-r--r--include/linux/of_mdio.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/of_mdio.h b/include/linux/of_mdio.h
index a58cca8bcb29..ba35ba520487 100644
--- a/include/linux/of_mdio.h
+++ b/include/linux/of_mdio.h
@@ -12,7 +12,7 @@
#include <linux/phy.h>
#include <linux/of.h>
-#ifdef CONFIG_OF
+#if IS_ENABLED(CONFIG_OF_MDIO)
extern int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np);
extern struct phy_device *of_phy_find_device(struct device_node *phy_np);
extern struct phy_device *of_phy_connect(struct net_device *dev,
@@ -32,7 +32,7 @@ extern int of_phy_register_fixed_link(struct device_node *np);
extern void of_phy_deregister_fixed_link(struct device_node *np);
extern bool of_phy_is_fixed_link(struct device_node *np);
-#else /* CONFIG_OF */
+#else /* CONFIG_OF_MDIO */
static inline int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np)
{
/*