ice: Fix XDP memory leak when NIC is brought up and down
authorKamil Maziarz <kamil.maziarz@intel.com>
Tue, 6 Jun 2023 10:33:58 +0000 (12:33 +0200)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Thu, 8 Jun 2023 18:41:40 +0000 (11:41 -0700)
commit78c50d6961fc05491ebbc71c35d87324b1a4f49a
tree5a2316521d2d46199bcfa772c82ac5f8c489af97
parent05a1308a2e08e4a375bf60eb4c6c057a201d81fc
ice: Fix XDP memory leak when NIC is brought up and down

Fix the buffer leak that occurs while switching
the port up and down with traffic and XDP by
checking for an active XDP program and freeing all empty TX buffers.

Fixes: efc2214b6047 ("ice: Add support for XDP")
Signed-off-by: Kamil Maziarz <kamil.maziarz@intel.com>
Tested-by: Chandan Kumar Rout <chandanx.rout@intel.com> (A Contingent Worker at Intel)
Acked-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/ice/ice_main.c