Skip to content

Commit

Permalink
service: fix C++ linkage
Browse files Browse the repository at this point in the history
[ upstream commit 604d426 ]

"extern C" define is added to rte_service_component.h file
to be able to use in C++ context

Fixes: 2169835 ("service: introduce service cores concept")

Signed-off-by: Levend Sayar <levendsayar@gmail.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
  • Loading branch information
sayarsoft authored and kevintraynor committed Aug 20, 2020
1 parent 4a0112b commit 71cd446
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions lib/librte_eal/common/include/rte_service_component.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@
* Include this file if you are writing a component that requires CPU cycles to
* operate, and you wish to run the component using service cores
*/

#ifdef __cplusplus
extern "C" {
#endif

#include <rte_compat.h>
#include <rte_service.h>

Expand Down Expand Up @@ -130,4 +135,8 @@ int32_t rte_service_init(void);
*/
void rte_service_finalize(void);

#ifdef __cplusplus
}
#endif

#endif /* _RTE_SERVICE_PRIVATE_H_ */

0 comments on commit 71cd446

Please sign in to comment.