From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id C4CC4A051C for ; Tue, 11 Feb 2020 12:25:00 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id BCC6D2B9C; Tue, 11 Feb 2020 12:25:00 +0100 (CET) Received: from mail-wm1-f67.google.com (mail-wm1-f67.google.com [209.85.128.67]) by dpdk.org (Postfix) with ESMTP id C163A1BFA0 for ; Tue, 11 Feb 2020 12:24:59 +0100 (CET) Received: by mail-wm1-f67.google.com with SMTP id p9so3021544wmc.2 for ; Tue, 11 Feb 2020 03:24:59 -0800 (PST) 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=eOecak8w6TB0Z11MwTxzHq+EsKS+UamMV+/tMOUdqww=; b=i4OQv67JGOFAHv0tiZwDFANQCI+Oeds9sHK6QIBSOqT25BBH1CkSo1WtvQTPrPaiIE mxYRoEhUlPsMgVgGuu+oksITfCocJv7m0A8R3eXaN99EP67+Rgwj4JkNwkWe2qaKtEEQ SHZk+RcVd/kNJetKaSiJJ6+Jt1GWNqsOemc2d/25UNYaDI/WmQSMRQUDGJk0Ru3jSXwY s2CI5ujfNRfneqXJVagufEtiTPhKml01UQTV9eq6bwtehAz9UAXgP7nFQJmxZPrOsBVu BPrXkmHHiR1KMSuD1xO//EMs0SyKig0t2gy30cqUP8b7Oj153H/U32QeWpvczlUOGdSv dv+Q== 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=eOecak8w6TB0Z11MwTxzHq+EsKS+UamMV+/tMOUdqww=; b=qZ5rzq6UM6a6wSYZRotFXWE4VUWiWi5Z1xJPEZYdRjMTeRdOD8ANS1Ie9TNa1HGX7v jnUBALfuHAOjjVqohG5s0b2mQHDNpRhprzPfsNR4mS9HhVi7ZpVzsdgkv/cSvqipEbOb zUFmhv1yk+aX/lJzTL5k3BF7OSoVTY90h7p2FlApnBIrIJpQW2NpKFHfeVbggmOR5/Ie ib6yybjDayx9tzZvDFVQ7vrNi3jHhiOpuRTL7P0LQD98kUcXTC7/TTBWyuJJhKRUQVe2 BIDqLZ5lzmjQltNVKLmnTDAvmPbYo3ilA+qQMDWspNIm6HvEqO6VJVKHlNnvd3Xag0RX FlEQ== X-Gm-Message-State: APjAAAUqkr+kuZ/KnXCXtRm+n4DIfcKKKHrh8cjUYmfSdMbC/nqEW8nY +Kc/dCu61zaSEw8LATOLY8gfuONqV0g= X-Google-Smtp-Source: APXvYqwG1weEW7WAK1Jtxmw0DDIhmK8w5Mn/H+PlGnmVg5Gv2P1hdF6HbKmMCcS8WhZOFtsFDA4glw== X-Received: by 2002:a7b:c216:: with SMTP id x22mr5321777wmi.51.1581420299482; Tue, 11 Feb 2020 03:24:59 -0800 (PST) Received: from localhost ([88.98.246.218]) by smtp.gmail.com with ESMTPSA id x10sm4892206wrp.58.2020.02.11.03.24.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Feb 2020 03:24:58 -0800 (PST) From: luca.boccassi@gmail.com To: Xiaoyu Min Cc: Zhike Wang , Matan Azrad , dpdk stable Date: Tue, 11 Feb 2020 11:19:45 +0000 Message-Id: <20200211112216.3929-39-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200211112216.3929-1-luca.boccassi@gmail.com> References: <20200211112216.3929-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'net/mlx5: fix multiple flow table hash list' has been queued to stable release 19.11.1 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 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 19.11.1 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/13/20. 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. Thanks. Luca Boccassi --- >From ba19ef396aaca14e49de7b88ef5a435423c68ce8 Mon Sep 17 00:00:00 2001 From: Xiaoyu Min Date: Mon, 16 Dec 2019 11:27:41 +0200 Subject: [PATCH] net/mlx5: fix multiple flow table hash list [ upstream commit 6801116688fe82b5b32cf45ffa7b475d1cfdcea4 ] The eth devices which share one ibv device only need one hash list of flow table. Currently, flow table hash list is created per each eth device whatever whether they share one ibv device or not. If the devices share one ibv device, the previously created hash list will become dangle because the pointer point to (sh->flow_tbls) is overwritten by the later created hast list. To fix this, just don't create hash list if it is already created. Fixes: 54534725d2f3 ("net/mlx5: fix flow table hash list conversion") Reported-by: Zhike Wang Signed-off-by: Xiaoyu Min Acked-by: Matan Azrad --- drivers/net/mlx5/mlx5.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c index d84a6f91b4..50960c91ce 100644 --- a/drivers/net/mlx5/mlx5.c +++ b/drivers/net/mlx5/mlx5.c @@ -868,8 +868,13 @@ mlx5_alloc_shared_dr(struct mlx5_priv *priv) { struct mlx5_ibv_shared *sh = priv->sh; char s[MLX5_HLIST_NAMESIZE]; - int err = mlx5_alloc_table_hash_list(priv); + int err = 0; + if (!sh->flow_tbls) + err = mlx5_alloc_table_hash_list(priv); + else + DRV_LOG(DEBUG, "sh->flow_tbls[%p] already created, reuse\n", + (void *)sh->flow_tbls); if (err) return err; /* Create tags hash list table. */ -- 2.20.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2020-02-11 11:17:40.484967399 +0000 +++ 0039-net-mlx5-fix-multiple-flow-table-hash-list.patch 2020-02-11 11:17:38.372000824 +0000 @@ -1,8 +1,10 @@ -From 6801116688fe82b5b32cf45ffa7b475d1cfdcea4 Mon Sep 17 00:00:00 2001 +From ba19ef396aaca14e49de7b88ef5a435423c68ce8 Mon Sep 17 00:00:00 2001 From: Xiaoyu Min Date: Mon, 16 Dec 2019 11:27:41 +0200 Subject: [PATCH] net/mlx5: fix multiple flow table hash list +[ upstream commit 6801116688fe82b5b32cf45ffa7b475d1cfdcea4 ] + The eth devices which share one ibv device only need one hash list of flow table. @@ -16,7 +18,6 @@ To fix this, just don't create hash list if it is already created. Fixes: 54534725d2f3 ("net/mlx5: fix flow table hash list conversion") -Cc: stable@dpdk.org Reported-by: Zhike Wang Signed-off-by: Xiaoyu Min