diff --git a/lib/include/openamp/hil.h b/lib/include/openamp/hil.h index 581364011..bdb041b91 100644 --- a/lib/include/openamp/hil.h +++ b/lib/include/openamp/hil.h @@ -200,6 +200,10 @@ struct hil_proc { struct metal_list node; }; +#ifdef __cplusplus +extern "C" { +#endif + /** * hil_create_proc * @@ -596,6 +600,10 @@ int hil_set_rpmsg_channel (struct hil_proc *proc, int index, int hil_set_vdev_rst_cb (struct hil_proc *proc, int index, hil_proc_vdev_rst_cb_t cb); +#ifdef __cplusplus +} // extern "C" +#endif + /** * * This structure is an interface between HIL and platform porting diff --git a/lib/include/openamp/remoteproc.h b/lib/include/openamp/remoteproc.h index 95f5d190b..0146295f5 100644 --- a/lib/include/openamp/remoteproc.h +++ b/lib/include/openamp/remoteproc.h @@ -418,6 +418,10 @@ struct rsc_table_info { #define RPROC_ERR_PARAM (RPROC_ERR_BASE -12) #define RPROC_ERR_PTR (void*)0xDEADBEAF +#ifdef __cplusplus +extern "C" { +#endif + /** * remoteproc_resource_init * @@ -515,4 +519,8 @@ int remoteproc_boot(struct remote_proc *rproc); */ int remoteproc_shutdown(struct remote_proc *rproc); +#ifdef __cplusplus +} // extern "C" +#endif + #endif /* REMOTEPROC_H_ */ diff --git a/lib/include/openamp/rpmsg.h b/lib/include/openamp/rpmsg.h index 26fc6e666..1f88b9a07 100644 --- a/lib/include/openamp/rpmsg.h +++ b/lib/include/openamp/rpmsg.h @@ -171,6 +171,10 @@ struct rpmsg_endpoint { struct metal_list node; }; +#ifdef __cplusplus +extern "C" { +#endif + struct rpmsg_endpoint *rpmsg_create_ept(struct rpmsg_channel *rp_chnl, rpmsg_rx_cb_t cb, void *priv, uint32_t addr); @@ -584,4 +588,8 @@ struct rpmsg_channel *rpmsg_create_channel(struct remote_device *rdev, */ void rpmsg_delete_channel(struct rpmsg_channel *rp_chnl); +#ifdef __cplusplus +} // extern "C" +#endif + #endif /* _RPMSG_H_ */