Skip to content

Commit

Permalink
of: mdio: Add missing inline to of_mdiobus_child_is_phy() dummy
Browse files Browse the repository at this point in the history
If CONFIG_OF_MDIO=n:

    drivers/net/phy/mdio_bus.c:23:
    include/linux/of_mdio.h:58:13: warning: ‘of_mdiobus_child_is_phy’ defined but not used [-Wunused-function]
     static bool of_mdiobus_child_is_phy(struct device_node *child)
		 ^~~~~~~~~~~~~~~~~~~~~~~

Fix this by adding the missing "inline" keyword.

Fixes: 0aa4d01 ("of: mdio: export of_mdiobus_child_is_phy")
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Acked-by: Borislav Petkov <bp@suse.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Geert Uytterhoeven authored and David S. Miller committed Dec 26, 2019
1 parent 1c93fb4 commit 7df2281
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/linux/of_mdio.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ static inline int of_mdio_parse_addr(struct device *dev,
}

#else /* CONFIG_OF_MDIO */
static bool of_mdiobus_child_is_phy(struct device_node *child)
static inline bool of_mdiobus_child_is_phy(struct device_node *child)
{
return false;
}
Expand Down

0 comments on commit 7df2281

Please sign in to comment.