netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [net-next PATCH v3 00/10] net: phy: Add support for fbnic PHY w/ 25G, 50G, and 100G support
@ 2025-11-10 16:00 Alexander Duyck
  2025-11-10 16:00 ` [net-next PATCH v3 01/10] net: phy: Add support for 25, 50 and 100Gbps PMA to genphy_c45_read_pma Alexander Duyck
                   ` (10 more replies)
  0 siblings, 11 replies; 17+ messages in thread
From: Alexander Duyck @ 2025-11-10 16:00 UTC (permalink / raw)
  To: netdev; +Cc: kuba, kernel-team, andrew+netdev, hkallweit1, linux, pabeni,
	davem

To transition the fbnic driver to using the XPCS driver we need to address
the fact that we need a representation for the FW managed PMA/PMD that is
actually a SerDes PHY to handle link bouncing during link training.

This patch set first introduces the necessary bits to the 
generic c45 driver code to enable it to read 25G, 50G, and 100G modes from 
the PHY. After that we update the XPCS driver to to do the same.

The rest of this patch set enables the changes to fbnic to make use of these
interfaces and expose a PMA/PMD that can provide a necessary link delay to 
avoid link flapping in the event that a cable is disconnected and 
reconnected, and to correctly provide the count for the link down events.

With this we have the basic groundwork laid as with this all the bits and 
pieces are in place in terms of reading the configuration. The general plan for 
follow-on patch sets is to start looking at enabling changing the configuration 
in environments where that is supported.

v2: Added XPCS code to the patch set
    Dropped code adding bits for extended ability registers
    Switched from enabling code in generic c45 to enabling code in fbnic_phy.c
    Fixed several bugs related to phy state machine and use of resume
    Moved PHY assignment into ndo_init/uninit
    Renamed fbnic_swmii.c to fbnic_mdio.c
v3: Modified XPCS to have it read link from PMA instead of using a phydev
    Fixed naming for PCS vs PMA for CTRL1 register speed bit values
    Added logic to XPCS to get speed from PCS CTRL1 register
    Swapped fbnic link delay timer from tracking training start to end
    Dropped driver code for fbnic_phy.c and phydev code from patches
    Updated patch naming to match expectations for PCS changes
    Cleaned up dead code and defines from earlier versions

---

Alexander Duyck (10):
      net: phy: Add support for 25, 50 and 100Gbps PMA to genphy_c45_read_pma
      net: phy: Rename MDIO_CTRL1_SPEED for 2.5G and 5G to reflect PMA values
      net: pcs: xpcs: Add support for 25G, 50G, and 100G interfaces
      net: pcs: xpcs: Fix PMA identifier handling in XPCS
      net: pcs: xpcs: Add support for FBNIC 25G, 50G, 100G PMA
      fbnic: Rename PCS IRQ to MAC IRQ as it is actually a MAC interrupt
      fbnic: Add logic to track PMD state via MAC/PCS signals
      fbnic: Cleanup handling for link down event statistics
      fbnic: Add SW shim for MDIO interface to PMA/PMD and PCS
      fbnic: Replace use of internal PCS w/ Designware XPCS


 drivers/net/ethernet/meta/Kconfig             |   1 +
 drivers/net/ethernet/meta/fbnic/Makefile      |   1 +
 drivers/net/ethernet/meta/fbnic/fbnic.h       |  15 +-
 drivers/net/ethernet/meta/fbnic/fbnic_csr.h   |   2 +
 .../net/ethernet/meta/fbnic/fbnic_ethtool.c   |   9 +
 drivers/net/ethernet/meta/fbnic/fbnic_irq.c   |  45 +++--
 drivers/net/ethernet/meta/fbnic/fbnic_mac.c   |  71 ++++---
 drivers/net/ethernet/meta/fbnic/fbnic_mac.h   |  40 +++-
 drivers/net/ethernet/meta/fbnic/fbnic_mdio.c  | 190 ++++++++++++++++++
 .../net/ethernet/meta/fbnic/fbnic_netdev.c    |  11 +-
 .../net/ethernet/meta/fbnic/fbnic_netdev.h    |   6 +-
 drivers/net/ethernet/meta/fbnic/fbnic_pci.c   |  17 +-
 .../net/ethernet/meta/fbnic/fbnic_phylink.c   | 163 ++++++++-------
 drivers/net/pcs/pcs-xpcs.c                    | 135 ++++++++++++-
 drivers/net/phy/phy-c45.c                     |  17 +-
 include/linux/pcs/pcs-xpcs.h                  |   4 +-
 include/uapi/linux/mdio.h                     |  18 +-
 17 files changed, 592 insertions(+), 153 deletions(-)
 create mode 100644 drivers/net/ethernet/meta/fbnic/fbnic_mdio.c

--


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

end of thread, other threads:[~2025-11-12 16:32 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-10 16:00 [net-next PATCH v3 00/10] net: phy: Add support for fbnic PHY w/ 25G, 50G, and 100G support Alexander Duyck
2025-11-10 16:00 ` [net-next PATCH v3 01/10] net: phy: Add support for 25, 50 and 100Gbps PMA to genphy_c45_read_pma Alexander Duyck
2025-11-10 16:01 ` [net-next PATCH v3 02/10] net: phy: Rename MDIO_CTRL1_SPEED for 2.5G and 5G to reflect PMA values Alexander Duyck
2025-11-12  8:53   ` Maxime Chevallier
2025-11-12 10:42   ` Russell King (Oracle)
2025-11-12 16:32     ` Alexander H Duyck
2025-11-10 16:01 ` [net-next PATCH v3 03/10] net: pcs: xpcs: Add support for 25G, 50G, and 100G interfaces Alexander Duyck
2025-11-10 16:01 ` [net-next PATCH v3 04/10] net: pcs: xpcs: Fix PMA identifier handling in XPCS Alexander Duyck
2025-11-10 16:01 ` [net-next PATCH v3 05/10] net: pcs: xpcs: Add support for FBNIC 25G, 50G, 100G PMA Alexander Duyck
2025-11-10 16:01 ` [net-next PATCH v3 06/10] fbnic: Rename PCS IRQ to MAC IRQ as it is actually a MAC interrupt Alexander Duyck
2025-11-10 16:01 ` [net-next PATCH v3 07/10] fbnic: Add logic to track PMD state via MAC/PCS signals Alexander Duyck
2025-11-10 16:01 ` [net-next PATCH v3 08/10] fbnic: Cleanup handling for link down event statistics Alexander Duyck
2025-11-10 16:02 ` [net-next PATCH v3 09/10] fbnic: Add SW shim for MDIO interface to PMA/PMD and PCS Alexander Duyck
2025-11-10 16:02 ` [net-next PATCH v3 10/10] fbnic: Replace use of internal PCS w/ Designware XPCS Alexander Duyck
2025-11-11 14:23 ` [net-next PATCH v3 00/10] net: phy: Add support for fbnic PHY w/ 25G, 50G, and 100G support Paolo Abeni
2025-11-11 15:23   ` Jakub Kicinski
2025-11-11 16:09     ` Alexander Duyck

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).