summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorWei Fang <wei.fang@nxp.com>2026-07-20 09:43:15 +0800
committerJakub Kicinski <kuba@kernel.org>2026-07-27 16:31:55 -0700
commitf0c1f31afd97abcdaa70d78ac556bad84fc41871 (patch)
tree912dc6e33f75c35321219d230503125fc03c9a3a /include
parent75b136cf0f6faca1d183f5c0be7a1773d11bfbc3 (diff)
net: enetc: use alloc_etherdev_mqs() to create netdev for VF driver
The VF driver uses alloc_etherdev_mq() with ENETC_MAX_NUM_TXQS as the queue count, which forces the TX and RX queue counts to be equal and uses a compile-time constant rather than the actual hardware capability. After enetc_get_si_caps() is called, si->num_tx_rings and si->num_rx_rings reflect the actual number of rings assigned to the VF by the PF. For the ENETC VF on LS1028A and the upcoming i.MX95/94, their SoCs have no more than 6 CPUs, and the number of TX/RX rings allocated to the VF is less than 8. Therefore, switch to alloc_etherdev_mqs() so that the TX and RX queue counts are set independently, each capped at ENETC_MAX_NUM_TXQS, based on the actual number of rings assigned to the VF by the PF. Note that if future SoCs have more than 6 CPUs and more than 6 RX rings allocated to VFs, the size of the int_vector array in struct enetc_ndev_priv will need to be modified. Similarly, if more than 8 TX rings are allocated to each int_vector, ENETC_MAX_NUM_TXQS will also need to be modified. Signed-off-by: Wei Fang <wei.fang@nxp.com> Reviewed-by: Joe Damato <joe@dama.to> Link: https://patch.msgid.link/20260720014317.1059359-14-wei.fang@oss.nxp.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions