phy: fix build error in phy-bcm-nsp-usb3 with COMPILE_TEST
PATCH 1/1 phy: fix build error in phy-bcm-nsp-usb3 with COMPILE_TEST
I see the following build error with COMPILE_TEST on randconfig builds:
divers/built-in.o: In function `nsp_usb3_phy_init':
phy-bcm-nsp-usb3.c:(.text+0x4050): undefined reference to mdiobus_write' phy-bcm-nsp-usb3.c:(.text+0x406c): undefined reference to mdiobus_write' phy-bcm-nsp-usb3.c:(.text+0x4088): undefined reference to mdiobus_write' phy-bcm-nsp-usb3.c:(.text+0x40a4): undefined reference to mdiobus_write' phy-bcm-nsp-usb3.c:(.text+0x40c0): undefined reference to mdiobus_write' drivers/built-in.o:phy-bcm-nsp-usb3.c:(.text+0x40f2): more undefined references to mdiobus_write' follow drivers/built-in.o: In function `mdio_module_init':
phy-bcm-nsp-usb3.c:(.init.text+0x134): undefined reference to mdio_driver_register' drivers/built-in.o: In function mdio_module_exit':
phy-bcm-nsp-usb3.c:(.exit.text+0xcc): undefined reference to `mdio_driver_unregister'
Fix this by adding the correct Kconfig dependency.
--- drivers/phy/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/phy/Kconfig +1 -1
@@ -512,7 +512,7 @@ config PHY_MESON8B_USB2 config PHY_NSP_USB3 tristate "Broadcom NorthStar plus USB3 PHY driver" - depends on OF && (ARCH_BCM_NSP || COMPILE_TEST) + depends on OF && OF_MDIO && (ARCH_BCM_NSP || COMPILE_TEST) select GENERIC_PHY default ARCH_BCM_NSP help
Signature · 1 line
2.11.0
Quoted 14 lines · Tobias Regnery
I see the following build error with
COMPILE_TESTon randconfig builds:
divers/built-in.o: In function `nsp_usb3_phy_init':
phy-bcm-nsp-usb3.c:(.text+0x4050): undefined reference tomdiobus_write' phy-bcm-nsp-usb3.c:(.text+0x406c): undefined reference tomdiobus_write' phy-bcm-nsp-usb3.c:(.text+0x4088): undefined reference tomdiobus_write' phy-bcm-nsp-usb3.c:(.text+0x40a4): undefined reference tomdiobus_write' phy-bcm-nsp-usb3.c:(.text+0x40c0): undefined reference tomdiobus_write' drivers/built-in.o:phy-bcm-nsp-usb3.c:(.text+0x40f2): more undefined references tomdiobus_write' followdrivers/built-in.o: In function `mdio_module_init':
phy-bcm-nsp-usb3.c:(.init.text+0x134): undefined reference tomdio_driver_register' drivers/built-in.o: In functionmdio_module_exit':
phy-bcm-nsp-usb3.c:(.exit.text+0xcc): undefined reference to `mdio_driver_unregister'
Quoted 1 line
Fix this by adding the correct
Kconfigdependency.
This patch looks fine, but this driver is being reverted in Kishon's "fixes" branch. See
https://git.kernel.org/pub/scm/linux/kernel/git/kishon/linux-phy.git/commit/?h=fixes&id=9200c6f177638909dbbaded8aeeeccbd48744400
Thanks,
Jon
Quoted 22 lines
Signed-off-by Tobias Regnery <[email protected]>--- drivers/phy/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/phy/Kconfig +1
-1@@ -512,7 +512,7 @@ config PHY_MESON8B_USB2 config PHY_NSP_USB3 tristate "Broadcom NorthStar plus USB3 PHY driver" - depends on OF && (ARCH_BCM_NSP || COMPILE_TEST) + depends on OF && OF_MDIO && (ARCH_BCM_NSP || COMPILE_TEST) select GENERIC_PHY default ARCH_BCM_NSP helpSignature · 1 line
2.11.0