]> git.baikalelectronics.ru Git - kernel.git/commit
ice: store the result of ice_rx_offset() onto ice_ring
authorMaciej Fijalkowski <maciej.fijalkowski@intel.com>
Mon, 18 Jan 2021 15:13:17 +0000 (16:13 +0100)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Fri, 12 Feb 2021 18:36:57 +0000 (10:36 -0800)
commit498dc0b568bc092b1432d885a6b1734f3817750d
tree3049aaf08ab480f46acea67d59baa05e3001e765
parent5e1b7d2f995de5453a386b572b4528b72476b440
ice: store the result of ice_rx_offset() onto ice_ring

Output of ice_rx_offset() is based on ethtool's priv flag setting, which
when changed, causes PF reset (disables napi, frees irqs, loads
different Rx mem model, etc.). This means that within napi its result is
constant and there is no reason to call it per each processed frame.

Add new 'rx_offset' field to ice_ring that is meant to hold the
ice_rx_offset() result and use it within ice_clean_rx_irq().
Furthermore, use it within ice_alloc_mapped_page().

Reviewed-by: Björn Töpel <bjorn.topel@intel.com>
Signed-off-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
Tested-by: Tony Brelinski <tonyx.brelinski@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/ice/ice_txrx.c
drivers/net/ethernet/intel/ice/ice_txrx.h