opnsense-src/sys/dev/mlx5
Ariel Ehrenberg 253a1fa16b mlx5: Fix handling of port_module_event
Remove the array of port module status and instead save module status
and module number.

At boot, for each PCI function driver get event from fw about module
status. The event contains module number and module status. Driver
stores module number and module status..  When user (ifconfig) ask for
modules information, for each pci function driver first queries fw to
get module number of current pci function, then driver compares the
module number to the module number it stored before and if it matches
and module status is "plugged and enabled" then driver queries fw for
the eprom information of that module number and return it to the
caller.

In fact fw could have concluded that required module number of the
current pci function, but fw is not implemented this way. current
design of PRM/FW is that MCIA register handling is only aware of
modules, not the pci function->module connections.  FW is designed to
take the module number written to MCIA and write/read the content
to/from the associated module's EPROM.

So, based on current FW design, we must supply the module num so fw
can find the corresponding I2C interface of the module to write/read.

Sponsored by:	NVidia networking
MFC after:	1 week
2024-11-23 12:59:26 +02:00
..
mlx5_accel mlx5_ipsec: add enough #ifdef IPSEC_OFFLOAD to make LINT_NOIP compilable 2024-10-10 16:18:11 +03:00
mlx5_core mlx5: Fix handling of port_module_event 2024-11-23 12:59:26 +02:00
mlx5_en mlx5en: fix the sign of mlx5e_tls_st_init() error, convert from Linux to BSD 2024-11-23 12:09:50 +02:00
mlx5_fpga sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
mlx5_fpga_tools sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
mlx5_ib mlx5: optimize ilog2 calculation 2024-09-28 16:24:44 -05:00
mlx5_lib mlx5en: add IPSEC_OFFLOAD support 2024-07-30 18:00:04 +03:00
cmd.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
cq.h mlx5en: add IPSEC_OFFLOAD support 2024-07-30 18:00:04 +03:00
crypto.h mlx5en: add IPSEC_OFFLOAD support 2024-07-30 18:00:04 +03:00
device.h dev/mlx5: remove some duplicated macros from device.h 2024-09-04 11:49:38 +03:00
diagnostics.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
doorbell.h mlx5en: add IPSEC_OFFLOAD support 2024-07-30 18:00:04 +03:00
driver.h mlx5: Fix handling of port_module_event 2024-11-23 12:59:26 +02:00
fs.h mlx5en: add IPSEC_OFFLOAD support 2024-07-30 18:00:04 +03:00
mlx5_ifc.h mlx5en: add IPSEC_OFFLOAD support 2024-07-30 18:00:04 +03:00
mlx5_rdma_if.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
mlx5io.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
mpfs.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
port.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
qp.h mlx5en: add IPSEC_OFFLOAD support 2024-07-30 18:00:04 +03:00
srq.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
tls.h mlx5en: add IPSEC_OFFLOAD support 2024-07-30 18:00:04 +03:00
vport.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00