* [PATCH v2 -next 1/2] dpaa2: add select config for FSL_DPAA2_SWITCH
2026-03-09 12:50 [PATCH v2 -next 0/2] dpaa2: fix config relation with FSL_DPAA2_SWITCH Cai Xinchen
@ 2026-03-09 12:50 ` Cai Xinchen
2026-03-09 12:50 ` [PATCH v2 -next 2/2] dpaa2: compile dpaa2 even CONFIG_FSL_DPAA2_ETH=n Cai Xinchen
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Cai Xinchen @ 2026-03-09 12:50 UTC (permalink / raw)
To: ioana.ciornei, andrew+netdev, davem, edumazet, kuba, pabeni
Cc: netdev, linux-kernel, caixinchen1
Since the commit 84cba72956fd ("dpaa2-switch: integrate
the MAC endpoint support") included dpaa2-mac.o in the driver,
but it didn't select PCS_LYNX, PHYLINK and FSL_XGMAC_MDIO. it
will lead to link error, such as
undefined reference to `phylink_ethtool_ksettings_set'
undefined reference to `lynx_pcs_create_fwnode'
And the same reason as the commit d2624e70a2f53 ("dpaa2-eth: select
XGMAC_MDIO for MDIO bus support"), enable the FSL_XGMAC_MDIO Kconfig
option in order to have MDIO access to internal and external PHYs.
Fixes: 84cba72956fd ("dpaa2-switch: integrate the MAC endpoint support")
Suggested-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Cai Xinchen <caixinchen1@huawei.com>
---
drivers/net/ethernet/freescale/dpaa2/Kconfig | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/ethernet/freescale/dpaa2/Kconfig b/drivers/net/ethernet/freescale/dpaa2/Kconfig
index d029b69c3f18..44637ec7c25d 100644
--- a/drivers/net/ethernet/freescale/dpaa2/Kconfig
+++ b/drivers/net/ethernet/freescale/dpaa2/Kconfig
@@ -34,6 +34,9 @@ config FSL_DPAA2_SWITCH
tristate "Freescale DPAA2 Ethernet Switch"
depends on BRIDGE || BRIDGE=n
depends on NET_SWITCHDEV
+ select PHYLINK
+ select PCS_LYNX
+ select FSL_XGMAC_MDIO
help
Driver for Freescale DPAA2 Ethernet Switch. This driver manages
switch objects discovered on the Freeescale MC bus.
--
2.34.1
^ permalink raw reply related [flat|nested] 5+ messages in thread* [PATCH v2 -next 2/2] dpaa2: compile dpaa2 even CONFIG_FSL_DPAA2_ETH=n
2026-03-09 12:50 [PATCH v2 -next 0/2] dpaa2: fix config relation with FSL_DPAA2_SWITCH Cai Xinchen
2026-03-09 12:50 ` [PATCH v2 -next 1/2] dpaa2: add select config for FSL_DPAA2_SWITCH Cai Xinchen
@ 2026-03-09 12:50 ` Cai Xinchen
2026-03-10 18:00 ` [PATCH v2 -next 0/2] dpaa2: fix config relation with FSL_DPAA2_SWITCH Simon Horman
2026-03-11 8:02 ` Ioana Ciornei
3 siblings, 0 replies; 5+ messages in thread
From: Cai Xinchen @ 2026-03-09 12:50 UTC (permalink / raw)
To: ioana.ciornei, andrew+netdev, davem, edumazet, kuba, pabeni
Cc: netdev, linux-kernel, caixinchen1
CONFIG_FSL_DPAA2_ETH and CONFIG_FSL_DPAA2_SWITCH are not
associated, but the compilation of FSL_DPAA2_SWITCH depends on
the compilation of the dpaa2 folder. The files controlled by
CONFIG_FSL_DPAA2_SWITCH in the dpaa2 folder are not controlled
by CONFIG_FSL_DPAA2_ETH, except for the files controlled by
CONFIG_FSL_DPAA2_SWITCH. Therefore, removing the restriction will
not affect the compilation of the files in the directory.
Fixes: f48298d3fbfaa ("staging: dpaa2-switch: move the driver out of staging")
Suggested-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Cai Xinchen <caixinchen1@huawei.com>
---
drivers/net/ethernet/freescale/Makefile | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/freescale/Makefile b/drivers/net/ethernet/freescale/Makefile
index de7b31842233..d0a259e47960 100644
--- a/drivers/net/ethernet/freescale/Makefile
+++ b/drivers/net/ethernet/freescale/Makefile
@@ -22,6 +22,5 @@ ucc_geth_driver-objs := ucc_geth.o ucc_geth_ethtool.o
obj-$(CONFIG_FSL_FMAN) += fman/
obj-$(CONFIG_FSL_DPAA_ETH) += dpaa/
-obj-$(CONFIG_FSL_DPAA2_ETH) += dpaa2/
-
+obj-y += dpaa2/
obj-y += enetc/
--
2.34.1
^ permalink raw reply related [flat|nested] 5+ messages in thread* Re: [PATCH v2 -next 0/2] dpaa2: fix config relation with FSL_DPAA2_SWITCH
2026-03-09 12:50 [PATCH v2 -next 0/2] dpaa2: fix config relation with FSL_DPAA2_SWITCH Cai Xinchen
2026-03-09 12:50 ` [PATCH v2 -next 1/2] dpaa2: add select config for FSL_DPAA2_SWITCH Cai Xinchen
2026-03-09 12:50 ` [PATCH v2 -next 2/2] dpaa2: compile dpaa2 even CONFIG_FSL_DPAA2_ETH=n Cai Xinchen
@ 2026-03-10 18:00 ` Simon Horman
2026-03-11 8:02 ` Ioana Ciornei
3 siblings, 0 replies; 5+ messages in thread
From: Simon Horman @ 2026-03-10 18:00 UTC (permalink / raw)
To: Cai Xinchen
Cc: ioana.ciornei, andrew+netdev, davem, edumazet, kuba, pabeni,
netdev, linux-kernel
On Mon, Mar 09, 2026 at 12:50:16PM +0000, Cai Xinchen wrote:
> When compile FSL_DPAA2_SWITCH, it needs to set CONFIG_FSL_DPAA2_ETH=y,
> otherwise it cannot be compiled.
> And as Ioana Ciornei sugggested, FSL_DPAA2_SWITCH included dpaa2-mac.o in
> the driver, but it does not select PCS_LYNX, PHYLINK and FSL_XGMAC_MDIO
>
> v1->v2
> There is no code dependency between the dpaa2-switch driver and the
> dpaa2-eth, so use Makefile to control dpaa2-eth instead of using depending
> on in Kconfig.
> And add select PCS_LYNX, PHYLINK and FSL_XGMAC_MDIO for FSL_DPAA2_SWITCH.
Thanks.
For the series,
Reviewed-by: Simon Horman <horms@kernel.org>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2 -next 0/2] dpaa2: fix config relation with FSL_DPAA2_SWITCH
2026-03-09 12:50 [PATCH v2 -next 0/2] dpaa2: fix config relation with FSL_DPAA2_SWITCH Cai Xinchen
` (2 preceding siblings ...)
2026-03-10 18:00 ` [PATCH v2 -next 0/2] dpaa2: fix config relation with FSL_DPAA2_SWITCH Simon Horman
@ 2026-03-11 8:02 ` Ioana Ciornei
3 siblings, 0 replies; 5+ messages in thread
From: Ioana Ciornei @ 2026-03-11 8:02 UTC (permalink / raw)
To: Cai Xinchen
Cc: andrew+netdev, davem, edumazet, kuba, pabeni, netdev,
linux-kernel
On Mon, Mar 09, 2026 at 12:50:16PM +0000, Cai Xinchen wrote:
> When compile FSL_DPAA2_SWITCH, it needs to set CONFIG_FSL_DPAA2_ETH=y,
> otherwise it cannot be compiled.
> And as Ioana Ciornei sugggested, FSL_DPAA2_SWITCH included dpaa2-mac.o in
> the driver, but it does not select PCS_LYNX, PHYLINK and FSL_XGMAC_MDIO
>
> v1->v2
> There is no code dependency between the dpaa2-switch driver and the
> dpaa2-eth, so use Makefile to control dpaa2-eth instead of using depending
> on in Kconfig.
> And add select PCS_LYNX, PHYLINK and FSL_XGMAC_MDIO for FSL_DPAA2_SWITCH.
Thanks for submitting this!
Reviewed-by: Ioana Ciornei <ioana.ciornei@nxp.com>
^ permalink raw reply [flat|nested] 5+ messages in thread