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 E230FA034C for ; Fri, 25 Feb 2022 18:18:25 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DC2454114D; Fri, 25 Feb 2022 18:18:24 +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 597A74113D for ; Fri, 25 Feb 2022 18:18:23 +0100 (CET) Received: from mail-wm1-f71.google.com (mail-wm1-f71.google.com [209.85.128.71]) (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 806273FCA6 for ; Fri, 25 Feb 2022 17:18:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1645809502; bh=LGZTaL3OYIQK8DBkAOPKmCFbP6X3omBGokzEvhvngT0=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=O76Ckpk4WX2vmt6WYkRI/2AJMUNJU6EabluIEoZcW5zpgpaUX7H2vDgkpEsrtWxXp Desi7HCpiu71GeYS8HdFRW28pRP2oaYrx+3Px9yjxKc6EBxETQ9BzBVWjDT/3cGmzv Ktcx5aT5qlLJe65FypTOnrKTE8qc+gE4Yv9rA9OqNE4xvQcqDbFhO8JwUlnXmgBaMp SN+U5vnbIlCanj1447jLxSHLayD/HFmXz+YvVTT+GupkZFaYf2BUxxeWLTKEZHPQVb +acYWO+DRHUligm+Fia5WWTc0cUBGs/R7ojEIUtcIpi2B8al4Fb+G2GcP/eLAOUvl6 0s/Hx5n8ReNsQ== Received: by mail-wm1-f71.google.com with SMTP id 7-20020a1c1907000000b003471d9bbe8dso2572503wmz.0 for ; Fri, 25 Feb 2022 09:18:22 -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=LGZTaL3OYIQK8DBkAOPKmCFbP6X3omBGokzEvhvngT0=; b=UAlDPhHquvy9g4lrhJXrJVJEDjHPKT9zXHcVgaQvzSfbFRuNI8zGyFiKuQ0Vc14HC9 WKG1xqhGMV9EHnxjylBKzCgUSlz7EENKYxTyOKum5EywvHu+cPoetIXnFtD9ww5C5V3K J+cjaUIs/m2dZT0/YyOKL9qzok+wxiAtEC2iyqKfsv/pb/a4UoeptoiiukjlTXqqmZV+ WDfO2Z3w9hzO+JXk0Mi1Hiz75mLKEyMW8U63NP764atPC1GTriVAE7UPWRNY6HVqUZbv pWNC0kHI7rU/L5yZ42UJTZmfB0Yjo9x119s3luiq65lifbMdLYDzgd3QTnHGfSgK6TUH r7QA== X-Gm-Message-State: AOAM533WWLan1DTHLYea4bmdx9arAlsw7KWytl2S6raevY6inutfhxen vOwMR5SSJFtWctchWeJt/7yyTGO7pcwEytpS9NYLIWvFFlPULhJAzXyv31kgQy50qZEaOWh5vfY hxhHXKJov/KvYCKCDzkegqSIQ X-Received: by 2002:a05:600c:2201:b0:381:ee:419e with SMTP id z1-20020a05600c220100b0038100ee419emr3584454wml.55.1645809501747; Fri, 25 Feb 2022 09:18:21 -0800 (PST) X-Google-Smtp-Source: ABdhPJziKl0WWqP/RwuasxikyLP/vA/EBdVsbkcPKFPsSB6xgxoImNtDURL8YYvohOmKM6N65Ak6QA== X-Received: by 2002:a05:600c:2201:b0:381:ee:419e with SMTP id z1-20020a05600c220100b0038100ee419emr3584438wml.55.1645809501481; Fri, 25 Feb 2022 09:18:21 -0800 (PST) Received: from Keschdeichel.fritz.box (068-133-067-156.ip-addr.inexio.net. [156.67.133.68]) by smtp.gmail.com with ESMTPSA id u4-20020adfdb84000000b001e8d8ac5394sm2880337wri.110.2022.02.25.09.18.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Feb 2022 09:18:21 -0800 (PST) From: christian.ehrhardt@canonical.com To: Weiguo Li Cc: Ferruh Yigit , dpdk stable Subject: patch 'net/memif: remove pointer deference before null check' has been queued to stable release 19.11.12 Date: Fri, 25 Feb 2022 18:15:44 +0100 Message-Id: <20220225171550.3499040-51-christian.ehrhardt@canonical.com> X-Mailer: git-send-email 2.35.0 In-Reply-To: <20220225171550.3499040-1-christian.ehrhardt@canonical.com> References: <20220225171550.3499040-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.12 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 02/27/22. 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/a30a7dba8884a9bedcf00023aa61d29d004ad632 Thanks. Christian Ehrhardt --- >From a30a7dba8884a9bedcf00023aa61d29d004ad632 Mon Sep 17 00:00:00 2001 From: Weiguo Li Date: Wed, 9 Feb 2022 15:39:34 +0800 Subject: [PATCH] net/memif: remove pointer deference before null check [ upstream commit b6c0f464affcf0ec6fcf0a26e517692dc08244f4 ] There are duplicates of assignment here, the one before null check may cause a null pointer deference, so remove the previous one. Fixes: 09c7e63a71f9 ("net/memif: introduce memory interface PMD") Signed-off-by: Weiguo Li Reviewed-by: Ferruh Yigit --- drivers/net/memif/memif_socket.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/memif/memif_socket.c b/drivers/net/memif/memif_socket.c index c1967c67bf..ff6317574d 100644 --- a/drivers/net/memif/memif_socket.c +++ b/drivers/net/memif/memif_socket.c @@ -396,11 +396,10 @@ memif_msg_enq_init(struct rte_eth_dev *dev) { struct pmd_internals *pmd = dev->data->dev_private; struct memif_msg_queue_elt *e = memif_msg_enq(pmd->cc); - memif_msg_init_t *i = &e->msg.init; + memif_msg_init_t *i; if (e == NULL) return -1; - i = &e->msg.init; e->msg.type = MEMIF_MSG_TYPE_INIT; i->version = MEMIF_VERSION; -- 2.35.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2022-02-25 16:58:46.205072340 +0100 +++ 0051-net-memif-remove-pointer-deference-before-null-check.patch 2022-02-25 16:58:44.296990462 +0100 @@ -1 +1 @@ -From b6c0f464affcf0ec6fcf0a26e517692dc08244f4 Mon Sep 17 00:00:00 2001 +From a30a7dba8884a9bedcf00023aa61d29d004ad632 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit b6c0f464affcf0ec6fcf0a26e517692dc08244f4 ] + @@ -10 +11,0 @@ -Cc: stable@dpdk.org @@ -19 +20 @@ -index 42f48a68a1..7886644412 100644 +index c1967c67bf..ff6317574d 100644 @@ -22 +23 @@ -@@ -402,11 +402,10 @@ memif_msg_enq_init(struct rte_eth_dev *dev) +@@ -396,11 +396,10 @@ memif_msg_enq_init(struct rte_eth_dev *dev)