aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/aquantia/atlantic/aq_cfg.h
diff options
context:
space:
mode:
authorIgor Russkikh <Igor.Russkikh@aquantia.com>2019-03-23 15:23:34 +0000
committerDavid S. Miller <davem@davemloft.net>2019-03-23 22:16:53 -0400
commit9773ef18b83d8acc5862ea7e727d6e4d52846dd7 (patch)
treed63bc6457458f5bc17b93e469ba70248defe7a31 /drivers/net/ethernet/aquantia/atlantic/aq_cfg.h
parentnet: aquantia: optimize rx performance by page reuse strategy (diff)
downloadlinux-dev-9773ef18b83d8acc5862ea7e727d6e4d52846dd7.tar.xz
linux-dev-9773ef18b83d8acc5862ea7e727d6e4d52846dd7.zip
net: aquantia: Introduce rx refill threshold value
Before that, we've refilled ring even on single descriptor move. Under high packet load that caused page allocation logic to be triggered too often. That made overall ring processing slower. Moreover, with page buffer reuse implemented, we should give a chance higher networking levels to process received packets faster, release the pages they consumed and therefore give a higher chance for these pages to be reused. RX ring is now refilled only when AQ_CFG_RX_REFILL_THRES or more descriptors were processed (32 by default). Under regular traffic this gives quite enough time for packet to be consumed and page to be reused. Signed-off-by: Igor Russkikh <igor.russkikh@aquantia.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/aquantia/atlantic/aq_cfg.h')
-rw-r--r--drivers/net/ethernet/aquantia/atlantic/aq_cfg.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/aquantia/atlantic/aq_cfg.h b/drivers/net/ethernet/aquantia/atlantic/aq_cfg.h
index 80c16ab87771..551c5cc1714b 100644
--- a/drivers/net/ethernet/aquantia/atlantic/aq_cfg.h
+++ b/drivers/net/ethernet/aquantia/atlantic/aq_cfg.h
@@ -38,6 +38,8 @@
#define AQ_CFG_TX_CLEAN_BUDGET 256U
+#define AQ_CFG_RX_REFILL_THRES 32U
+
#define AQ_CFG_RX_HDR_SIZE 256U
#define AQ_CFG_RX_PAGEORDER 0U