Hi
NXP Confidential > -----Original Message----- > From: Stephen Hemminger <[email protected]> > Sent: Monday, November 2, 2026 6:53 PM > To: Gagandeep Singh <[email protected]> > Cc: [email protected]; Hemant Agrawal <[email protected]> > Subject: Re: [PATCH v2 0/4] DPAA driver changes > > On Fri, 30 Oct 2026 10:13:14 +0530 > Gagandeep Singh <[email protected]> wrote: > > > V2-changes: > > - Fixed most of the AI comments. > > - added new patch: > > fix out-of-bounds read of mac_idx > > - removed drv_oldev, updated comments and notes. > > - fixes FQ shutdown > > - removed unwanted checks, updated open, updated snprintf. > > - updated commit messages. > > > > V1: > > - Adding OH port support. > > - Updates in shared ethernet code. > > - Congestion related code cleanup. > > > > Gagandeep Singh (2): > > bus/dpaa: fix out-of-bounds read of mac_idx array > > drivers: add offline (O/H) port device support > > > > Hemant Agrawal (1): > > net/dpaa: support non fmX-macY type of shared Ethernet name > > > > Jun Yang (1): > > drivers: add DPAA cgrid cleanup support > > > > doc/api/doxy-api-index.md | 1 + > > doc/guides/nics/dpaa.rst | 35 + > > drivers/bus/dpaa/base/fman/fman.c | 19 + > > drivers/bus/dpaa/base/qbman/qman.c | 61 ++ > > drivers/bus/dpaa/bus_dpaa_driver.h | 4 +- > > drivers/bus/dpaa/dpaa_bus.c | 66 +- > > drivers/bus/dpaa/dpaa_bus_base_symbols.c | 2 + > > drivers/bus/dpaa/include/fman.h | 6 +- > > drivers/bus/dpaa/include/fsl_qman.h | 28 + > > drivers/net/dpaa/dpaa_ethdev.c | 241 ++++++- > > drivers/net/dpaa/dpaa_ethdev.h | 3 + > > drivers/net/dpaa/dpaa_flow.c | 7 +- > > drivers/net/dpaa/dpaa_oldev.c | 875 +++++++++++++++++++++++ > > drivers/net/dpaa/meson.build | 11 +- > > drivers/net/dpaa/rte_pmd_dpaa_oldev.h | 188 +++++ > > 15 files changed, 1517 insertions(+), 30 deletions(-) create mode > > 100644 drivers/net/dpaa/dpaa_oldev.c create mode 100644 > > drivers/net/dpaa/rte_pmd_dpaa_oldev.h > > > > Review of [PATCH v2 0/4] DPAA offline port, shared MAC, cgrid cleanup > > Applied to next-net for-main (3b51e2e2f0). Each commit builds with - > Dwerror=true. > > Series > ------ > > The rte_pmd_dpaa_ol_* API is unchanged from v1 apart from renames and > Doxygen. The four functions still take no port_id and only pass a > caller-filled > struct to ioctl() on the out-of-tree /dev/cdx_ctrl driver. The dpaa.rst text > added in > v2 confirms the API is configuration for that kernel module, not for the DPDK > port. > It belongs in the vendor userspace library for cdx. Please drop > rte_pmd_dpaa_oldev.h and the exports. > > There are still no release notes for the offline port. > In V3, we've updated the rte_pmd_dpaa_ol_* APIs to be port-based by requiring a port_id argument. Each call now resolves the corresponding rte_eth_dev and verifies it is a valid DPAA offline port before proceeding, preventing use on invalid or unrelated ports. We also moved the control device handle (/dev/cdx_ctrl) from a process-wide global into the offline port's private data (dpaa_if::ol_fd). It is opened on first use and closed during dev_close(), ensuring its lifetime is tied to the port. Also added the release notes in V3. > > Patch 2/4 drivers: add offline (O/H) port device support > -------------------------------------------------------- > > Warning > > The commit message still says the port is "selected through the 'drv_oldev' > bus > device argument". v2 removed drv_oldev; the port is created when "-a > dpaa_bus:oldev1" is given. > > With only oldev1 present, dpaa_netcfg is NULL. v2 handles that in the two log > statements but not in the debug dump: > > #ifdef RTE_LIBRTE_DPAA_DEBUG_DRIVER > dump_netcfg(dpaa_netcfg, stdout); > #endif > > dump_netcfg() dereferences cfg_ptr->num_ethports unconditionally. Fold it into > the existing check: > > if (dpaa_netcfg) { > #ifdef RTE_LIBRTE_DPAA_DEBUG_DRIVER > dump_netcfg(dpaa_netcfg, stdout); > #endif > DPAA_BUS_DEBUG("Number of ethernet devices = %d", > dpaa_netcfg->num_ethports); > } > > Not addressed from v1: dpaa_oldev_queues_release() returns both FQIDs to the > allocator with qman_release_fqid(), but the kernel received them through > ASK_CTRL_SET_DPDK_INFO and is never told they are gone. There is no reset > ioctl for that. Until cdx provides one, do not release the two FQIDs on close. > > Info > > drv_bh_port is now checked against a key list, but it is still parsed in > dev_start(). A > missing drv_bh_port is only reported at start. Parse it once in > dpaa_ol_probe() > and fail probe if it is absent. > > The static_assert and comment added to dpaa_flow.c, and the > MEMMAC_REG_OFFSET removal in fman.h, are not part of the offline port. > Move the dpaa_flow.c change to 1/4, and mention the fman.h removal in the > commit message. > > > Patch 4/4 drivers: add DPAA cgrid cleanup support > ------------------------------------------------- > > Info > > dev_close() runs dpaa_cgr_stale_fq_cleanup() before shutting down the port's > own FQs. The scan therefore finds this port's live queues, logs each one as > "still > alive?", and shuts it down by FQID. The > qman_shutdown_fq() loop that follows then only sees FQs that are already OOS. > Shut down rx_queues[]/tx_queues[] first, then scan, so the scan only reports > FQs > left by a previous run. >

