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 8ACFFA0C4C for ; Mon, 12 Jul 2021 15:12:23 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 821414119C; Mon, 12 Jul 2021 15:12:23 +0200 (CEST) Received: from mail-wr1-f54.google.com (mail-wr1-f54.google.com [209.85.221.54]) by mails.dpdk.org (Postfix) with ESMTP id E48DD4069D for ; Mon, 12 Jul 2021 15:12:21 +0200 (CEST) Received: by mail-wr1-f54.google.com with SMTP id a13so25534512wrf.10 for ; Mon, 12 Jul 2021 06:12:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=IW8fmKT8FMN2rg5+ywStlx9MvwdDjXOE7YGS5fVe1lU=; b=k5QixwjtntYJy+ESvNR+ZnyO6x1AEd1AoKTwhUK/YdaI3Zo23gMtu+ZiJCSvBsn7Ec Y+6CU1+zrIySOE0f7KqHbiGVkbbAu11OkWpdpl9WXHP8Ybph/WHkBwG0iVYSzZblWD2b q9Fk35/4M8yKUT9cSKxeA4+oOncBan4NqMDWJSRAstNm8ATCx/CTvNumCchTUUuYt1I0 +UPLQCiELYwW83/DqwXJPDvqqNtChVGOweRyEKAFNXJcCjEW3Kckzwji/Coy7DHbOgt4 d42cPnrcslBdyQKic3/KGuV9hQhPIN/a47UyjW1sBnF/YR+ACkccDAbRQxu6w2JLwyf7 qGtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=IW8fmKT8FMN2rg5+ywStlx9MvwdDjXOE7YGS5fVe1lU=; b=Gxp1jBcon1OiXkiadn3mfq+td7OYZhx012XN+0o95tEn27R+HWqMhUXk7dDxXaGvxB f2L4SM+2ZmsfZ5BK9f/v43L/+GMLQnNmJZ/thD0OPAf/r3D99mGjGscIxSbylQftgNqc cJCkWj1H1pBdjQS4s9MY6X28I37yWqXQOaQ/lxEuyEIPG6lYDsj/tmDRIP9vqYfvUp8x uRSP8wkAN4sto07n79LY76BO+V1Pyoj8X7wTZnKlPp293VmUWSJlMX/KSosuIoO56lCP kPEQ3AGbvDdyBaVgw8YxCYSfOXUPetSVljPj9ChCVKzG4W7cQVHDiPtKtzQn3pszQTto 03bA== X-Gm-Message-State: AOAM5303Cbk3NIqOld/FMyJDfUlE0y6QxlGORFBxwslNxS2x8f1I7BGu pP/hqQFk8kvM+GSmBFO6PJA= X-Google-Smtp-Source: ABdhPJxJqcY75U7WP8ZYqHS2EYxrYIr1yRY6sSBWclfByf+AG2U4AQ1XIBy8uIahIMQz1TWl66qSdw== X-Received: by 2002:a5d:4010:: with SMTP id n16mr4996352wrp.142.1626095541748; Mon, 12 Jul 2021 06:12:21 -0700 (PDT) Received: from localhost ([137.220.125.106]) by smtp.gmail.com with ESMTPSA id o17sm11340668wms.32.2021.07.12.06.12.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Jul 2021 06:12:21 -0700 (PDT) From: luca.boccassi@gmail.com To: David Marchand Cc: Owen Hilyard , dpdk stable Date: Mon, 12 Jul 2021 14:04:39 +0100 Message-Id: <20210712130551.2462159-44-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210712130551.2462159-1-luca.boccassi@gmail.com> References: <20210712130551.2462159-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'bus/pci: fix leak for unbound devices' has been queued to stable release 20.11.3 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 Sender: "stable" Hi, FYI, your patch has been queued to stable release 20.11.3 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 07/14/21. 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/bluca/dpdk-stable This queued commit can be viewed at: https://github.com/bluca/dpdk-stable/commit/dbf34013549a5e32691c90bdb84e80fffaf96868 Thanks. Luca Boccassi --- >From dbf34013549a5e32691c90bdb84e80fffaf96868 Mon Sep 17 00:00:00 2001 From: David Marchand Date: Wed, 16 Jun 2021 08:52:57 +0200 Subject: [PATCH] bus/pci: fix leak for unbound devices [ upstream commit 7c83a1e3c83e601f449f05e2e36e1df50e8503aa ] For devices not bound to any Linux kernel module, we leak a pci object since it is never added to the PCI bus device list. Fixes: c79a1c67465d ("bus/pci: optimize bus scan") Reported-by: Owen Hilyard Signed-off-by: David Marchand --- drivers/bus/pci/linux/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/bus/pci/linux/pci.c b/drivers/bus/pci/linux/pci.c index c5402b9652..e8d1faa4c9 100644 --- a/drivers/bus/pci/linux/pci.c +++ b/drivers/bus/pci/linux/pci.c @@ -331,7 +331,7 @@ pci_scan_one(const char *dirname, const struct rte_pci_addr *addr) else dev->kdrv = RTE_PCI_KDRV_UNKNOWN; } else { - dev->kdrv = RTE_PCI_KDRV_NONE; + free(dev); return 0; } /* device is valid, add in list (sorted) */ -- 2.30.2 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2021-07-12 13:41:38.928118373 +0100 +++ 0044-bus-pci-fix-leak-for-unbound-devices.patch 2021-07-12 13:41:36.338119444 +0100 @@ -1 +1 @@ -From 7c83a1e3c83e601f449f05e2e36e1df50e8503aa Mon Sep 17 00:00:00 2001 +From dbf34013549a5e32691c90bdb84e80fffaf96868 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit 7c83a1e3c83e601f449f05e2e36e1df50e8503aa ] + @@ -10 +11,0 @@ -Cc: stable@dpdk.org @@ -19 +20 @@ -index 80ffe7633a..4d261b55ee 100644 +index c5402b9652..e8d1faa4c9 100644 @@ -22 +23 @@ -@@ -327,7 +327,7 @@ pci_scan_one(const char *dirname, const struct rte_pci_addr *addr) +@@ -331,7 +331,7 @@ pci_scan_one(const char *dirname, const struct rte_pci_addr *addr)