ice: update xdp_rxq_info::frag_size for ZC enabled Rx queue
authorMaciej Fijalkowski <maciej.fijalkowski@intel.com>
Wed, 24 Jan 2024 19:15:59 +0000 (20:15 +0100)
committerAlexei Starovoitov <ast@kernel.org>
Thu, 25 Jan 2024 00:24:07 +0000 (16:24 -0800)
commit3de38c87174225487fc93befeea7d380db80aef6
treecb98a6eac4860b6fea2fee81820f8be67e963a92
parent290779905d09d5fdf6caa4f58ddefc3f4db0c0a9
ice: update xdp_rxq_info::frag_size for ZC enabled Rx queue

Now that ice driver correctly sets up frag_size in xdp_rxq_info, let us
make it work for ZC multi-buffer as well. ice_rx_ring::rx_buf_len for ZC
is being set via xsk_pool_get_rx_frame_size() and this needs to be
propagated up to xdp_rxq_info.

Use a bigger hammer and instead of unregistering only xdp_rxq_info's
memory model, unregister it altogether and register it again and have
xdp_rxq_info with correct frag_size value.

Fixes: 1bbc04de607b ("ice: xsk: add RX multi-buffer support")
Signed-off-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
Link: https://lore.kernel.org/r/20240124191602.566724-9-maciej.fijalkowski@intel.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
drivers/net/ethernet/intel/ice/ice_base.c