From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wi0-f169.google.com (mail-wi0-f169.google.com [209.85.212.169]) by dpdk.org (Postfix) with ESMTP id 3D05E7F61 for ; Mon, 10 Nov 2014 16:56:06 +0100 (CET) Received: by mail-wi0-f169.google.com with SMTP id n3so10522772wiv.2 for ; Mon, 10 Nov 2014 08:05:52 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-type:content-transfer-encoding; bh=6aa+X+/dDp22TBwm0wq1jXtHa8Zv34ggmQ03Gy0MSQU=; b=UuLkjNsQlkYW5fj0H8LlgxH8xVBZnq6WuQ+rqW0wao+jSBmgNlepgN08re2fNqBjUq meZhAvOKI+uRsJ7RjBfgxFI+ZJLt2TZ/Unj4nixkIe0hdanvBgCP47tEvGMreJfE9oCV PunW79/Ui5YMpuaiaJM35Iq6RRkHV9cIZUWwgYpWO0NzGL9sjDwpdBLGjuE0ob1n3Olm wQ/Pqbs5yDMYiBk7SzFlgBC8nXVpAHmlS5++0skFlHRW4XdMOhkZjRj9u3xPtUYsiJ9e BOHV1Z6KskKZJGWtWLRatbGNuHZdH8M/mstpJjnJsk4Q5uUNCi82HNnP6WbF5kvAMI6Q JXpg== X-Gm-Message-State: ALoCoQnJhJ61enCri2g6GEuV8yzv7/Zvak3x3i33vbhtwayPEkuoZ6xTHHKniAJDIcfLRNV84TsU X-Received: by 10.194.85.116 with SMTP id g20mr17753022wjz.18.1415635189184; Mon, 10 Nov 2014 07:59:49 -0800 (PST) Received: from glumotte.dev.6wind.com (guy78-3-82-239-227-177.fbx.proxad.net. [82.239.227.177]) by mx.google.com with ESMTPSA id ll2sm10966561wjb.11.2014.11.10.07.59.48 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 10 Nov 2014 07:59:48 -0800 (PST) From: Olivier Matz To: dev@dpdk.org Date: Mon, 10 Nov 2014 16:59:15 +0100 Message-Id: <1415635166-1364-2-git-send-email-olivier.matz@6wind.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1415635166-1364-1-git-send-email-olivier.matz@6wind.com> References: <1415635166-1364-1-git-send-email-olivier.matz@6wind.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: jigsaw@gmail.com Subject: [dpdk-dev] [PATCH 01/12] igb/ixgbe: fix IP checksum calculation X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Nov 2014 15:56:06 -0000 According to IntelĀ® 82599 10 GbE Controller Datasheet (Table 7-38), both L2 and L3 lengths are needed to offload the IP checksum. Note that the e1000 driver does not need to be patched as it already contains the fix. Signed-off-by: Olivier Matz Acked-by: Konstantin Ananyev --- lib/librte_pmd_e1000/igb_rxtx.c | 2 +- lib/librte_pmd_ixgbe/ixgbe_rxtx.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/librte_pmd_e1000/igb_rxtx.c b/lib/librte_pmd_e1000/igb_rxtx.c index f09c525..321493e 100644 --- a/lib/librte_pmd_e1000/igb_rxtx.c +++ b/lib/librte_pmd_e1000/igb_rxtx.c @@ -262,7 +262,7 @@ igbe_set_xmit_ctx(struct igb_tx_queue* txq, if (ol_flags & PKT_TX_IP_CKSUM) { type_tucmd_mlhl = E1000_ADVTXD_TUCMD_IPV4; - cmp_mask |= TX_MAC_LEN_CMP_MASK; + cmp_mask |= TX_MACIP_LEN_CMP_MASK; } /* Specify which HW CTX to upload. */ diff --git a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c index 3a5a8ff..78be7e6 100644 --- a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c +++ b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c @@ -374,7 +374,7 @@ ixgbe_set_xmit_ctx(struct igb_tx_queue* txq, if (ol_flags & PKT_TX_IP_CKSUM) { type_tucmd_mlhl = IXGBE_ADVTXD_TUCMD_IPV4; - cmp_mask |= TX_MAC_LEN_CMP_MASK; + cmp_mask |= TX_MACIP_LEN_CMP_MASK; } /* Specify which HW CTX to upload. */ -- 2.1.0