DPDK patches and discussions
 help / color / mirror / Atom feed
From: Brian Dooley <brian.dooley@intel.com>
To: dev@dpdk.org
Cc: Brian Dooley <brian.dooley@intel.com>,
	liang-min.wang@intel.com, jblunck@infradead.org,
	ferruh.yigit@intel.com, thomas@monjalon.net, stable@dpdk.org,
	Bruce Richardson <bruce.richardson@intel.com>,
	Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>,
	David Harton <dharton@cisco.com>,
	Konstantin Ananyev <konstantin.ananyev@intel.com>,
	Andrew Harvey <agh@cisco.com>,
	Stephen Hemminger <stephen@networkplumber.org>
Subject: [PATCH v2 03/11] ethdev: fix missing C++ guards
Date: Wed, 16 Feb 2022 15:14:48 +0000	[thread overview]
Message-ID: <20220216151456.114242-4-brian.dooley@intel.com> (raw)
In-Reply-To: <20220216151456.114242-1-brian.dooley@intel.com>

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: 7a3f27cbf59b ("ethdev: add access to specific device info")
Fixes: dcd5c8112bc3 ("ethdev: add PCI driver helpers")
Fixes: 7f0a669e7b04 ("ethdev: add allocation helper for virtual drivers")
Fixes: 7a3357205755 ("lib: remove C++ include guard from private headers")
Cc: liang-min.wang@intel.com
Cc: jblunck@infradead.org
Cc: ferruh.yigit@intel.com
Cc: thomas@monjalon.net
Cc: stable@dpdk.org

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>

---
v2: Added missing apostrophe to commit message.
---
 lib/ethdev/ethdev_driver.h | 8 ++++++++
 lib/ethdev/ethdev_pci.h    | 8 ++++++++
 lib/ethdev/ethdev_vdev.h   | 8 ++++++++
 lib/ethdev/rte_dev_info.h  | 8 ++++++++
 4 files changed, 32 insertions(+)

diff --git a/lib/ethdev/ethdev_driver.h b/lib/ethdev/ethdev_driver.h
index 6d697a879a..5ec00e533e 100644
--- a/lib/ethdev/ethdev_driver.h
+++ b/lib/ethdev/ethdev_driver.h
@@ -5,6 +5,10 @@
 #ifndef _RTE_ETHDEV_DRIVER_H_
 #define _RTE_ETHDEV_DRIVER_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * @file
  *
@@ -1881,4 +1885,8 @@ struct rte_eth_tunnel_filter_conf {
 	uint16_t queue_id;      /**< Queue assigned to if match */
 };
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_ETHDEV_DRIVER_H_ */
diff --git a/lib/ethdev/ethdev_pci.h b/lib/ethdev/ethdev_pci.h
index 71aa4b2e98..6130bcbd1f 100644
--- a/lib/ethdev/ethdev_pci.h
+++ b/lib/ethdev/ethdev_pci.h
@@ -6,6 +6,10 @@
 #ifndef _RTE_ETHDEV_PCI_H_
 #define _RTE_ETHDEV_PCI_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <rte_malloc.h>
 #include <rte_pci.h>
 #include <rte_bus_pci.h>
@@ -171,4 +175,8 @@ rte_eth_dev_pci_generic_remove(struct rte_pci_device *pci_dev,
 	return 0;
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_ETHDEV_PCI_H_ */
diff --git a/lib/ethdev/ethdev_vdev.h b/lib/ethdev/ethdev_vdev.h
index 2b49e9665b..f5f536ce64 100644
--- a/lib/ethdev/ethdev_vdev.h
+++ b/lib/ethdev/ethdev_vdev.h
@@ -6,6 +6,10 @@
 #ifndef _RTE_ETHDEV_VDEV_H_
 #define _RTE_ETHDEV_VDEV_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <rte_config.h>
 #include <rte_malloc.h>
 #include <rte_bus_vdev.h>
@@ -52,4 +56,8 @@ rte_eth_vdev_allocate(struct rte_vdev_device *dev, size_t private_data_size)
 	return eth_dev;
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_ETHDEV_VDEV_H_ */
diff --git a/lib/ethdev/rte_dev_info.h b/lib/ethdev/rte_dev_info.h
index cb2fe0ae97..67cf0ae526 100644
--- a/lib/ethdev/rte_dev_info.h
+++ b/lib/ethdev/rte_dev_info.h
@@ -5,6 +5,10 @@
 #ifndef _RTE_DEV_INFO_H_
 #define _RTE_DEV_INFO_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <stdint.h>
 
 /*
@@ -48,4 +52,8 @@ struct rte_eth_dev_module_info {
 #define RTE_ETH_MODULE_SFF_8436_LEN         256
 #define RTE_ETH_MODULE_SFF_8436_MAX_LEN     640
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_DEV_INFO_H_ */
-- 
2.25.1


  parent reply	other threads:[~2022-02-16 15:15 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-15 17:08 [PATCH 00/11] add " Brian Dooley
2022-02-15 17:08 ` [PATCH 01/11] eal: fix " Brian Dooley
2022-02-15 17:08 ` [PATCH 02/11] telemetry: " Brian Dooley
2022-02-15 17:08 ` [PATCH 03/11] ethdev: " Brian Dooley
2022-02-15 17:08 ` [PATCH 04/11] metrics: " Brian Dooley
2022-02-15 17:08 ` [PATCH 05/11] acl: " Brian Dooley
2022-02-15 17:08 ` [PATCH 06/11] compressdev: " Brian Dooley
2022-02-15 17:08 ` [PATCH 07/11] eventdev: " Brian Dooley
2022-02-15 17:08 ` [PATCH 08/11] kni: " Brian Dooley
2022-02-15 17:08 ` [PATCH 09/11] vhost: " Brian Dooley
2022-02-15 17:08 ` [PATCH 10/11] bpf: " Brian Dooley
2022-02-15 17:08 ` [PATCH 11/11] cryptodev: " Brian Dooley
2022-02-15 17:32 ` [PATCH 00/11] add " Bruce Richardson
2022-02-16 15:14 ` [PATCH v2 " Brian Dooley
2022-02-16 15:14   ` [PATCH v2 01/11] eal: fix " Brian Dooley
2022-02-16 15:14   ` [PATCH v2 02/11] telemetry: " Brian Dooley
2022-02-16 15:14   ` Brian Dooley [this message]
2022-02-16 15:14   ` [PATCH v2 04/11] metrics: " Brian Dooley
2022-02-16 15:14   ` [PATCH v2 05/11] acl: " Brian Dooley
2022-02-16 15:14   ` [PATCH v2 06/11] compressdev: " Brian Dooley
2022-02-16 15:14   ` [PATCH v2 07/11] eventdev: " Brian Dooley
2022-02-16 15:14   ` [PATCH v2 08/11] kni: " Brian Dooley
2022-02-16 15:14   ` [PATCH v2 09/11] vhost: " Brian Dooley
2022-02-17  7:50     ` Xia, Chenbo
2022-02-16 15:14   ` [PATCH v2 10/11] bpf: " Brian Dooley
2022-02-16 15:14   ` [PATCH v2 11/11] cryptodev: " Brian Dooley
2022-02-17  8:00 ` [PATCH 00/11] add " Tyler Retzlaff
2022-02-22 14:02   ` Thomas Monjalon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220216151456.114242-4-brian.dooley@intel.com \
    --to=brian.dooley@intel.com \
    --cc=agh@cisco.com \
    --cc=andrew.rybchenko@oktetlabs.ru \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=dharton@cisco.com \
    --cc=ferruh.yigit@intel.com \
    --cc=jblunck@infradead.org \
    --cc=konstantin.ananyev@intel.com \
    --cc=liang-min.wang@intel.com \
    --cc=stable@dpdk.org \
    --cc=stephen@networkplumber.org \
    --cc=thomas@monjalon.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).