diff --git a/include/drivers/uart/cdc_acm.h b/include/drivers/uart/cdc_acm.h index e166fb47b24..38b3de8e62b 100644 --- a/include/drivers/uart/cdc_acm.h +++ b/include/drivers/uart/cdc_acm.h @@ -16,6 +16,10 @@ #include +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + /** * @typedef cdc_dte_rate_callback_t * @brief A function that is called when the USB host changes the baud @@ -30,6 +34,9 @@ typedef void (*cdc_dte_rate_callback_t)(struct device *dev, uint32_t rate); * * The callback is invoked when the USB host changes the baud rate. * + * @note This function is available only when + * CONFIG_CDC_ACM_DTE_RATE_CALLBACK_SUPPORT is enabled. + * * @param dev CDC ACM device structure. * @param callback Event handler. * @@ -38,4 +45,8 @@ typedef void (*cdc_dte_rate_callback_t)(struct device *dev, uint32_t rate); int cdc_acm_dte_rate_callback_set(struct device *dev, cdc_dte_rate_callback_t callback); +#ifdef __cplusplus +} +#endif /* __cplusplus */ + #endif /* ZEPHYR_INCLUDE_DRIVERS_UART_CDC_ACM_H_ */