From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 070EEA0C41 for ; Tue, 30 Nov 2021 17:40:28 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 018FD41186; Tue, 30 Nov 2021 17:40:28 +0100 (CET) Received: from smtp-relay-internal-0.canonical.com (smtp-relay-internal-0.canonical.com [185.125.188.122]) by mails.dpdk.org (Postfix) with ESMTP id DFEC041170 for ; Tue, 30 Nov 2021 17:40:25 +0100 (CET) Received: from mail-ed1-f69.google.com (mail-ed1-f69.google.com [209.85.208.69]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-0.canonical.com (Postfix) with ESMTPS id C30AE40038 for ; Tue, 30 Nov 2021 16:40:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1638290425; bh=K4dW2vG75AuzXFKVg9lx385XLPXtdAq2H2oOq97FVLg=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=YOvVQZIyHpHp7p3wGxn6elXcNsfFMezrLabXMgNdsyDww3xvqfMyGrTU3rIVN7qEJ I7TPGLBq9GWbMSxh1kecbuYmOfeF7oT3De5ZbfmfmOKYhRxLHx2tTVCUjQTPZw3ndz byGUNcjbpsQoEml5dSdy4+F8UXt/Z64Lkl80v1I3ErsAjdgZEX1d9Rv2OCCaHsdqL+ gOhLAu3jMiOOgHxziVjW2e8vveZMGbIWisqwE7PMDxa7oEfV577NdRktC+34afWMja qMoAoag2b2ZybmyfZrRQjDmct5UNNQdMHhGt5M7ni0pWVCzIdZFnoIKEkkQJN4aMIW DF4SQ/PsCcFcw== Received: by mail-ed1-f69.google.com with SMTP id bx28-20020a0564020b5c00b003e7c42443dbso17407546edb.15 for ; Tue, 30 Nov 2021 08:40:25 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=K4dW2vG75AuzXFKVg9lx385XLPXtdAq2H2oOq97FVLg=; b=T5PUWiZzjGX2OHui7tmTtP0g094Rgm/tSllse4tCAvZXfSeAmBdIwBjqD9BeIIdQpv OskmwnjUVorPpqf2S6wPYMCXgXwM7qzzT97mkB8NFN/2v6Af7W2Dy2rqk0xjNpTASIhz +Z3/6pnBGC5x0aoQ39SQNkwqhgVYLG1RvFeQZ+yer02LXX2Hb7DmOv1nkJJ35xxfWCyL w1ssBhEoS7826O050G0s/II/053hSE2gux/P/dEwbGOJQgXNG9Aygjruff9gSjWTaEFK N8EPIO6Ow7yPT+b4hdVB+FrhtIhHZAlnpCvU7FTPvmsab9P3bO+2ifCKnuBqVWYK6VtR Wukw== X-Gm-Message-State: AOAM531o8eWXyofUTd30xQVsG0XbSYsoWRf46X8t8plFzSZKJjGex8vD yiwVUUdi/4vAftV0qvkPfYEfKdLR4a70PluM/eKL0XtQa4zPTJ8RzPli6QVyMg938llHTHD36Q8 U7/xnrundqB/Um3e7VTnmdVIR X-Received: by 2002:a17:907:2d10:: with SMTP id gs16mr167112ejc.353.1638290425166; Tue, 30 Nov 2021 08:40:25 -0800 (PST) X-Google-Smtp-Source: ABdhPJx7EL7t9rpWgu67vS65BrudClAGv0BMWlj8Y/rTFTkWg2J/O+jOu5b5MCm/frbFp3rQXFPUbA== X-Received: by 2002:a17:907:2d10:: with SMTP id gs16mr167096ejc.353.1638290425026; Tue, 30 Nov 2021 08:40:25 -0800 (PST) Received: from localhost.localdomain ([2001:67c:1560:8007::aac:c4ad]) by smtp.gmail.com with ESMTPSA id c7sm9711627ejd.91.2021.11.30.08.40.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Nov 2021 08:40:24 -0800 (PST) From: christian.ehrhardt@canonical.com To: Robin Zhang Cc: Christopher Pau , Beilei Xing , dpdk stable Subject: patch 'net/i40e/base: fix using checksum before check' has been queued to stable release 19.11.11 Date: Tue, 30 Nov 2021 17:34:47 +0100 Message-Id: <20211130163605.2460997-83-christian.ehrhardt@canonical.com> X-Mailer: git-send-email 2.34.0 In-Reply-To: <20211130163605.2460997-1-christian.ehrhardt@canonical.com> References: <20211130163605.2460997-1-christian.ehrhardt@canonical.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Hi, FYI, your patch has been queued to stable release 19.11.11 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before December 10th 2021. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/cpaelzer/dpdk-stable-queue This queued commit can be viewed at: https://github.com/cpaelzer/dpdk-stable-queue/commit/e67b39e429b88a343f36e88f5acbc34e244f04a2 Thanks. Christian Ehrhardt --- >From e67b39e429b88a343f36e88f5acbc34e244f04a2 Mon Sep 17 00:00:00 2001 From: Robin Zhang Date: Sat, 9 Oct 2021 01:39:51 +0000 Subject: [PATCH] net/i40e/base: fix using checksum before check [ upstream commit e59d949182767cdf8c7ee1b2637034f50a8487fb ] The variable checksum from i40e_calc_nvm_checksum is used before return value is checked. Fix this logic. Fixes: 8db9e2a1b232 ("i40e: base driver") Fixes: 3ed6c3246f43 ("i40e/base: handle AQ timeout when releasing NVM") Signed-off-by: Christopher Pau Signed-off-by: Robin Zhang Acked-by: Beilei Xing --- drivers/net/i40e/base/i40e_nvm.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/i40e/base/i40e_nvm.c b/drivers/net/i40e/base/i40e_nvm.c index aabf7df900..338972a2f9 100644 --- a/drivers/net/i40e/base/i40e_nvm.c +++ b/drivers/net/i40e/base/i40e_nvm.c @@ -684,10 +684,11 @@ enum i40e_status_code i40e_update_nvm_checksum(struct i40e_hw *hw) DEBUGFUNC("i40e_update_nvm_checksum"); ret_code = i40e_calc_nvm_checksum(hw, &checksum); - le_sum = CPU_TO_LE16(checksum); - if (ret_code == I40E_SUCCESS) + if (ret_code == I40E_SUCCESS) { + le_sum = CPU_TO_LE16(checksum); ret_code = i40e_write_nvm_aq(hw, 0x00, I40E_SR_SW_CHECKSUM_WORD, 1, &le_sum, true); + } return ret_code; } -- 2.34.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2021-11-30 16:50:10.757493881 +0100 +++ 0083-net-i40e-base-fix-using-checksum-before-check.patch 2021-11-30 16:50:05.862874058 +0100 @@ -1 +1 @@ -From e59d949182767cdf8c7ee1b2637034f50a8487fb Mon Sep 17 00:00:00 2001 +From e67b39e429b88a343f36e88f5acbc34e244f04a2 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit e59d949182767cdf8c7ee1b2637034f50a8487fb ] + @@ -11 +12,0 @@ -Cc: stable@dpdk.org @@ -21 +22 @@ -index 67e58cc195..f385042601 100644 +index aabf7df900..338972a2f9 100644 @@ -24 +25 @@ -@@ -755,10 +755,11 @@ enum i40e_status_code i40e_update_nvm_checksum(struct i40e_hw *hw) +@@ -684,10 +684,11 @@ enum i40e_status_code i40e_update_nvm_checksum(struct i40e_hw *hw)