]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ixgbe: pass bi->xdp to ixgbe_construct_skb_zc() directly
authorAlexander Lobakin <alexandr.lobakin@intel.com>
Wed, 8 Dec 2021 14:07:00 +0000 (15:07 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 8 Apr 2022 11:58:00 +0000 (13:58 +0200)
commite2225fccce7d65a152887d0b49622d56cb0851c2
tree7426a3938b38c22dfbffdb783d66dab2d94934b5
parentf0252b99631e4acaf8cd533713f5eb95a7cc70a4
ixgbe: pass bi->xdp to ixgbe_construct_skb_zc() directly

[ Upstream commit 1fbdaa13386804a31eefd3db3c5fe00e80ce9bc3 ]

To not dereference bi->xdp each time in ixgbe_construct_skb_zc(),
pass bi->xdp as an argument instead of bi. We can also call
xsk_buff_free() outside of the function as well as assign bi->xdp
to NULL, which seems to make it closer to its name.

Suggested-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
Signed-off-by: Alexander Lobakin <alexandr.lobakin@intel.com>
Tested-by: Sandeep Penigalapati <sandeep.penigalapati@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/intel/ixgbe/ixgbe_xsk.c