patch 'vhost: fix C++ include' has been queued to stable release 20.11.5

luca.boccassi at gmail.com luca.boccassi at gmail.com
Fri Feb 18 13:39:12 CET 2022


Hi,

FYI, your patch has been queued to stable release 20.11.5

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/20/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/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/c7bd2f435490e211d98b70ca8ca2dcc4fdf51ece

Thanks.

Luca Boccassi

---
>From c7bd2f435490e211d98b70ca8ca2dcc4fdf51ece Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson at intel.com>
Date: Thu, 10 Feb 2022 15:42:38 +0000
Subject: [PATCH] vhost: fix C++ include

[ upstream commit 1d1126ad436e8c7c015fb3f67ad3af05c3b397d5 ]

The virtio kernel header includes are already noted as being
incompatible with C++. We can ensure that the header is safe for
inclusion in C++ code by not including those headers during C++ builds.
While not ideal, this does ensure that all DPDK headers can be included
in C++ code without errors.

Fixes: f8904d563691 ("vhost: fix header for strict compilation flags")

Signed-off-by: Bruce Richardson <bruce.richardson at intel.com>
---
 lib/librte_vhost/rte_vhost.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/librte_vhost/rte_vhost.h b/lib/librte_vhost/rte_vhost.h
index 755fb3dd7a..39fe428079 100644
--- a/lib/librte_vhost/rte_vhost.h
+++ b/lib/librte_vhost/rte_vhost.h
@@ -21,10 +21,12 @@
 extern "C" {
 #endif
 
+#ifndef __cplusplus
 /* These are not C++-aware. */
 #include <linux/vhost.h>
 #include <linux/virtio_ring.h>
 #include <linux/virtio_net.h>
+#endif
 
 #define RTE_VHOST_USER_CLIENT		(1ULL << 0)
 #define RTE_VHOST_USER_NO_RECONNECT	(1ULL << 1)
-- 
2.30.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-02-18 12:37:41.766146065 +0000
+++ 0103-vhost-fix-C-include.patch	2022-02-18 12:37:37.834795136 +0000
@@ -1 +1 @@
-From 1d1126ad436e8c7c015fb3f67ad3af05c3b397d5 Mon Sep 17 00:00:00 2001
+From c7bd2f435490e211d98b70ca8ca2dcc4fdf51ece Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 1d1126ad436e8c7c015fb3f67ad3af05c3b397d5 ]
+
@@ -13 +14,0 @@
-Cc: stable at dpdk.org
@@ -17 +18 @@
- lib/vhost/rte_vhost.h | 2 ++
+ lib/librte_vhost/rte_vhost.h | 2 ++
@@ -20,4 +21,4 @@
-diff --git a/lib/vhost/rte_vhost.h b/lib/vhost/rte_vhost.h
-index b454c05868..2acb31df2d 100644
---- a/lib/vhost/rte_vhost.h
-+++ b/lib/vhost/rte_vhost.h
+diff --git a/lib/librte_vhost/rte_vhost.h b/lib/librte_vhost/rte_vhost.h
+index 755fb3dd7a..39fe428079 100644
+--- a/lib/librte_vhost/rte_vhost.h
++++ b/lib/librte_vhost/rte_vhost.h


More information about the stable mailing list