Re: [Intel-wired-lan] [net-next v3 1/2] e1000e: Link NAPI instances to queues and IRQs

From: Avigail Dahan
Date: Tue Oct 08 2024 - 09:46:02 EST




On 30/09/2024 20:12, Joe Damato wrote:
Add support for netdev-genl, allowing users to query IRQ, NAPI, and queue
information.

After this patch is applied, note the IRQs assigned to my NIC:

$ cat /proc/interrupts | grep ens | cut -f1 --delimiter=':'
50
51
52

While e1000e allocates 3 IRQs (RX, TX, and other), it looks like e1000e
only has a single NAPI, so I've associated the NAPI with the RX IRQ (50
on my system, seen above).

Note the output from the cli:

$ ./tools/net/ynl/cli.py --spec Documentation/netlink/specs/netdev.yaml \
--dump napi-get --json='{"ifindex": 2}'
[{'id': 145, 'ifindex': 2, 'irq': 50}]

This device supports only 1 rx and 1 tx queue. so querying that:

$ ./tools/net/ynl/cli.py --spec Documentation/netlink/specs/netdev.yaml \
--dump queue-get --json='{"ifindex": 2}'
[{'id': 0, 'ifindex': 2, 'napi-id': 145, 'type': 'rx'},
{'id': 0, 'ifindex': 2, 'napi-id': 145, 'type': 'tx'}]

Signed-off-by: Joe Damato <jdamato@xxxxxxxxxx>
---
drivers/net/ethernet/intel/e1000e/netdev.c | 11 +++++++++++
1 file changed, 11 insertions(+)

Tested-by: Avigail Dahan <avigailx.dahan@xxxxxxxxx>