提交 b943fbb0 编写于 作者: B Bjørn Mork 提交者: David S. Miller

net: of/phy: fix build error when phylib is built as a module

CONFIG_OF_MDIO is tristate and will be m if PHYLIB is m.  Use
IS_ENABLED macro to prevent build error:

 ERROR: "of_mdio_find_bus" [drivers/net/phy/mdio-mux.ko] undefined!
Reported-by: NRandy Dunlap <rdunlap@xenotime.net>
Cc: David Daney <david.daney@cavium.com>
Signed-off-by: NBjørn Mork <bjorn@mork.no>
Acked-by: NDavid Daney <david.daney@cavium.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 16c788de
......@@ -88,7 +88,7 @@ static struct class mdio_bus_class = {
.dev_release = mdiobus_release,
};
#ifdef CONFIG_OF_MDIO
#if IS_ENABLED(CONFIG_OF_MDIO)
/* Helper function for of_mdio_find_bus */
static int of_mdio_bus_match(struct device *dev, void *mdio_bus_np)
{
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册