netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] net: pcs: xpcs: depends on PHYLINK in Kconfig
@ 2022-06-21  7:55 Paolo Abeni
  2022-06-21 19:50 ` Jakub Kicinski
  0 siblings, 1 reply; 10+ messages in thread
From: Paolo Abeni @ 2022-06-21  7:55 UTC (permalink / raw)
  To: netdev
  Cc: Andrew Lunn, Heiner Kallweit, Russell King, David S. Miller,
	Eric Dumazet, Jakub Kicinski, Ong Boon Leong,
	Russell King (Oracle)

This is another attempt at fixing:

>> 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!

We can't select PHYLINK, or that will trigger a circular dependency
PHYLINK already selects PHYLIB, which in turn selects MDIO_DEVICE:
replacing the MDIO_DEVICE dependency with PHYLINK will pull all the
required configs.

Link: https://lore.kernel.org/netdev/20220620201915.1195280-1-kuba@kernel.org/
Reported-by: kernel test robot <lkp@intel.com>
Fixes: b47aec885bcd ("net: pcs: xpcs: add CL37 1000BASE-X AN support")
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
---
 drivers/net/pcs/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/pcs/Kconfig b/drivers/net/pcs/Kconfig
index 22ba7b0b476d..70fd6a03e982 100644
--- a/drivers/net/pcs/Kconfig
+++ b/drivers/net/pcs/Kconfig
@@ -7,7 +7,7 @@ menu "PCS device drivers"
 
 config PCS_XPCS
 	tristate "Synopsys DesignWare XPCS controller"
-	depends on MDIO_DEVICE && MDIO_BUS
+	depends on PHYLINK && MDIO_BUS
 	help
 	  This module provides helper functions for Synopsys DesignWare XPCS
 	  controllers.
-- 
2.35.3


^ permalink raw reply related	[flat|nested] 10+ messages in thread
* [PATCH net-next] net: pcs: xpcs: depends on PHYLINK in Kconfig
@ 2022-06-23 20:29 Jakub Kicinski
  2022-06-25  6:00 ` patchwork-bot+netdevbpf
  0 siblings, 1 reply; 10+ messages in thread
From: Jakub Kicinski @ 2022-06-23 20:29 UTC (permalink / raw)
  To: davem
  Cc: netdev, edumazet, pabeni, Jakub Kicinski, kernel test robot,
	andrew, hkallweit1, linux, rmk+kernel, boon.leong.ong

This is yet another attempt at fixing:

>> 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!

Switch XPCS to be invisible, as Russell points out it's
"selected" by its consumers. Drop the dependency on MDIO_BUS
as "depends" is meaningless on "selected" symbols.

Reported-by: kernel test robot <lkp@intel.com>
Fixes: b47aec885bcd ("net: pcs: xpcs: add CL37 1000BASE-X AN support")
Link: https://lore.kernel.org/netdev/20220620201915.1195280-1-kuba@kernel.org/
Link: https://lore.kernel.org/r/20220622083521.0de3ea5c@kernel.org/
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
---
CC: andrew@lunn.ch
CC: hkallweit1@gmail.com
CC: linux@armlinux.org.uk
CC: rmk+kernel@armlinux.org.uk
CC: boon.leong.ong@intel.com
---
 drivers/net/pcs/Kconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/pcs/Kconfig b/drivers/net/pcs/Kconfig
index 22ba7b0b476d..f778e5155fae 100644
--- a/drivers/net/pcs/Kconfig
+++ b/drivers/net/pcs/Kconfig
@@ -6,8 +6,8 @@
 menu "PCS device drivers"
 
 config PCS_XPCS
-	tristate "Synopsys DesignWare XPCS controller"
-	depends on MDIO_DEVICE && MDIO_BUS
+	tristate
+	select PHYLINK
 	help
 	  This module provides helper functions for Synopsys DesignWare XPCS
 	  controllers.
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2022-06-25  6:00 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-06-21  7:55 [PATCH net-next] net: pcs: xpcs: depends on PHYLINK in Kconfig Paolo Abeni
2022-06-21 19:50 ` Jakub Kicinski
2022-06-22 13:50   ` Paolo Abeni
2022-06-22 14:15   ` Russell King (Oracle)
2022-06-22 15:35     ` Jakub Kicinski
2022-06-22 15:42       ` Paolo Abeni
2022-06-22 23:12         ` Jakub Kicinski
2022-06-23 14:00           ` Paolo Abeni
  -- strict thread matches above, loose matches on Subject: below --
2022-06-23 20:29 Jakub Kicinski
2022-06-25  6:00 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).