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 5F251A04DD for ; Wed, 28 Oct 2020 11:54:51 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 56E4BCA4E; Wed, 28 Oct 2020 11:54:50 +0100 (CET) Received: from mail-wr1-f66.google.com (mail-wr1-f66.google.com [209.85.221.66]) by dpdk.org (Postfix) with ESMTP id 50640CA59 for ; Wed, 28 Oct 2020 11:54:47 +0100 (CET) Received: by mail-wr1-f66.google.com with SMTP id a9so1356154wrg.12 for ; Wed, 28 Oct 2020 03:54:47 -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=lfjfyZ6Ou1x8pnR3zN26ZGNbzfmPLl1wZKaxkCZkPTk=; b=MDzgytcu1510gyGwl1fd9v4QiDrJPcDy10m+GSJ2FJrMgaX2tLcAYuWe+PK8eE2kbX 0JmRm3d7qtAP7ygWt03V22a9csvdrEXXnteR93SaFoDypD71K5QpD0ON2T9UafsZCg1g h8Z/wbZB9DlRc7EYynir0jMg7LEwCGsjpZKP3gLoozyYDYClHqths8Z3QdD6T8jiOuHv cLTqdedGPn8+gjufUiYNILx5MFUwKn56T/0Sw7MzL7GbgUTVFoApprqiVEaICQdm21SD pqdkqB3GWdkIW7jgLDzvuBb+G4Hvbo7iNM/ip7kqqJ17xS3tqJe6Ciob2gCBFMNArAnP SSuw== 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=lfjfyZ6Ou1x8pnR3zN26ZGNbzfmPLl1wZKaxkCZkPTk=; b=Iej4lOBxgxrgtBUtvU25DtuoCSELFEQo2E9G7FiUv7j5dYhaThWlvTzFdk/MbgZpuT IixRSPNtFweqJfaW8DulkV9dHTGMcwaqhzjquPpDRM8EQDgRrZL5pf+DVtY3BArHRZm2 X0646qd8ZyFu7+WI2T1SlNsIYc0fGYRgwvpQ58NiFuTblWkOWR3kNqnN27CRg0JrtUa9 uBXyDLWOVqrOUUsz+jOte49RsvazkH0IsZwfUy76aqWtKAdSXZnB4l178CpJg0es9uBM oqMvfoXtWUjHo6KY5CunOP/6WqdckgAOKxWwXY958iIViVbNw1aewYhq5qGDM12CG5z6 lffA== X-Gm-Message-State: AOAM530YxEt7Z3e7zTMPyXGSRcuisd9t2suuse2zgYiKoBpUmoVV6TLZ og68HElJqdQWB06Ozbekykk= X-Google-Smtp-Source: ABdhPJzDF1ubWi+v8r+jWbPEx65wslGrR4E+RCJd7mRpYBTBtJk1+m/h643g9LLSdLb0PN1O2FRnvA== X-Received: by 2002:a5d:40c3:: with SMTP id b3mr8855283wrq.157.1603882487073; Wed, 28 Oct 2020 03:54:47 -0700 (PDT) Received: from localhost ([88.98.246.218]) by smtp.gmail.com with ESMTPSA id h7sm6479391wrt.45.2020.10.28.03.54.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Oct 2020 03:54:46 -0700 (PDT) From: luca.boccassi@gmail.com To: Maxime Coquelin Cc: Marvin Liu , Chenbo Xia , dpdk stable Date: Wed, 28 Oct 2020 10:45:21 +0000 Message-Id: <20201028104606.3504127-162-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20201028104606.3504127-1-luca.boccassi@gmail.com> References: <20201028104606.3504127-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'vhost: fix virtio-net header length with packed ring' has been queued to stable release 19.11.6 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.6 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 10/30/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 0461fa1134443efb3378c41746d210408ead2c19 Mon Sep 17 00:00:00 2001 From: Maxime Coquelin Date: Thu, 1 Oct 2020 12:11:54 +0200 Subject: [PATCH] vhost: fix virtio-net header length with packed ring [ upstream commit 22eaf2613537ba6b0e79f656195eeeaa3dd14666 ] In case packed ring layout has been negotiated, but neither Version 1 nor mergeable buffers, the Virtio-net header len is assigned to the legacy devices value, which is wrong. This patch fixes this with using the proper len as devices using packed ring are not legacy devices. Fixes: a922401f35cc ("vhost: add Rx support for packed ring") Fixes: ae999ce49dcb ("vhost: add Tx support for packed ring") Reported-by: Marvin Liu Signed-off-by: Maxime Coquelin Reviewed-by: Chenbo Xia --- lib/librte_vhost/vhost_user.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/librte_vhost/vhost_user.c b/lib/librte_vhost/vhost_user.c index 4cc0ce21e0..647f0e9cde 100644 --- a/lib/librte_vhost/vhost_user.c +++ b/lib/librte_vhost/vhost_user.c @@ -350,7 +350,9 @@ vhost_user_set_features(struct virtio_net **pdev, struct VhostUserMsg *msg, dev->features = features; if (dev->features & - ((1 << VIRTIO_NET_F_MRG_RXBUF) | (1ULL << VIRTIO_F_VERSION_1))) { + ((1ULL << VIRTIO_NET_F_MRG_RXBUF) | + (1ULL << VIRTIO_F_VERSION_1) | + (1ULL << VIRTIO_F_RING_PACKED))) { dev->vhost_hlen = sizeof(struct virtio_net_hdr_mrg_rxbuf); } else { dev->vhost_hlen = sizeof(struct virtio_net_hdr); -- 2.20.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2020-10-28 10:35:16.757555512 +0000 +++ 0162-vhost-fix-virtio-net-header-length-with-packed-ring.patch 2020-10-28 10:35:11.760833792 +0000 @@ -1,8 +1,10 @@ -From 22eaf2613537ba6b0e79f656195eeeaa3dd14666 Mon Sep 17 00:00:00 2001 +From 0461fa1134443efb3378c41746d210408ead2c19 Mon Sep 17 00:00:00 2001 From: Maxime Coquelin Date: Thu, 1 Oct 2020 12:11:54 +0200 Subject: [PATCH] vhost: fix virtio-net header length with packed ring +[ upstream commit 22eaf2613537ba6b0e79f656195eeeaa3dd14666 ] + In case packed ring layout has been negotiated, but neither Version 1 nor mergeable buffers, the Virtio-net header len is assigned to the legacy devices value, which is wrong. @@ -12,7 +14,6 @@ Fixes: a922401f35cc ("vhost: add Rx support for packed ring") Fixes: ae999ce49dcb ("vhost: add Tx support for packed ring") -Cc: stable@dpdk.org Reported-by: Marvin Liu Signed-off-by: Maxime Coquelin @@ -22,10 +23,10 @@ 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/librte_vhost/vhost_user.c b/lib/librte_vhost/vhost_user.c -index 4deceb3e00..5d1fb9e863 100644 +index 4cc0ce21e0..647f0e9cde 100644 --- a/lib/librte_vhost/vhost_user.c +++ b/lib/librte_vhost/vhost_user.c -@@ -341,7 +341,9 @@ vhost_user_set_features(struct virtio_net **pdev, struct VhostUserMsg *msg, +@@ -350,7 +350,9 @@ vhost_user_set_features(struct virtio_net **pdev, struct VhostUserMsg *msg, dev->features = features; if (dev->features &