netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH bpf-next 0/6] Enhancing selftests/xsk Framework: Maximum and Minimum Ring Configurations
@ 2024-03-15 14:07 Tushar Vyavahare
  2024-03-15 14:07 ` [PATCH bpf-next 1/6] tools/include: add ethtool_ringparam definition to UAPI header Tushar Vyavahare
                   ` (5 more replies)
  0 siblings, 6 replies; 15+ messages in thread
From: Tushar Vyavahare @ 2024-03-15 14:07 UTC (permalink / raw)
  To: bpf
  Cc: netdev, bjorn, magnus.karlsson, maciej.fijalkowski,
	jonathan.lemon, davem, kuba, pabeni, ast, daniel,
	tirthendu.sarkar, tushar.vyavahare

Please find enclosed a patch set that introduces enhancements and new test
cases to the selftests/xsk framework. These test the robustness and
reliability of AF_XDP across both minimal and maximal ring size
configurations.

While running these tests, a bug [1] was identified when the batch size is
roughly the same as the NIC ring size. This has now been addressed by
Maciej's fix.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/commit/?id=913eda2b08cc49d31f382579e2be34c2709eb789

Patch Summary:

1: Adds the definition of ethtool_ringparam to the UAPI header, a
   necessary step for the subsequent patches to run tests with various
   ring sizes.

2: Modifies the BATCH_SIZE from a constant to a variable, batch_size, to
   support dynamic modification at runtime for testing different hardware
   ring sizes.

3: Implements a function, get_hw_ring_size, to retrieve the current
   maximum interface size and store this information in the hw_ring
   structure.

4: Implements a new function, set_hw_ring_size, which allows for the
   dynamic configuration of the ring size within an interface.

5: Adds a new test case that puts the AF_XDP driver under stress by
   configuring minimal hardware and software ring sizes, verifying its
   functionality under constrained conditions.

6: Enhances the framework by adding a new test case that evaluates the
   maximum ring sizes for AF_XDP, ensuring its reliability under maximum
   ring utilization.

Testing Strategy:

Check the system in extreme scenarios, such as maximum and minimum
configurations. This helps identify and fix any bugs that may occur.

Tushar Vyavahare (6):
  tools/include: add ethtool_ringparam definition to UAPI header
  selftests/xsk: make batch size variable
  selftests/xsk: implement get_hw_ring_size function to retrieve current
    and max interface size
  selftests/xsk: implement set_hw_ring_size function to configure
    interface ring size
  selftests/xsk: test AF_XDP functionality under minimal ring
    configurations
  selftests/xsk: enhance framework with a new test case for AF_XDP under
    max ring sizes

Signed-off-by: Tushar Vyavahare <tushar.vyavahare@intel.com>

---
 tools/include/uapi/linux/ethtool.h       |  41 ++++++
 tools/testing/selftests/bpf/xskxceiver.c | 155 +++++++++++++++++++++--
 tools/testing/selftests/bpf/xskxceiver.h |  14 +-
 3 files changed, 200 insertions(+), 10 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2024-03-19  6:54 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-15 14:07 [PATCH bpf-next 0/6] Enhancing selftests/xsk Framework: Maximum and Minimum Ring Configurations Tushar Vyavahare
2024-03-15 14:07 ` [PATCH bpf-next 1/6] tools/include: add ethtool_ringparam definition to UAPI header Tushar Vyavahare
2024-03-15 17:33   ` Stanislav Fomichev
2024-03-19  6:42     ` Vyavahare, Tushar
2024-03-15 14:07 ` [PATCH bpf-next 2/6] selftests/xsk: make batch size variable Tushar Vyavahare
2024-03-15 14:07 ` [PATCH bpf-next 3/6] selftests/xsk: implement get_hw_ring_size function to retrieve current and max interface size Tushar Vyavahare
2024-03-15 17:40   ` Stanislav Fomichev
2024-03-19  6:47     ` Vyavahare, Tushar
2024-03-15 14:07 ` [PATCH bpf-next 4/6] selftests/xsk: implement set_hw_ring_size function to configure interface ring size Tushar Vyavahare
2024-03-15 15:47   ` Alexei Starovoitov
2024-03-19  6:54     ` Vyavahare, Tushar
2024-03-15 17:44   ` Stanislav Fomichev
2024-03-19  6:52     ` Vyavahare, Tushar
2024-03-15 14:07 ` [PATCH bpf-next 5/6] selftests/xsk: test AF_XDP functionality under minimal ring configurations Tushar Vyavahare
2024-03-15 14:07 ` [PATCH bpf-next 6/6] selftests/xsk: enhance framework with a new test case for AF_XDP under max ring sizes Tushar Vyavahare

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).