Skip to content

net/mlx5: ICM page management in VHCA_ID mode

Tariq Toukan linux-rdma lkml netdev 2 versions – Applied

Status from this message: This series was applied to netdev/net-next.git (main)

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 1 replyApplied 3/3
  2. v13 patches 4 repliesSuperseded

Changes in v2 from the cover letter

- Cache vhca_id to type mapping to provide lockless lookup.
- Store the resolved type on each fw_page at allocation time so reclaim and release paths read it directly without any lookup.
- Reorder erase old key and insert new key on migrate function.
- Fixed comment on mlx5_satisfy_startup_pages.

Patches in v2 All 3 applied

#Subject and filesSizeRepliesApplied
1/3net/mlx5: Relax capability check for eswitch query pathsdrivers/net/ethernet/mellanox/mlx5/core/esw/ipsec.c drivers/net/ethernet/mellanox/mlx5/core/eswitch.c drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c+12 -100 repliesApplied
2/3net/mlx5: Make debugfs page counters by function type dynamicdrivers/net/ethernet/mellanox/mlx5/core/debugfs.c drivers/net/ethernet/mellanox/mlx5/core/main.c include/linux/mlx5/driver.h+42 -60 repliesApplied
3/3net/mlx5: Add VHCA_ID page management mode supportdrivers/net/ethernet/mellanox/mlx5/core/eswitch.c drivers/net/ethernet/mellanox/mlx5/core/eswitch.h drivers/net/ethernet/mellanox/mlx5/core/main.c +2 more+251 -621 replyApplied

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchAkiva GoldbergerMark Bloch
1/3R-b R-b
2/3R-b R-b
3/3R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH net-next V2 0/3] net/mlx5: ICM page management in VHCA_ID mode

Hi,

Find detailed description by Moshe below.

Regards,
Tariq

This series adds driver support for the VHCA_ID page management mode. When firmware and driver support this mode, ICM (Interconnect Context Memory) page management uses the device vhca_id as the function identifier in MANAGE_PAGES, QUERY_PAGES, and page request events instead of the legacy function_id + ec_function pair.

Background
Firmware can operate page management in two modes:
FUNC_ID mode (current): Function identity is (function_id, ec_function). This remains the default and is used for boot pages and when the new mode capability is not set.
VHCA_ID mode (new): Function identity is vhca_id only; ec_function is ignored. This aligns page management with the vhca_id-based model used by other firmware commands and simplifies identification on SmartNIC and multi-function setups.

---

V2:
- Cache vhca_id to type mapping to provide lockless lookup.
- Store the resolved type on each fw_page at allocation time so reclaim and release paths read it directly without any lookup.
- Reorder erase old key and insert new key on migrate function.
- Fixed comment on mlx5_satisfy_startup_pages.

V1: https://lore.kernel.org/all/[email protected]/

Moshe Shemesh (3):
net/mlx5: Relax capability check for eswitch query paths net/mlx5: Make debugfs page counters by function type dynamic net/mlx5: Add VHCA_ID page management mode support

 .../net/ethernet/mellanox/mlx5/core/debugfs.c |  39 ++-
 .../ethernet/mellanox/mlx5/core/esw/ipsec.c   |   2 +-
 .../net/ethernet/mellanox/mlx5/core/eswitch.c |  49 +++-
 .../net/ethernet/mellanox/mlx5/core/eswitch.h |   8 +
 .../mellanox/mlx5/core/eswitch_offloads.c     |  14 +-
 .../net/ethernet/mellanox/mlx5/core/main.c    |  10 +-
 .../ethernet/mellanox/mlx5/core/pagealloc.c   | 250 +++++++++++++-----
 include/linux/mlx5/driver.h                   |   9 +
 8 files changed, 304 insertions(+), 77 deletions(-)

base-commit: 7e0cccae6b45b12eaf71fc3ab8eb133bb50b28ad

Signature · 1 line
2.44.0