summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/ixgbevf/ixgbevf.h
diff options
context:
space:
mode:
authorEmil Tantilov <emil.s.tantilov@intel.com>2017-12-11 10:37:10 -0800
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2018-01-26 07:46:50 -0800
commit35074d698d4213874e93a4b8561360241698b104 (patch)
treed02010830316904e08f8484bfe376b63ad4478a5 /drivers/net/ethernet/intel/ixgbevf/ixgbevf.h
parent16b359498b12e83b795be160f105d7c3dc4a8bb5 (diff)
downloadop-kernel-dev-35074d698d4213874e93a4b8561360241698b104.zip
op-kernel-dev-35074d698d4213874e93a4b8561360241698b104.tar.gz
ixgbevf: update code to better handle incrementing page count
Based on commit bd4171a5d4c2 ("igb: update code to better handle incrementing page count") Update the driver code so that we do bulk updates of the page reference count instead of just incrementing it by one reference at a time. The advantage to doing this is that we cut down on atomic operations and this in turn should give us a slight improvement in cycles per packet. In addition if we eventually move this over to using build_skb the gains will be more noticeable. Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Krishneil Singh <krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/ixgbevf/ixgbevf.h')
-rw-r--r--drivers/net/ethernet/intel/ixgbevf/ixgbevf.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/net/ethernet/intel/ixgbevf/ixgbevf.h b/drivers/net/ethernet/intel/ixgbevf/ixgbevf.h
index b1da9f4..c70a789 100644
--- a/drivers/net/ethernet/intel/ixgbevf/ixgbevf.h
+++ b/drivers/net/ethernet/intel/ixgbevf/ixgbevf.h
@@ -62,7 +62,12 @@ struct ixgbevf_tx_buffer {
struct ixgbevf_rx_buffer {
dma_addr_t dma;
struct page *page;
- unsigned int page_offset;
+#if (BITS_PER_LONG > 32) || (PAGE_SIZE >= 65536)
+ __u32 page_offset;
+#else
+ __u16 page_offset;
+#endif
+ __u16 pagecnt_bias;
};
struct ixgbevf_stats {
OpenPOWER on IntegriCloud