mbox series

[net-next,0/6] net: pcs: add supported_interfaces bitmap for PCS

Message ID Z3fG9oTY9F9fCYHv@shell.armlinux.org.uk (mailing list archive)
Headers show
Series net: pcs: add supported_interfaces bitmap for PCS | expand

Message

Russell King (Oracle) Jan. 3, 2025, 11:16 a.m. UTC
Hi,

This series adds supported_interfaces for PCS, which gives MAC code a
way to determine the interface modes that the PCS supports without
having to implement functions such as xpcs_get_interfaces(), or
workarounds such as in

https://lore.kernel.org/r/20241213090526.71516-3-maxime.chevallier@bootlin.com

Patch 1 adds the new bitmask to struct phylink_pcs, and code within
phylink to validate that the PCS returned by the MAC driver supports
the interface mode - but only if this bitmask is non-empty.

Patch 2 through 4 fills in the interface modes for XPCS, Mediatek LynxI
and Lynx PCS.

Patch 5 adds support to stmmac to make use of this bitmask when filling
in phylink_config.supported_interfaces, eliminating the call to
xpcs_get_interfaces.

As xpcs_get_interfaces() is now unused outside of pcs-xpcs.c, patch 6
makes this function static and removes it from the header file.

 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 11 +++++++++--
 drivers/net/pcs/pcs-lynx.c                        | 13 +++++++++++++
 drivers/net/pcs/pcs-mtk-lynxi.c                   |  4 ++++
 drivers/net/pcs/pcs-xpcs.c                        |  5 +++--
 drivers/net/phy/phylink.c                         | 11 +++++++++++
 include/linux/pcs/pcs-xpcs.h                      |  1 -
 include/linux/phylink.h                           |  3 +++
 7 files changed, 43 insertions(+), 5 deletions(-)

Comments

patchwork-bot+netdevbpf@kernel.org Jan. 7, 2025, 12:40 a.m. UTC | #1
Hello:

This series was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Fri, 3 Jan 2025 11:16:06 +0000 you wrote:
> Hi,
> 
> This series adds supported_interfaces for PCS, which gives MAC code a
> way to determine the interface modes that the PCS supports without
> having to implement functions such as xpcs_get_interfaces(), or
> workarounds such as in
> 
> [...]

Here is the summary with links:
  - [net-next,1/6] net: phylink: add support for PCS supported_interfaces bitmap
    https://git.kernel.org/netdev/net-next/c/fbb9a9d263a6
  - [net-next,2/6] net: pcs: xpcs: fill in PCS supported_interfaces
    https://git.kernel.org/netdev/net-next/c/906909fabb81
  - [net-next,3/6] net: pcs: mtk-lynxi: fill in PCS supported_interfaces
    https://git.kernel.org/netdev/net-next/c/b87d4ee16bb4
  - [net-next,4/6] net: pcs: lynx: fill in PCS supported_interfaces
    https://git.kernel.org/netdev/net-next/c/b0f88c1b9a53
  - [net-next,5/6] net: stmmac: use PCS supported_interfaces
    https://git.kernel.org/netdev/net-next/c/d13cefbb108e
  - [net-next,6/6] net: pcs: xpcs: make xpcs_get_interfaces() static
    https://git.kernel.org/netdev/net-next/c/2410719cdd49

You are awesome, thank you!