]> www.infradead.org Git - users/jedix/linux-maple.git/commit
selftests/xsk: Add packet stream replacement function
authorTushar Vyavahare <tushar.vyavahare@intel.com>
Thu, 10 Apr 2025 03:31:15 +0000 (03:31 +0000)
committerMartin KaFai Lau <martin.lau@kernel.org>
Thu, 10 Apr 2025 17:07:48 +0000 (10:07 -0700)
commit3e730fe2af867d49b8c0eed65fe824079f7f377a
tree57dc93a127516b8460129e315e31aa520376fb6c
parent0f681b0ecd190fb4516bb34cec227296b10533d1
selftests/xsk: Add packet stream replacement function

Add pkt_stream_replace_ifobject function to replace the packet stream for
a given ifobject.

Enable separate TX and RX packet replacement, allowing RX side packet
length adjustments using bpf_xdp_adjust_tail() in the upcoming patch.
Currently, pkt_stream_replace() works on both TX and RX packet streams,
and this new function provides the ability to modify one of them.

Reviewed-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
Signed-off-by: Tushar Vyavahare <tushar.vyavahare@intel.com>
Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org>
Link: https://patch.msgid.link/20250410033116.173617-2-tushar.vyavahare@intel.com
tools/testing/selftests/bpf/xskxceiver.c