Message ID | 1459405129-12442-1-git-send-email-wenzhuo.lu@intel.com (mailing list archive) |
---|---|
State | Rejected, archived |
Headers |
Return-Path: <dev-bounces@dpdk.org> X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id C88B8569A; Thu, 31 Mar 2016 08:18:58 +0200 (CEST) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id 162285699 for <dev@dpdk.org>; Thu, 31 Mar 2016 08:18:56 +0200 (CEST) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga104.fm.intel.com with ESMTP; 30 Mar 2016 23:18:56 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.24,420,1455004800"; d="scan'208";a="678407775" Received: from shvmail01.sh.intel.com ([10.239.29.42]) by FMSMGA003.fm.intel.com with ESMTP; 30 Mar 2016 23:18:55 -0700 Received: from shecgisg004.sh.intel.com (shecgisg004.sh.intel.com [10.239.29.89]) by shvmail01.sh.intel.com with ESMTP id u2V6IrOZ025612; Thu, 31 Mar 2016 14:18:53 +0800 Received: from shecgisg004.sh.intel.com (localhost [127.0.0.1]) by shecgisg004.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id u2V6IogW012477; Thu, 31 Mar 2016 14:18:52 +0800 Received: (from wenzhuol@localhost) by shecgisg004.sh.intel.com (8.13.6/8.13.6/Submit) id u2V6IoWu012473; Thu, 31 Mar 2016 14:18:50 +0800 From: Wenzhuo Lu <wenzhuo.lu@intel.com> To: dev@dpdk.org Cc: Wenzhuo Lu <wenzhuo.lu@intel.com> Date: Thu, 31 Mar 2016 14:18:49 +0800 Message-Id: <1459405129-12442-1-git-send-email-wenzhuo.lu@intel.com> X-Mailer: git-send-email 1.7.4.1 Subject: [dpdk-dev] [PATCH] igb: change default RX wthresh back X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK <dev.dpdk.org> List-Unsubscribe: <http://dpdk.org/ml/options/dev>, <mailto:dev-request@dpdk.org?subject=unsubscribe> List-Archive: <http://dpdk.org/ml/archives/dev/> List-Post: <mailto:dev@dpdk.org> List-Help: <mailto:dev-request@dpdk.org?subject=help> List-Subscribe: <http://dpdk.org/ml/listinfo/dev>, <mailto:dev-request@dpdk.org?subject=subscribe> Errors-To: dev-bounces@dpdk.org Sender: "dev" <dev-bounces@dpdk.org> |
Commit Message
Wenzhuo Lu
March 31, 2016, 6:18 a.m. UTC
A problem is found on i350 VF. TX will happen once per 4
packets. If only 1~3 packets are received, they will not be
forwarded.
The reason is the default RX write-back threshold is changed
to 4. This patch changes the value back to 0, so every packet
can be handled immediately.
Fixes: 4a41c17dba18 (igb: set default thresholds based on MAC type)
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
---
drivers/net/e1000/igb_ethdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Comments
Hi Wenzhuo, > > A problem is found on i350 VF. TX will happen once per 4 > packets. If only 1~3 packets are received, they will not be > forwarded. > > The reason is the default RX write-back threshold is changed > to 4. This patch changes the value back to 0, so every packet > can be handled immediately. > > Fixes: 4a41c17dba18 (igb: set default thresholds based on MAC type) > Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com> > --- > drivers/net/e1000/igb_ethdev.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.c > index bd0ae26..34120ae 100644 > --- a/drivers/net/e1000/igb_ethdev.c > +++ b/drivers/net/e1000/igb_ethdev.c > @@ -64,7 +64,7 @@ > > #define IGB_DEFAULT_RX_PTHRESH ((hw->mac.type == e1000_i354) ? 12 : 8) > #define IGB_DEFAULT_RX_HTHRESH 8 > -#define IGB_DEFAULT_RX_WTHRESH ((hw->mac.type == e1000_82576) ? 1 : 4) > +#define IGB_DEFAULT_RX_WTHRESH 0 But that still doesn't prevent user from setting wthresh to whatever he likes inside rx_queue_setup(), so the problem persists right? As a side notice, it seems really bad practice to use implicit variables inside macro definition. Konstantin > > #define IGB_DEFAULT_TX_PTHRESH ((hw->mac.type == e1000_i354) ? 20 : 8) > #define IGB_DEFAULT_TX_HTHRESH 1 > -- > 1.9.3
Hi Konstantin, > -----Original Message----- > From: Ananyev, Konstantin > Sent: Thursday, March 31, 2016 3:30 PM > To: Lu, Wenzhuo; dev@dpdk.org > Cc: Lu, Wenzhuo > Subject: RE: [dpdk-dev] [PATCH] igb: change default RX wthresh back > > > Hi Wenzhuo, > > > > A problem is found on i350 VF. TX will happen once per 4 packets. If > > only 1~3 packets are received, they will not be forwarded. > > > > The reason is the default RX write-back threshold is changed to 4. > > This patch changes the value back to 0, so every packet can be handled > > immediately. > > > > Fixes: 4a41c17dba18 (igb: set default thresholds based on MAC type) > > Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com> > > --- > > drivers/net/e1000/igb_ethdev.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/net/e1000/igb_ethdev.c > > b/drivers/net/e1000/igb_ethdev.c index bd0ae26..34120ae 100644 > > --- a/drivers/net/e1000/igb_ethdev.c > > +++ b/drivers/net/e1000/igb_ethdev.c > > @@ -64,7 +64,7 @@ > > > > #define IGB_DEFAULT_RX_PTHRESH ((hw->mac.type == e1000_i354) ? 12 : > 8) > > #define IGB_DEFAULT_RX_HTHRESH 8 > > -#define IGB_DEFAULT_RX_WTHRESH ((hw->mac.type == e1000_82576) ? > 1 : 4) > > +#define IGB_DEFAULT_RX_WTHRESH 0 > > But that still doesn't prevent user from setting wthresh to whatever he likes > inside rx_queue_setup(), so the problem persists right? > As a side notice, it seems really bad practice to use implicit variables inside > macro definition. > Konstantin Yes, you're right. It doesn't prevent the user from changing the value to trigger the problem. I'll withdraw this patch and create another one for this problem. Thanks. > > > > > #define IGB_DEFAULT_TX_PTHRESH ((hw->mac.type == e1000_i354) ? 20 : > 8) > > #define IGB_DEFAULT_TX_HTHRESH 1 > > -- > > 1.9.3
diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.c index bd0ae26..34120ae 100644 --- a/drivers/net/e1000/igb_ethdev.c +++ b/drivers/net/e1000/igb_ethdev.c @@ -64,7 +64,7 @@ #define IGB_DEFAULT_RX_PTHRESH ((hw->mac.type == e1000_i354) ? 12 : 8) #define IGB_DEFAULT_RX_HTHRESH 8 -#define IGB_DEFAULT_RX_WTHRESH ((hw->mac.type == e1000_82576) ? 1 : 4) +#define IGB_DEFAULT_RX_WTHRESH 0 #define IGB_DEFAULT_TX_PTHRESH ((hw->mac.type == e1000_i354) ? 20 : 8) #define IGB_DEFAULT_TX_HTHRESH 1