Skip to contentSkip to conversation

net: pcs: xpcs: select PHYLINK in Kconfig

PATCH In review Jakub Kicinski 3 participants 5 messages Jun 20, 2022 – Jun 21, 2022

Subsystems (3)
lore
Share & tools
lore

Jakub Kicinski

author maintainer
#0 lore raw

PATCH 1/1 net: pcs: xpcs: select PHYLINK in Kconfig

Various builds bots are upset about lack of PHYLINK:

Quoted 2 lines
Quoted 2 lines

ERROR: modpost: "phylink_mii_c22_pcs_encode_advertisement" [drivers/net/pcs/pcs_xpcs.ko] undefined!
ERROR: modpost: "phylink_mii_c22_pcs_decode_state" [drivers/net/pcs/pcs_xpcs.ko] undefined!

Fixes b47aec885bcd ("net: pcs: xpcs: add CL37 1000BASE-X AN support")

---
CC: [email protected]
CC: [email protected]
CC: [email protected]
CC: [email protected]
CC: [email protected]

---
 drivers/net/pcs/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/net/pcs/Kconfig +1 -0
index 22ba7b0b476d..c3e52fa6ca06 100644
@@ -8,6 +8,7 @@ menu "PCS device drivers"
 config PCS_XPCS
 	tristate "Synopsys DesignWare XPCS controller"
 	depends on MDIO_DEVICE && MDIO_BUS
+	select PHYLINK
 	help
 	  This module provides helper functions for Synopsys DesignWare XPCS
 	  controllers.
Signature · 1 line
2.36.1
#1 lore raw
I love your patch! Yet something to improve:

Hi Jakub,

I love your patch! Yet something to improve:

[auto build test ERROR on net-next/master]

url:    https://github.com/intel-lab-lkp/linux/commits/Jakub-Kicinski/net-pcs-xpcs-select-PHYLINK-in-Kconfig/20220621-042123
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git dbca1596bbb08318f5e3b3b99f8ca0a0d3830a65
config: i386-tinyconfig
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
        # https://github.com/intel-lab-lkp/linux/commit/a3120516f7ee66896bb0d3c90fe653ce0cb3a09f
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Jakub-Kicinski/net-pcs-xpcs-select-PHYLINK-in-Kconfig/20220621-042123
        git checkout a3120516f7ee66896bb0d3c90fe653ce0cb3a09f
        make W=1 ARCH=i386  tinyconfig
        make W=1 ARCH=i386 

If you fix the issue, kindly add following tag where applicable

All errors (new ones prefixed by >>):

>> drivers/net/phy/Kconfig:16:error: recursive dependency detected!

drivers/net/phy/Kconfig:16: symbol PHYLIB is selected by PHYLINK drivers/net/phy/Kconfig:6: symbol PHYLINK is selected by PCS_XPCS drivers/net/pcs/Kconfig:8: symbol PCS_XPCS depends on MDIO_DEVICE drivers/net/mdio/Kconfig:6: symbol MDIO_DEVICE is selected by PHYLIB For a resolution refer to Documentation/kbuild/kconfig-language.rst subsection "Kconfig recursive dependency limitations"

vim +16 drivers/net/phy/Kconfig

00db8189d984d6 Andy Fleming        2005-07-30   5  
9525ae83959b60 Russell King        2017-07-25   6  config PHYLINK
9525ae83959b60 Russell King        2017-07-25   7  	tristate
9525ae83959b60 Russell King        2017-07-25   8  	depends on NETDEVICES
9525ae83959b60 Russell King        2017-07-25   9  	select PHYLIB
9525ae83959b60 Russell King        2017-07-25  10  	select SWPHY
9525ae83959b60 Russell King        2017-07-25  11  	help
9525ae83959b60 Russell King        2017-07-25  12  	  PHYlink models the link between the PHY and MAC, allowing fixed
9525ae83959b60 Russell King        2017-07-25  13  	  configuration links, PHYs, and Serdes links with MAC level
9525ae83959b60 Russell King        2017-07-25  14  	  autonegotiation modes.
9525ae83959b60 Russell King        2017-07-25  15  
6073512cc8e2c4 Jerome Brunet       2017-09-18 @16  menuconfig PHYLIB
9e8d438e8ba43a Florian Fainelli    2018-04-27  17  	tristate "PHY Device support and infrastructure"
6073512cc8e2c4 Jerome Brunet       2017-09-18  18  	depends on NETDEVICES
6073512cc8e2c4 Jerome Brunet       2017-09-18  19  	select MDIO_DEVICE
1814cff26739de Bartosz Golaszewski 2020-07-05  20  	select MDIO_DEVRES
6073512cc8e2c4 Jerome Brunet       2017-09-18  21  	help
6073512cc8e2c4 Jerome Brunet       2017-09-18  22  	  Ethernet controllers are usually attached to PHY
6073512cc8e2c4 Jerome Brunet       2017-09-18  23  	  devices.  This option provides infrastructure for
6073512cc8e2c4 Jerome Brunet       2017-09-18  24  	  managing PHY devices.
6073512cc8e2c4 Jerome Brunet       2017-09-18  25  
Signature · 2 lines
0-DAY CI Kernel Test Service
https://01.org/lkp
#4 lore raw
In reply to Jakub Kicinski
I love your patch! Yet something to improve:

Hi Jakub,

I love your patch! Yet something to improve:

[auto build test ERROR on net-next/master]

url:    https://github.com/intel-lab-lkp/linux/commits/Jakub-Kicinski/net-pcs-xpcs-select-PHYLINK-in-Kconfig/20220621-042123
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git dbca1596bbb08318f5e3b3b99f8ca0a0d3830a65
config: x86_64-randconfig-a013-20220620
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project af6d2a0b6825e71965f3e2701a63c239fa0ad70f)

reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# https://github.com/intel-lab-lkp/linux/commit/a3120516f7ee66896bb0d3c90fe653ce0cb3a09f
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Jakub-Kicinski/net-pcs-xpcs-select-PHYLINK-in-Kconfig/20220621-042123 git checkout a3120516f7ee66896bb0d3c90fe653ce0cb3a09f COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=x86_64 randconfig COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=x86_64

If you fix the issue, kindly add following tag where applicable

All errors (new ones prefixed by >>):

>> drivers/net/phy/Kconfig:16:error: recursive dependency detected!

drivers/net/phy/Kconfig:16: symbol PHYLIB is selected by PHYLINK drivers/net/phy/Kconfig:6: symbol PHYLINK is selected by PCS_XPCS drivers/net/pcs/Kconfig:8: symbol PCS_XPCS depends on MDIO_DEVICE drivers/net/mdio/Kconfig:6: symbol MDIO_DEVICE is selected by PHYLIB For a resolution refer to Documentation/kbuild/kconfig-language.rst subsection "Kconfig recursive dependency limitations"

vim +16 drivers/net/phy/Kconfig

00db8189d984d6 Andy Fleming        2005-07-30   5  
9525ae83959b60 Russell King        2017-07-25   6  config PHYLINK
9525ae83959b60 Russell King        2017-07-25   7  	tristate
9525ae83959b60 Russell King        2017-07-25   8  	depends on NETDEVICES
9525ae83959b60 Russell King        2017-07-25   9  	select PHYLIB
9525ae83959b60 Russell King        2017-07-25  10  	select SWPHY
9525ae83959b60 Russell King        2017-07-25  11  	help
9525ae83959b60 Russell King        2017-07-25  12  	  PHYlink models the link between the PHY and MAC, allowing fixed
9525ae83959b60 Russell King        2017-07-25  13  	  configuration links, PHYs, and Serdes links with MAC level
9525ae83959b60 Russell King        2017-07-25  14  	  autonegotiation modes.
9525ae83959b60 Russell King        2017-07-25  15  
6073512cc8e2c4 Jerome Brunet       2017-09-18 @16  menuconfig PHYLIB
9e8d438e8ba43a Florian Fainelli    2018-04-27  17  	tristate "PHY Device support and infrastructure"
6073512cc8e2c4 Jerome Brunet       2017-09-18  18  	depends on NETDEVICES
6073512cc8e2c4 Jerome Brunet       2017-09-18  19  	select MDIO_DEVICE
1814cff26739de Bartosz Golaszewski 2020-07-05  20  	select MDIO_DEVRES
6073512cc8e2c4 Jerome Brunet       2017-09-18  21  	help
6073512cc8e2c4 Jerome Brunet       2017-09-18  22  	  Ethernet controllers are usually attached to PHY
6073512cc8e2c4 Jerome Brunet       2017-09-18  23  	  devices.  This option provides infrastructure for
6073512cc8e2c4 Jerome Brunet       2017-09-18  24  	  managing PHY devices.
6073512cc8e2c4 Jerome Brunet       2017-09-18  25  
Signature · 2 lines
0-DAY CI Kernel Test Service
https://01.org/lkp
author maintainer
#2 lore raw
In reply to kernel test robot
Quoted 21 lines · On Tue, 21 Jun 2022 05:49:57 +0800 kernel test robot wrote:

I love your patch! Yet something to improve:

[auto build test ERROR on net-next/master]

url:    https://github.com/intel-lab-lkp/linux/commits/Jakub-Kicinski/net-pcs-xpcs-select-PHYLINK-in-Kconfig/20220621-042123
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git dbca1596bbb08318f5e3b3b99f8ca0a0d3830a65
config: i386-tinyconfig
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
        # https://github.com/intel-lab-lkp/linux/commit/a3120516f7ee66896bb0d3c90fe653ce0cb3a09f
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Jakub-Kicinski/net-pcs-xpcs-select-PHYLINK-in-Kconfig/20220621-042123
        git checkout a3120516f7ee66896bb0d3c90fe653ce0cb3a09f
        make W=1 ARCH=i386  tinyconfig
        make W=1 ARCH=i386 

If you fix the issue, kindly add following tag where applicable

All errors (new ones prefixed by >>):

Quoted 7 lines
Quoted 1 line
Quoted 1 line

drivers/net/phy/Kconfig:16:error: recursive dependency detected!

drivers/net/phy/Kconfig:16: symbol PHYLIB is selected by PHYLINK drivers/net/phy/Kconfig:6: symbol PHYLINK is selected by PCS_XPCS drivers/net/pcs/Kconfig:8: symbol PCS_XPCS depends on MDIO_DEVICE drivers/net/mdio/Kconfig:6: symbol MDIO_DEVICE is selected by PHYLIB For a resolution refer to Documentation/kbuild/kconfig-language.rst subsection "Kconfig recursive dependency limitations"

Dunno what the best practice is in that case :S
I'll leave this to the experts.

#3 lore raw
Quoted 30 lines · Jakub Kicinski
Quoted 21 lines · On Tue, 21 Jun 2022 05:49:57 +0800 kernel test robot wrote:

I love your patch! Yet something to improve:

[auto build test ERROR on net-next/master]

url:    https://github.com/intel-lab-lkp/linux/commits/Jakub-Kicinski/net-pcs-xpcs-select-PHYLINK-in-Kconfig/20220621-042123
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git dbca1596bbb08318f5e3b3b99f8ca0a0d3830a65
config: i386-tinyconfig
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
        # https://github.com/intel-lab-lkp/linux/commit/a3120516f7ee66896bb0d3c90fe653ce0cb3a09f
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Jakub-Kicinski/net-pcs-xpcs-select-PHYLINK-in-Kconfig/20220621-042123
        git checkout a3120516f7ee66896bb0d3c90fe653ce0cb3a09f
        make W=1 ARCH=i386  tinyconfig
        make W=1 ARCH=i386 

If you fix the issue, kindly add following tag where applicable

All errors (new ones prefixed by >>):

Quoted 7 lines
Quoted 1 line
Quoted 1 line

drivers/net/phy/Kconfig:16:error: recursive dependency detected!

drivers/net/phy/Kconfig:16: symbol PHYLIB is selected by PHYLINK drivers/net/phy/Kconfig:6: symbol PHYLINK is selected by PCS_XPCS drivers/net/pcs/Kconfig:8: symbol PCS_XPCS depends on MDIO_DEVICE drivers/net/mdio/Kconfig:6: symbol MDIO_DEVICE is selected by PHYLIB For a resolution refer to Documentation/kbuild/kconfig-language.rst subsection "Kconfig recursive dependency limitations"

Quoted 2 lines

Dunno what the best practice is in that case :S
I'll leave this to the experts.

Would it work to make all the PCS drivers depend on PHYLINK ?

Signature · 2 lines
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!