summaryrefslogtreecommitdiff
path: root/common/usbx_device_classes/inc/ux_device_class_dfu.h
diff options
context:
space:
mode:
authorYuxin Zhou <[email protected]>2021-07-28 07:25:46 +0000
committerYuxin Zhou <[email protected]>2021-07-28 07:25:46 +0000
commit3574b6bc518553adefe70d82db907ae801786d6f (patch)
treeeadc713a8c532d2519bff2b6da93d31c8a98995b /common/usbx_device_classes/inc/ux_device_class_dfu.h
parent756899739082fd013048ae6a39dab556fddc8a11 (diff)
Release 6.1.8v6.1.8_rel
Diffstat (limited to 'common/usbx_device_classes/inc/ux_device_class_dfu.h')
-rw-r--r--common/usbx_device_classes/inc/ux_device_class_dfu.h22
1 files changed, 21 insertions, 1 deletions
diff --git a/common/usbx_device_classes/inc/ux_device_class_dfu.h b/common/usbx_device_classes/inc/ux_device_class_dfu.h
index 16ffde8..da31b1f 100644
--- a/common/usbx_device_classes/inc/ux_device_class_dfu.h
+++ b/common/usbx_device_classes/inc/ux_device_class_dfu.h
@@ -24,7 +24,7 @@
/* COMPONENT DEFINITION RELEASE */
/* */
/* ux_device_class_dfu.h PORTABLE C */
-/* 6.1.6 */
+/* 6.1.8 */
/* AUTHOR */
/* */
/* Chaoqiong Xiao, Microsoft Corporation */
@@ -50,12 +50,26 @@
/* removed block count (it's */
/* from host request wValue), */
/* resulting in version 6.1.6 */
+/* 08-02-2021 Chaoqiong Xiao Modified comment(s), */
+/* added extern "C" keyword */
+/* for compatibility with C++, */
+/* resulting in version 6.1.8 */
/* */
/**************************************************************************/
#ifndef UX_DEVICE_CLASS_DFU_H
#define UX_DEVICE_CLASS_DFU_H
+/* Determine if a C++ compiler is being used. If so, ensure that standard
+ C is used to process the API information. */
+
+#ifdef __cplusplus
+
+/* Yes, C++ compiler is present. Use standard C. */
+extern "C" {
+
+#endif
+
/* Define DFU class descriptor capabilities. */
#define UX_SLAVE_CLASS_DFU_CAPABILITY_WILL_DETACH 0x08
#define UX_SLAVE_CLASS_DFU_CAPABILITY_MANIFESTATION_TOLERANT 0x04
@@ -222,4 +236,10 @@ VOID _ux_device_class_dfu_state_sync(UX_SLAVE_CLASS_DFU *dfu);
#define ux_device_class_dfu_state_get _ux_device_class_dfu_state_get
#define ux_device_class_dfu_state_sync _ux_device_class_dfu_state_sync
+/* Determine if a C++ compiler is being used. If so, complete the standard
+ C conditional started above. */
+#ifdef __cplusplus
+}
+#endif
+
#endif /* UX_DEVICE_CLASS_DFU_H */