From 3574b6bc518553adefe70d82db907ae801786d6f Mon Sep 17 00:00:00 2001 From: Yuxin Zhou Date: Wed, 28 Jul 2021 07:25:46 +0000 Subject: [PATCH] Release 6.1.8 --- CMakeLists.txt | 7 ++- common/core/inc/ux_api.h | 48 ++++++++++--------- common/core/inc/ux_dcd_sim_slave.h | 22 ++++++++- common/core/inc/ux_device_class_dpump.h | 22 ++++++++- common/core/inc/ux_device_stack.h | 22 ++++++++- common/core/inc/ux_hcd_sim_host.h | 22 ++++++++- common/core/inc/ux_host_class_dpump.h | 22 ++++++++- common/core/inc/ux_host_stack.h | 22 ++++++++- common/core/inc/ux_user_sample.h | 17 ++++--- common/core/src/ux_hcd_sim_host_port_reset.c | 7 ++- common/core/src/ux_host_stack_uninitialize.c | 7 ++- .../inc/ux_device_class_audio.h | 24 +++++++++- .../inc/ux_device_class_audio10.h | 22 ++++++++- .../inc/ux_device_class_audio20.h | 22 ++++++++- .../inc/ux_device_class_cdc_acm.h | 22 ++++++++- .../inc/ux_device_class_cdc_ecm.h | 25 +++++++++- .../inc/ux_device_class_dfu.h | 22 ++++++++- .../inc/ux_device_class_hid.h | 22 ++++++++- .../inc/ux_device_class_pima.h | 22 ++++++++- .../inc/ux_device_class_rndis.h | 27 +++++++++-- .../inc/ux_device_class_storage.h | 22 ++++++++- .../src/ux_device_class_cdc_ecm_activate.c | 7 ++- .../src/ux_device_class_hid_descriptor_send.c | 16 +++++-- .../src/ux_device_class_rndis_deactivate.c | 7 ++- .../inc/ux_host_class_asix.h | 22 ++++++++- .../inc/ux_host_class_audio.h | 22 ++++++++- .../inc/ux_host_class_cdc_acm.h | 22 ++++++++- .../inc/ux_host_class_cdc_ecm.h | 22 ++++++++- .../inc/ux_host_class_gser.h | 22 ++++++++- .../usbx_host_classes/inc/ux_host_class_hid.h | 22 ++++++++- .../inc/ux_host_class_hid_keyboard.h | 22 ++++++++- .../inc/ux_host_class_hid_mouse.h | 22 ++++++++- .../inc/ux_host_class_hid_remote_control.h | 22 ++++++++- .../usbx_host_classes/inc/ux_host_class_hub.h | 22 ++++++++- .../inc/ux_host_class_pima.h | 22 ++++++++- .../inc/ux_host_class_printer.h | 22 ++++++++- .../inc/ux_host_class_prolific.h | 22 ++++++++- .../inc/ux_host_class_storage.h | 22 ++++++++- .../inc/ux_host_class_swar.h | 22 ++++++++- .../inc/ux_host_class_video.h | 47 +++++++++++++++++- ...ux_host_class_asix_transmission_callback.c | 7 ++- .../src/ux_host_class_asix_write.c | 7 ++- .../src/ux_host_class_hid_report_add.c | 7 ++- .../ux_host_class_storage_device_initialize.c | 41 +++++++++------- .../src/ux_host_class_storage_media_get.c | 9 ++-- .../src/ux_host_class_video_entities_parse.c | 7 ++- .../usbx_host_controllers/inc/ux_hcd_ehci.h | 25 +++++++++- .../usbx_host_controllers/inc/ux_hcd_ohci.h | 22 ++++++++- .../src/ux_hcd_ehci_initialize.c | 7 ++- .../src/ux_hcd_ehci_port_reset.c | 7 ++- .../src/ux_hcd_ehci_port_status_get.c | 7 ++- .../src/ux_hcd_ehci_transfer_abort.c | 7 ++- common/usbx_network/inc/ux_network_driver.h | 25 +++++++++- common/usbx_network/src/ux_network_driver.c | 14 ++++-- common/usbx_pictbridge/inc/ux_pictbridge.h | 22 ++++++++- .../ux_pictbridge_dpsclient_object_delete.c | 7 ++- 56 files changed, 950 insertions(+), 126 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index d331df4e..ddf82919 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,7 +2,6 @@ cmake_minimum_required(VERSION 3.0.0 FATAL_ERROR) # Set up the project project(usbx - VERSION 6.0.0 LANGUAGES C ASM ) @@ -28,7 +27,11 @@ target_link_libraries(${PROJECT_NAME} PUBLIC set(CUSTOM_INC_DIR ${CMAKE_CURRENT_BINARY_DIR}/custom_inc) # Pick up the port specific stuff first -add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/ports/${THREADX_ARCH}/${THREADX_TOOLCHAIN}) +if(DEFINED USBX_CUSTOM_PORT) + add_subdirectory(${USBX_CUSTOM_PORT} usbx_port) +else() + add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/ports/${THREADX_ARCH}/${THREADX_TOOLCHAIN}) +endif() # Then the common files add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/common) diff --git a/common/core/inc/ux_api.h b/common/core/inc/ux_api.h index 6361c452..02201d39 100755 --- a/common/core/inc/ux_api.h +++ b/common/core/inc/ux_api.h @@ -26,7 +26,7 @@ /* APPLICATION INTERFACE DEFINITION RELEASE */ /* */ /* ux_api.h PORTABLE C */ -/* 6.1.7 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -92,6 +92,10 @@ /* changed transfer timeout */ /* value, */ /* resulting in version 6.1.7 */ +/* 08-02-2021 Chaoqiong Xiao Modified comment(s), */ +/* fixed spelling error, */ +/* fixed trace ID order error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ @@ -226,7 +230,7 @@ typedef signed char SCHAR; #define AZURE_RTOS_USBX #define USBX_MAJOR_VERSION 6 #define USBX_MINOR_VERSION 1 -#define USBX_PATCH_VERSION 7 +#define USBX_PATCH_VERSION 8 /* Macros for concatenating tokens, where UX_CONCATn concatenates n tokens. */ @@ -237,7 +241,7 @@ typedef signed char SCHAR; #define UX_COMPILE_TIME_ASSERT(exp, meaningful_name_as_variable) \ typedef char UX_CONCAT2(meaningful_name_as_variable, __LINE__)[!(exp) ? -1 : 1]; -/* Arithmetics. */ +/* Arithmetic. */ #define UX_MIN(a, b) ((a) < (b) ? (a) : (b)) #define UX_MAX(a, b) ((a) > (b) ? (a) : (b)) @@ -321,7 +325,7 @@ typedef signed char SCHAR; VOID _ux_utility_debug_log(UCHAR *debug_location, UCHAR *debug_message, ULONG debug_code, ULONG debug_parameter_1, ULONG debug_parameter_2); -/* DEBUG LOG MESSAGES SHOULD BE WRITEN LIKE THIS IN THE CODE : */ +/* DEBUG LOG MESSAGES SHOULD BE WRITTEN LIKE THIS IN THE CODE : */ /* If error log is enabled, insert this error message into the log buffer. */ /* UX_DEBUG_LOG("_ux_host_stack_rh_device_insertion", "Device insertion", port_index, port_index, 0) */ @@ -594,23 +598,23 @@ VOID _ux_trace_event_update(TX_TRACE_BUFFER_ENTRY *event, ULONG timestamp, UL #define UX_TRACE_DEVICE_STACK_CLASS_REGISTER (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 3) /* I1 = class name , I2 = interface number, I3 = parameter */ #define UX_TRACE_DEVICE_STACK_CLEAR_FEATURE (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 4) /* I1 = request type , I2 = request value , I3 = request index */ #define UX_TRACE_DEVICE_STACK_CONFIGURATION_GET (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 5) /* I1 = configuration value */ -#define UX_TRACE_DEVICE_STACK_CONFIGURATION_SET (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 5) /* I1 = configuration value */ -#define UX_TRACE_DEVICE_STACK_CONNECT (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 6) /* */ -#define UX_TRACE_DEVICE_STACK_DESCRIPTOR_SEND (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 7) /* I1 = descriptor type , I2 = request index */ -#define UX_TRACE_DEVICE_STACK_DISCONNECT (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 8) /* I1 = device */ -#define UX_TRACE_DEVICE_STACK_ENDPOINT_STALL (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 9) /* I1 = endpoint */ -#define UX_TRACE_DEVICE_STACK_GET_STATUS (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 10) /* I1 = request type , I2 = request value , I3 = request index */ -#define UX_TRACE_DEVICE_STACK_HOST_WAKEUP (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 11) /* */ -#define UX_TRACE_DEVICE_STACK_INITIALIZE (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 12) /* */ -#define UX_TRACE_DEVICE_STACK_INTERFACE_DELETE (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 13) /* I1 = interface */ -#define UX_TRACE_DEVICE_STACK_INTERFACE_GET (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 14) /* I1 = interface value */ -#define UX_TRACE_DEVICE_STACK_INTERFACE_SET (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 15) /* I1 = alternate setting value */ -#define UX_TRACE_DEVICE_STACK_SET_FEATURE (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 16) /* I1 = request value , I2 = request index */ -#define UX_TRACE_DEVICE_STACK_TRANSFER_ABORT (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 17) /* I1 = transfer request, I2 = completion code */ -#define UX_TRACE_DEVICE_STACK_TRANSFER_ALL_REQUEST_ABORT (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 18) /* I1 = endpoint , I2 = completion code */ -#define UX_TRACE_DEVICE_STACK_TRANSFER_REQUEST (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 19) /* I1 = transfer request */ -#define UX_TRACE_DEVICE_STACK_MICROSOFT_EXTENSION_REGISTER (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 20) /* I1 = transfer request */ -#define UX_TRACE_DEVICE_STACK_CLASS_UNREGISTER (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 21) /* I1 = class name */ +#define UX_TRACE_DEVICE_STACK_CONFIGURATION_SET (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 6) /* I1 = configuration value */ +#define UX_TRACE_DEVICE_STACK_CONNECT (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 7) /* */ +#define UX_TRACE_DEVICE_STACK_DESCRIPTOR_SEND (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 8) /* I1 = descriptor type , I2 = request index */ +#define UX_TRACE_DEVICE_STACK_DISCONNECT (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 9) /* I1 = device */ +#define UX_TRACE_DEVICE_STACK_ENDPOINT_STALL (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 10) /* I1 = endpoint */ +#define UX_TRACE_DEVICE_STACK_GET_STATUS (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 11) /* I1 = request type , I2 = request value , I3 = request index */ +#define UX_TRACE_DEVICE_STACK_HOST_WAKEUP (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 12) /* */ +#define UX_TRACE_DEVICE_STACK_INITIALIZE (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 13) /* */ +#define UX_TRACE_DEVICE_STACK_INTERFACE_DELETE (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 14) /* I1 = interface */ +#define UX_TRACE_DEVICE_STACK_INTERFACE_GET (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 15) /* I1 = interface value */ +#define UX_TRACE_DEVICE_STACK_INTERFACE_SET (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 16) /* I1 = alternate setting value */ +#define UX_TRACE_DEVICE_STACK_SET_FEATURE (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 17) /* I1 = request value , I2 = request index */ +#define UX_TRACE_DEVICE_STACK_TRANSFER_ABORT (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 18) /* I1 = transfer request, I2 = completion code */ +#define UX_TRACE_DEVICE_STACK_TRANSFER_ALL_REQUEST_ABORT (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 19) /* I1 = endpoint , I2 = completion code */ +#define UX_TRACE_DEVICE_STACK_TRANSFER_REQUEST (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 20) /* I1 = transfer request */ +#define UX_TRACE_DEVICE_STACK_MICROSOFT_EXTENSION_REGISTER (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 21) /* I1 = transfer request */ +#define UX_TRACE_DEVICE_STACK_CLASS_UNREGISTER (UX_TRACE_DEVICE_STACK_EVENTS_BASE + 22) /* I1 = class name */ /* Define the USBX device stack events first. */ @@ -619,7 +623,7 @@ VOID _ux_trace_event_update(TX_TRACE_BUFFER_ENTRY *event, ULONG timestamp, UL #define UX_TRACE_DEVICE_CLASS_DPUMP_DEACTIVATE (UX_TRACE_DEVICE_CLASS_EVENTS_BASE + 2) /* I1 = class instance */ #define UX_TRACE_DEVICE_CLASS_DPUMP_READ (UX_TRACE_DEVICE_CLASS_EVENTS_BASE + 3) /* I1 = class instance , I2 = buffer , I3 = requested_length */ #define UX_TRACE_DEVICE_CLASS_DPUMP_WRITE (UX_TRACE_DEVICE_CLASS_EVENTS_BASE + 4) /* I1 = class instance , I2 = buffer , I3 = requested_length */ -#define UX_TRACE_DEVICE_CLASS_DPUMP_CHANGE (UX_TRACE_DEVICE_CLASS_EVENTS_BASE + 4) /* I1 = class instance , I2 = buffer , I3 = requested_length */ +#define UX_TRACE_DEVICE_CLASS_DPUMP_CHANGE (UX_TRACE_DEVICE_CLASS_EVENTS_BASE + 5) /* I1 = class instance , I2 = buffer , I3 = requested_length */ #define UX_TRACE_DEVICE_CLASS_CDC_ACM_ACTIVATE (UX_TRACE_DEVICE_CLASS_EVENTS_BASE + 10) /* I1 = class instance */ #define UX_TRACE_DEVICE_CLASS_CDC_ACM_DEACTIVATE (UX_TRACE_DEVICE_CLASS_EVENTS_BASE + 11) /* I1 = class instance */ diff --git a/common/core/inc/ux_dcd_sim_slave.h b/common/core/inc/ux_dcd_sim_slave.h index ae7e4527..5c70cdfc 100644 --- a/common/core/inc/ux_dcd_sim_slave.h +++ b/common/core/inc/ux_dcd_sim_slave.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_dcd_sim_slave.h PORTABLE C */ -/* 6.1.6 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -48,12 +48,26 @@ /* added HCD connected to, */ /* supported bi-dir-endpoints, */ /* 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_DCD_SIM_SLAVE_H #define UX_DCD_SIM_SLAVE_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 USB slave simulator major equivalences. */ @@ -144,5 +158,11 @@ UINT _ux_dcd_sim_slave_transfer_abort(UX_DCD_SIM_SLAVE *dcd_sim_slave, UX_SLA /* Define Device Simulator Class API prototypes. */ #define ux_dcd_sim_slave_initialize _ux_dcd_sim_slave_initialize +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/core/inc/ux_device_class_dpump.h b/common/core/inc/ux_device_class_dpump.h index 2216d372..ec54284b 100644 --- a/common/core/inc/ux_device_class_dpump.h +++ b/common/core/inc/ux_device_class_dpump.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_dpump.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -43,12 +43,26 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_DEVICE_CLASS_DPUMP_H #define UX_DEVICE_CLASS_DPUMP_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 Storage Class USB Class constants. */ @@ -100,4 +114,10 @@ UINT _ux_device_class_dpump_change(UX_SLAVE_CLASS_COMMAND *command); #define ux_device_class_dpump_read _ux_device_class_dpump_read #define ux_device_class_dpump_write _ux_device_class_dpump_write +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/core/inc/ux_device_stack.h b/common/core/inc/ux_device_stack.h index 7cecf2d0..85c37f01 100644 --- a/common/core/inc/ux_device_stack.h +++ b/common/core/inc/ux_device_stack.h @@ -25,7 +25,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_stack.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -42,12 +42,26 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_DEVICE_STACK_H #define UX_DEVICE_STACK_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 USB Device Stack prototypes. */ @@ -85,5 +99,11 @@ UINT _ux_device_stack_class_unregister(UCHAR *class_name, UINT (*class_entry_ UINT _ux_device_stack_microsoft_extension_register(ULONG vendor_request, UINT (*vendor_request_function)(ULONG, ULONG, ULONG, ULONG, UCHAR *, ULONG *)); UINT _ux_device_stack_uninitialize(VOID); +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/core/inc/ux_hcd_sim_host.h b/common/core/inc/ux_hcd_sim_host.h index 825552c2..dafa2256 100644 --- a/common/core/inc/ux_hcd_sim_host.h +++ b/common/core/inc/ux_hcd_sim_host.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_hcd_sim_host.h PORTABLE C */ -/* 6.1.6 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -54,12 +54,26 @@ /* 04-02-2021 Chaoqiong Xiao Modified comment(s), */ /* added port status variable, */ /* 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_HCD_SIM_HOST_H #define UX_HCD_SIM_HOST_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 simulator host generic definitions. */ @@ -247,5 +261,11 @@ UINT _ux_hcd_sim_host_port_reset(UX_HCD_SIM_HOST *hcd_sim_host, ULONG port_in /* Define Device Simulator Class API prototypes. */ #define ux_hcd_sim_host_initialize _ux_hcd_sim_host_initialize +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/core/inc/ux_host_class_dpump.h b/common/core/inc/ux_host_class_dpump.h index c3c9047c..879f9b80 100644 --- a/common/core/inc/ux_host_class_dpump.h +++ b/common/core/inc/ux_host_class_dpump.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_dpump.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -43,12 +43,26 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_DPUMP_H #define UX_HOST_CLASS_DPUMP_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 Data Pump Class constants. */ @@ -88,4 +102,10 @@ UINT _ux_host_class_dpump_ioctl(UX_HOST_CLASS_DPUMP *dpump, ULONG ioctl_funct #define ux_host_class_dpump_write _ux_host_class_dpump_write #define ux_host_class_dpump_ioctl _ux_host_class_dpump_ioctl +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/core/inc/ux_host_stack.h b/common/core/inc/ux_host_stack.h index a8bc1318..41a52072 100644 --- a/common/core/inc/ux_host_stack.h +++ b/common/core/inc/ux_host_stack.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_stack.h PORTABLE C */ -/* 6.1.4 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -53,12 +53,26 @@ /* descriptor get support, */ /* updated internal function, */ /* resulting in version 6.1.4 */ +/* 08-02-2021 Chaoqiong Xiao Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_STACK_H #define UX_HOST_STACK_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 Host Stack component function prototypes. */ @@ -143,5 +157,11 @@ VOID _ux_host_stack_hnp_polling_thread_entry(ULONG id); #endif +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/core/inc/ux_user_sample.h b/common/core/inc/ux_user_sample.h index 584ed8e5..89c0e7bc 100644 --- a/common/core/inc/ux_user_sample.h +++ b/common/core/inc/ux_user_sample.h @@ -26,7 +26,7 @@ /* PORT SPECIFIC C INFORMATION RELEASE */ /* */ /* ux_user.h PORTABLE C */ -/* 6.1.7 */ +/* 6.1.8 */ /* */ /* AUTHOR */ /* */ @@ -62,6 +62,9 @@ /* transfer timeout value */ /* options, */ /* resulting in version 6.1.7 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ @@ -168,7 +171,7 @@ /* Defined, this value represents the maximum number of bytes received on a control endpoint in - the device stack. The default is 256 bytes but can be reduced in memory constraint environments. */ + the device stack. The default is 256 bytes but can be reduced in memory constrained environments. */ /* #define UX_SLAVE_REQUEST_CONTROL_MAX_LENGTH 256 */ @@ -176,7 +179,7 @@ /* Defined, this value represents the maximum number of bytes that can be received or transmitted on any endpoint. This value cannot be less than the maximum packet size of any endpoint. The default - is 4096 bytes but can be reduced in memory constraint environments. For cd-rom support in the storage + is 4096 bytes but can be reduced in memory constrained environments. For cd-rom support in the storage class, this value cannot be less than 2048. */ #define UX_SLAVE_REQUEST_DATA_MAX_LENGTH (1024 * 2) @@ -189,7 +192,7 @@ /* Defined, this value represents the maximum number of bytes that a storage payload can send/receive. - The default is 8K bytes but can be reduced in memory constraint environments. */ + The default is 8K bytes but can be reduced in memory constrained environments. */ #define UX_HOST_CLASS_STORAGE_MEMORY_BUFFER_SIZE (1024 * 8) /* Define USBX Mass Storage Thread Stack Size. The default is to use UX_THREAD_STACK_SIZE. */ @@ -198,7 +201,7 @@ */ /* Defined, this value represents the maximum number of Ed, regular TDs and Isochronous TDs. These values - depend on the type of host controller and can be reduced in memory constraint environments. */ + depend on the type of host controller and can be reduced in memory constrained environments. */ #define UX_MAX_ED 80 #define UX_MAX_TD 128 @@ -250,7 +253,7 @@ /* Defined, this value represents the maximum number of media for the host storage class. - Default is 8 but for memory contrained resource systems this can ne reduced to 1. */ + Default is 8 but for memory constrained resource systems this can ne reduced to 1. */ #define UX_HOST_CLASS_STORAGE_MAX_MEDIA 2 @@ -262,7 +265,7 @@ /* #define UX_HOST_CLASS_STORAGE_INCLUDE_LEGACY_PROTOCOL_SUPPORT */ -/* Defined, this value forces the memory allocation scheme to enforce alignement +/* Defined, this value forces the memory allocation scheme to enforce alignment of memory with the UX_SAFE_ALIGN field. */ diff --git a/common/core/src/ux_hcd_sim_host_port_reset.c b/common/core/src/ux_hcd_sim_host_port_reset.c index 8be67408..98077973 100644 --- a/common/core/src/ux_hcd_sim_host_port_reset.c +++ b/common/core/src/ux_hcd_sim_host_port_reset.c @@ -36,7 +36,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_hcd_sim_host_port_reset PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -70,6 +70,9 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_hcd_sim_host_port_reset(UX_HCD_SIM_HOST *hcd_sim_host, ULONG port_index) @@ -86,7 +89,7 @@ UX_SLAVE_DEVICE *device; /* Is this a connection? */ if (device -> ux_slave_device_state == UX_DEVICE_RESET) - /* Complete the device initialization. Note that everytime the device + /* Complete the device initialization. Note that every time the device is disconnected, this must be called again for connection. */ _ux_dcd_sim_slave_initialize_complete(); diff --git a/common/core/src/ux_host_stack_uninitialize.c b/common/core/src/ux_host_stack_uninitialize.c index 770a44ab..047482bf 100644 --- a/common/core/src/ux_host_stack_uninitialize.c +++ b/common/core/src/ux_host_stack_uninitialize.c @@ -34,7 +34,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_host_stack_uninitialize PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -72,6 +72,9 @@ /* DATE NAME DESCRIPTION */ /* */ /* 09-30-2020 Chaoqiong Xiao Initial Version 6.1 */ +/* 08-02-2021 Xiuwen Cai Modified comment(s), */ +/* fixed compile issue, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_host_stack_uninitialize(VOID) @@ -98,7 +101,7 @@ UINT _ux_host_stack_uninitialize(VOID) /* Free HCD thread stack. */ _ux_utility_memory_free(_ux_system_host -> ux_system_host_hcd_thread_stack); -#if UX_OTG_SUPPORT +#if defined(UX_OTG_SUPPORT) /* Delete HNP thread. */ _ux_utility_thread_delete(&_ux_system_host -> ux_system_host_hnp_polling_thread); diff --git a/common/usbx_device_classes/inc/ux_device_class_audio.h b/common/usbx_device_classes/inc/ux_device_class_audio.h index 38acd0d0..402a1718 100644 --- a/common/usbx_device_classes/inc/ux_device_class_audio.h +++ b/common/usbx_device_classes/inc/ux_device_class_audio.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_audio.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,11 +46,25 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_DEVICE_CLASS_AUDIO_H -#define UX_DEVICE_CLASS_AUDIO_H +#define UX_DEVICE_CLASS_AUDIO_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 Audio Class function (AF) constants. */ @@ -423,4 +437,10 @@ UINT _ux_device_class_audio_write_frame_commit(UX_DEVICE_CLASS_AUDIO_STREAM * #define ux_device_class_audio_ioctl _ux_device_class_audio_ioctl +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif /* ifndef UX_DEVICE_CLASS_AUDIO_H */ diff --git a/common/usbx_device_classes/inc/ux_device_class_audio10.h b/common/usbx_device_classes/inc/ux_device_class_audio10.h index e03003f3..6e6c000b 100644 --- a/common/usbx_device_classes/inc/ux_device_class_audio10.h +++ b/common/usbx_device_classes/inc/ux_device_class_audio10.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_audio10.h PORTABLE C */ -/* 6.1.6 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* 04-02-2021 Chaoqiong Xiao Modified comment(s), */ /* added volume RES support, */ /* 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_AUDIO10_H #define UX_DEVICE_CLASS_AUDIO10_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 Audio Class specific AC interface descriptor subclasses. */ @@ -363,4 +377,10 @@ UINT _ux_device_class_audio10_control_process(UX_DEVICE_CLASS_AUDIO *audio, #define ux_device_class_audio10_control_process _ux_device_class_audio10_control_process +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif /* ifndef UX_DEVICE_CLASS_AUDIO10_H */ diff --git a/common/usbx_device_classes/inc/ux_device_class_audio20.h b/common/usbx_device_classes/inc/ux_device_class_audio20.h index 058657d1..0f444458 100644 --- a/common/usbx_device_classes/inc/ux_device_class_audio20.h +++ b/common/usbx_device_classes/inc/ux_device_class_audio20.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_audio20.h PORTABLE C */ -/* 6.1.6 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* 04-02-2021 Chaoqiong Xiao Modified comment(s), */ /* added volume RES support, */ /* 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_AUDIO20_H #define UX_DEVICE_CLASS_AUDIO20_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 Audio Class function category codes. */ @@ -421,4 +435,10 @@ UINT _ux_device_class_audio20_control_process(UX_DEVICE_CLASS_AUDIO *audio, #define ux_device_class_audio20_control_process _ux_device_class_audio20_control_process +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif /* ifndef UX_DEVICE_CLASS_AUDIO20_H */ diff --git a/common/usbx_device_classes/inc/ux_device_class_cdc_acm.h b/common/usbx_device_classes/inc/ux_device_class_cdc_acm.h index eb8840c8..93deb6d2 100644 --- a/common/usbx_device_classes/inc/ux_device_class_cdc_acm.h +++ b/common/usbx_device_classes/inc/ux_device_class_cdc_acm.h @@ -24,7 +24,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_cdc_acm.h PORTABLE C */ -/* 6.1.6 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -48,12 +48,26 @@ /* added macro to disable */ /* transmission support, */ /* 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_CDC_ACM_H #define UX_DEVICE_CLASS_CDC_ACM_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 CDC Class USB Class constants. */ #define UX_SLAVE_CLASS_CDC_ACM_CLASS 10 @@ -266,4 +280,10 @@ UINT _ux_device_class_cdc_acm_write_with_callback(UX_SLAVE_CLASS_CDC_ACM *cdc_a #define ux_device_class_cdc_acm_ioctl _ux_device_class_cdc_acm_ioctl #define ux_device_class_cdc_acm_write_with_callback _ux_device_class_cdc_acm_write_with_callback +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif /* UX_DEVICE_CLASS_CDC_ACM_H */ diff --git a/common/usbx_device_classes/inc/ux_device_class_cdc_ecm.h b/common/usbx_device_classes/inc/ux_device_class_cdc_ecm.h index fac6c1cc..6f787e4d 100644 --- a/common/usbx_device_classes/inc/ux_device_class_cdc_ecm.h +++ b/common/usbx_device_classes/inc/ux_device_class_cdc_ecm.h @@ -24,7 +24,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_cdc_ecm.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -44,12 +44,27 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_DEVICE_CLASS_CDC_ECM_H #define UX_DEVICE_CLASS_CDC_ECM_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 + #include "nx_api.h" #include "ux_network_driver.h" @@ -120,7 +135,7 @@ #define UX_DEVICE_CLASS_CDC_ECM_VERSION_MAJOR 0x00000001 #define UX_DEVICE_CLASS_CDC_ECM_VERSION_MINOR 0x00000000 -/* Define CDC_ECM Conection type supported. Set to conectionless. */ +/* Define CDC_ECM Connection type supported. Set to conectionless. */ #define UX_DEVICE_CLASS_CDC_ECM_DF_CONNECTIONLESS 0x00000001 #define UX_DEVICE_CLASS_CDC_ECM_DF_CONNECTION_ORIENTED 0x00000002 #define UX_DEVICE_CLASS_CDC_ECM_DF_CONNECTION_SUPPORTED UX_DEVICE_CLASS_CDC_ECM_DF_CONNECTIONLESS @@ -339,4 +354,10 @@ VOID _ux_device_class_cdc_ecm_interrupt_thread(ULONG cdc_ecm_class); #define ux_device_class_cdc_ecm_read _ux_device_class_cdc_ecm_read #define ux_device_class_cdc_ecm_write _ux_device_class_cdc_ecm_write +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif /* UX_DEVICE_CLASS_CDC_ECM_H */ 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 16ffde8a..da31b1f5 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 */ diff --git a/common/usbx_device_classes/inc/ux_device_class_hid.h b/common/usbx_device_classes/inc/ux_device_class_hid.h index fc86bddb..48eac985 100644 --- a/common/usbx_device_classes/inc/ux_device_class_hid.h +++ b/common/usbx_device_classes/inc/ux_device_class_hid.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_hid.h PORTABLE C */ -/* 6.1.3 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -50,12 +50,26 @@ /* added Get/Set Protocol */ /* request support, */ /* resulting in version 6.1.3 */ +/* 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_HID_H #define UX_DEVICE_CLASS_HID_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 HID Class constants. */ #define UX_DEVICE_CLASS_HID_CLASS 0x03 @@ -193,4 +207,10 @@ UINT _ux_device_class_hid_report_get(UX_SLAVE_CLASS_HID *hid, ULONG descriptor_ #define ux_device_class_hid_protocol_get(hid) (hid -> ux_device_class_hid_protocol) +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_device_classes/inc/ux_device_class_pima.h b/common/usbx_device_classes/inc/ux_device_class_pima.h index 36558ba3..93dbfab7 100644 --- a/common/usbx_device_classes/inc/ux_device_class_pima.h +++ b/common/usbx_device_classes/inc/ux_device_class_pima.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_pima.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_DEVICE_CLASS_PIMA_H #define UX_DEVICE_CLASS_PIMA_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 PIMA Class constants. */ #define UX_DEVICE_CLASS_PIMA_CLASS_TRANSFER_TIMEOUT 300000 @@ -998,4 +1012,10 @@ extern USHORT _ux_device_class_pima_device_prop_supported[]; +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_device_classes/inc/ux_device_class_rndis.h b/common/usbx_device_classes/inc/ux_device_class_rndis.h index 7142cf38..b5ff9748 100644 --- a/common/usbx_device_classes/inc/ux_device_class_rndis.h +++ b/common/usbx_device_classes/inc/ux_device_class_rndis.h @@ -24,7 +24,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_rndis.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -44,12 +44,27 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_DEVICE_CLASS_RNDIS_H #define UX_DEVICE_CLASS_RNDIS_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 + #include "nx_api.h" #include "ux_network_driver.h" @@ -113,7 +128,7 @@ #define UX_DEVICE_CLASS_RNDIS_VERSION_MAJOR 0x00000001 #define UX_DEVICE_CLASS_RNDIS_VERSION_MINOR 0x00000000 -/* Define RNDIS Conection type supported. Set to conectionless. */ +/* Define RNDIS Connection type supported. Set to conectionless. */ #define UX_DEVICE_CLASS_RNDIS_DF_CONNECTIONLESS 0x00000001 #define UX_DEVICE_CLASS_RNDIS_DF_CONNECTION_ORIENTED 0x00000002 #define UX_DEVICE_CLASS_RNDIS_DF_CONNECTION_SUPPORTED UX_DEVICE_CLASS_RNDIS_DF_CONNECTIONLESS @@ -444,7 +459,7 @@ #define UX_DEVICE_CLASS_RNDIS_VENDOR_DESCRIPTION_MAX_RESPONSE_LENGTH (UX_DEVICE_CLASS_RNDIS_CMPLT_QUERY_INFO_BUFFER + UX_DEVICE_CLASS_RNDIS_VENDOR_DESCRIPTION_MAX_LENGTH) #define UX_DEVICE_CLASS_RNDIS_NODE_ID_RESPONSE_LENGTH (UX_DEVICE_CLASS_RNDIS_CMPLT_QUERY_INFO_BUFFER + UX_DEVICE_CLASS_RNDIS_NODE_ID_LENGTH) -/* Decide maximun size of RNDIS response buffer (with 1 ~ 4 bytes as padding and aligned to 4 bytes). */ +/* Decide maximum size of RNDIS response buffer (with 1 ~ 4 bytes as padding and aligned to 4 bytes). */ #define UX_DEVICE_CLASS_RNDIS_MAX(a, b) (((a) > (b)) ? (a) : (b)) #define UX_DEVICE_CLASS_RNDIS_MAX_CONTROL_RESPONSE_LENGTH ((( \ UX_DEVICE_CLASS_RNDIS_MAX(UX_DEVICE_CLASS_RNDIS_CMPLT_INITIALIZE_RESPONSE_LENGTH, \ @@ -572,4 +587,10 @@ VOID _ux_device_class_rndis_bulkout_thread(ULONG rndis_class); /* Define OID supported List. */ extern ULONG ux_device_class_rndis_oid_supported_list[]; +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif /* UX_DEVICE_CLASS_RNDIS_H */ diff --git a/common/usbx_device_classes/inc/ux_device_class_storage.h b/common/usbx_device_classes/inc/ux_device_class_storage.h index c55bbec7..2db4d6ef 100644 --- a/common/usbx_device_classes/inc/ux_device_class_storage.h +++ b/common/usbx_device_classes/inc/ux_device_class_storage.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_device_class_storage.h PORTABLE C */ -/* 6.1.3 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -47,12 +47,26 @@ /* 12-31-2020 Chaoqiong Xiao Modified comment(s), */ /* fixed USB CV test issues, */ /* resulting in version 6.1.3 */ +/* 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_STORAGE_H #define UX_DEVICE_CLASS_STORAGE_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 User configurable Storage Class constants. */ #ifndef UX_MAX_SLAVE_LUN @@ -555,4 +569,10 @@ UINT _ux_device_class_storage_read_dvd_structure(UX_SLAVE_CLASS_STORAGE *stor #define ux_device_class_storage_entry _ux_device_class_storage_entry +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_device_classes/src/ux_device_class_cdc_ecm_activate.c b/common/usbx_device_classes/src/ux_device_class_cdc_ecm_activate.c index 1ccac6e0..343818b1 100644 --- a/common/usbx_device_classes/src/ux_device_class_cdc_ecm_activate.c +++ b/common/usbx_device_classes/src/ux_device_class_cdc_ecm_activate.c @@ -33,7 +33,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_device_class_cdc_ecm_activate PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -69,6 +69,9 @@ /* refer to TX symbols instead */ /* of using them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_device_class_cdc_ecm_activate(UX_SLAVE_CLASS_COMMAND *command) @@ -193,7 +196,7 @@ ULONG physical_address_lsw; /* Not all endpoints have been found. Major error, do not proceed. */ return(UX_ERROR); - /* Declare the link to be up. That may need to change later to make it dependant on the + /* Declare the link to be up. That may need to change later to make it dependent on the WAN/Wireless modem. */ cdc_ecm -> ux_slave_class_cdc_ecm_link_state = UX_DEVICE_CLASS_CDC_ECM_LINK_STATE_UP; diff --git a/common/usbx_device_classes/src/ux_device_class_hid_descriptor_send.c b/common/usbx_device_classes/src/ux_device_class_hid_descriptor_send.c index c7fcc322..ca48a5d7 100644 --- a/common/usbx_device_classes/src/ux_device_class_hid_descriptor_send.c +++ b/common/usbx_device_classes/src/ux_device_class_hid_descriptor_send.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_device_class_hid_descriptor_send PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -74,6 +74,9 @@ /* verified memset and memcpy */ /* cases, */ /* resulting in version 6.1 */ +/* 08-02-2021 Chaoqiong Xiao Modified comment(s), */ +/* fixed HID descriptor search,*/ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_device_class_hid_descriptor_send(UX_SLAVE_CLASS_HID *hid, ULONG descriptor_type, @@ -89,6 +92,7 @@ UCHAR * device_framework_end; ULONG descriptor_length; UINT status = UX_ERROR; ULONG length; +UCHAR interface_number = 0xFF; UX_PARAMETER_NOT_USED(request_index); @@ -133,10 +137,16 @@ ULONG length; /* And its length. */ descriptor_length = (ULONG) *device_framework; - + + /* Save interface number for later check. */ + if (descriptor_type == UX_INTERFACE_DESCRIPTOR_ITEM) + interface_number = *(device_framework + 2); + /* Check if this is a HID report descriptor. */ - if (descriptor_type == UX_DEVICE_CLASS_HID_DESCRIPTOR_HID) + if ((descriptor_type == UX_DEVICE_CLASS_HID_DESCRIPTOR_HID) && + (interface_number == (UCHAR)request_index)) { + /* Ensure the host does not demand a length beyond our descriptor (Windows does that) and do not return more than what is allowed. */ if (descriptor_length < host_length) diff --git a/common/usbx_device_classes/src/ux_device_class_rndis_deactivate.c b/common/usbx_device_classes/src/ux_device_class_rndis_deactivate.c index 2956aec0..eabb8fa6 100644 --- a/common/usbx_device_classes/src/ux_device_class_rndis_deactivate.c +++ b/common/usbx_device_classes/src/ux_device_class_rndis_deactivate.c @@ -34,7 +34,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_device_class_rndis_deactivate PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -72,6 +72,9 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_device_class_rndis_deactivate(UX_SLAVE_CLASS_COMMAND *command) @@ -98,7 +101,7 @@ UX_SLAVE_CLASS *class; if (interface -> ux_slave_interface_descriptor.bInterfaceClass == UX_DEVICE_CLASS_RNDIS_CLASS_COMMUNICATION_CONTROL) { - /* Declare the link to be down. That may nd to change later to make it dependant on the + /* Declare the link to be down. That may need to change later to make it dependant on the WAN/Wireless modem. */ rndis -> ux_slave_class_rndis_link_state = UX_DEVICE_CLASS_RNDIS_LINK_STATE_DOWN; diff --git a/common/usbx_host_classes/inc/ux_host_class_asix.h b/common/usbx_host_classes/inc/ux_host_class_asix.h index 477b6323..717842c2 100644 --- a/common/usbx_host_classes/inc/ux_host_class_asix.h +++ b/common/usbx_host_classes/inc/ux_host_class_asix.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_asix.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_ASIX_H #define UX_HOST_CLASS_ASIX_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 + #include "nx_api.h" #include "ux_network_driver.h" @@ -415,4 +429,10 @@ UINT _ux_host_class_asix_setup(UX_HOST_CLASS_ASIX *asix); #define ux_host_class_asix_read _ux_host_class_asix_read #define ux_host_class_asix_write _ux_host_class_asix_write +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_audio.h b/common/usbx_host_classes/inc/ux_host_class_audio.h index db23a185..476bd7b9 100644 --- a/common/usbx_host_classes/inc/ux_host_class_audio.h +++ b/common/usbx_host_classes/inc/ux_host_class_audio.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_audio.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_AUDIO_H #define UX_HOST_CLASS_AUDIO_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 Audio Class main constants. */ @@ -445,6 +459,12 @@ UINT _ux_host_class_audio_write(UX_HOST_CLASS_AUDIO *audio, UX_HOST_CLASS_AUD #define ux_host_class_audio_streaming_terminal_get _ux_host_class_audio_streaming_terminal_get #define ux_host_class_audio_write _ux_host_class_audio_write +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_cdc_acm.h b/common/usbx_host_classes/inc/ux_host_class_cdc_acm.h index 0e0795a3..52275410 100644 --- a/common/usbx_host_classes/inc/ux_host_class_cdc_acm.h +++ b/common/usbx_host_classes/inc/ux_host_class_cdc_acm.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_cdc_acm.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_CDC_ACM_H #define UX_HOST_CLASS_CDC_ACM_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 CDC ACM Class constants. */ #define UX_HOST_CLASS_CDC_ACM_DEVICE_INIT_DELAY 1000 @@ -317,4 +331,10 @@ VOID _ux_host_class_cdc_acm_reception_callback (UX_TRANSFER *transfer_request); #define ux_host_class_cdc_acm_reception_stop _ux_host_class_cdc_acm_reception_stop +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_cdc_ecm.h b/common/usbx_host_classes/inc/ux_host_class_cdc_ecm.h index f139d034..9c6ff123 100644 --- a/common/usbx_host_classes/inc/ux_host_class_cdc_ecm.h +++ b/common/usbx_host_classes/inc/ux_host_class_cdc_ecm.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_cdc_ecm.h PORTABLE C */ -/* 6.1.4 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -50,12 +50,26 @@ /* compile option for using */ /* packet pool from NetX, */ /* resulting in version 6.1.4 */ +/* 08-02-2021 Chaoqiong Xiao Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_CDC_ECM_H #define UX_HOST_CLASS_CDC_ECM_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 + /* Include the NetX API. */ #include "nx_api.h" #include "ux_network_driver.h" @@ -306,4 +320,10 @@ UINT _ux_host_class_cdc_ecm_mac_address_get(UX_HOST_CLASS_CDC_ECM *cdc_ecm); #define ux_host_class_cdc_ecm_entry _ux_host_class_cdc_ecm_entry #define ux_host_class_cdc_ecm_write _ux_host_class_cdc_ecm_write +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_gser.h b/common/usbx_host_classes/inc/ux_host_class_gser.h index 5b846861..b176f155 100644 --- a/common/usbx_host_classes/inc/ux_host_class_gser.h +++ b/common/usbx_host_classes/inc/ux_host_class_gser.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_gser.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_GSER_H #define UX_HOST_CLASS_GSER_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 Sierra Wireless AR Class constants. */ @@ -263,4 +277,10 @@ UINT _ux_host_class_gser_reception_start (UX_HOST_CLASS_GSER *gser, #define ux_host_class_gser_reception_start _ux_host_class_gser_reception_start #define ux_host_class_gser_reception_stop _ux_host_class_gser_reception_stop +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_hid.h b/common/usbx_host_classes/inc/ux_host_class_hid.h index 49b1cec5..253b7892 100644 --- a/common/usbx_host_classes/inc/ux_host_class_hid.h +++ b/common/usbx_host_classes/inc/ux_host_class_hid.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_hid.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -47,12 +47,26 @@ /* them directly, fixed struct */ /* field definition issues, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_HID_H #define UX_HOST_CLASS_HID_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 HID Class constants. */ @@ -1032,5 +1046,11 @@ VOID _ux_host_class_hid_transfer_request_completed(UX_TRANSFER *transfer_requ #define ux_host_class_hid_report_id_get _ux_host_class_hid_report_id_get #define ux_host_class_hid_report_set _ux_host_class_hid_report_set +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_hid_keyboard.h b/common/usbx_host_classes/inc/ux_host_class_hid_keyboard.h index 229302ad..df42c23b 100644 --- a/common/usbx_host_classes/inc/ux_host_class_hid_keyboard.h +++ b/common/usbx_host_classes/inc/ux_host_class_hid_keyboard.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_hid_keyboard.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_HID_KEYBOARD_H #define UX_HOST_CLASS_HID_KEYBOARD_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 HID Keyboard Class constants. */ @@ -220,5 +234,11 @@ UINT _ux_host_class_hid_keyboard_ioctl(UX_HOST_CLASS_HID_KEYBOARD *keyboard_i #define ux_host_class_hid_keyboard_key_get _ux_host_class_hid_keyboard_key_get #define ux_host_class_hid_keyboard_ioctl _ux_host_class_hid_keyboard_ioctl +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_hid_mouse.h b/common/usbx_host_classes/inc/ux_host_class_hid_mouse.h index 00846a75..9df9526f 100644 --- a/common/usbx_host_classes/inc/ux_host_class_hid_mouse.h +++ b/common/usbx_host_classes/inc/ux_host_class_hid_mouse.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_hid_mouse.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -43,12 +43,26 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_HID_MOUSE_H #define UX_HOST_CLASS_HID_MOUSE_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 HID Mouse Class constants. */ @@ -106,4 +120,10 @@ UINT _ux_host_class_hid_mouse_wheel_get(UX_HOST_CLASS_HID_MOUSE *mouse_instance #define ux_host_class_hid_mouse_position_get _ux_host_class_hid_mouse_position_get #define ux_host_class_hid_mouse_wheel_get _ux_host_class_hid_mouse_wheel_get +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_hid_remote_control.h b/common/usbx_host_classes/inc/ux_host_class_hid_remote_control.h index a8685fa2..03bb69de 100644 --- a/common/usbx_host_classes/inc/ux_host_class_hid_remote_control.h +++ b/common/usbx_host_classes/inc/ux_host_class_hid_remote_control.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_hid_remote_control.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -43,12 +43,26 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_HID_REMOTE_CONTROL_H #define UX_HOST_CLASS_HID_REMOTE_CONTROL_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 HID Remote Control Class constants. */ @@ -85,5 +99,11 @@ UINT _ux_host_class_hid_remote_control_usage_get(UX_HOST_CLASS_HID_REMOTE_CON #define ux_host_class_hid_remote_control_entry _ux_host_class_hid_remote_control_entry #define ux_host_class_hid_remote_control_usage_get _ux_host_class_hid_remote_control_usage_get +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_hub.h b/common/usbx_host_classes/inc/ux_host_class_hub.h index 50f76d58..7611dece 100644 --- a/common/usbx_host_classes/inc/ux_host_class_hub.h +++ b/common/usbx_host_classes/inc/ux_host_class_hub.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_hub.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -43,12 +43,26 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_HUB_H #define UX_HOST_CLASS_HUB_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 HUB Class constants. */ @@ -196,5 +210,11 @@ UINT _ux_host_class_hub_ports_power(UX_HOST_CLASS_HUB *hub); UINT _ux_host_class_hub_status_get(UX_HOST_CLASS_HUB *hub, UINT port, USHORT *port_status, USHORT *port_change); VOID _ux_host_class_hub_transfer_request_completed(UX_TRANSFER *transfer_request); +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_pima.h b/common/usbx_host_classes/inc/ux_host_class_pima.h index 5b3d0b68..f5555527 100644 --- a/common/usbx_host_classes/inc/ux_host_class_pima.h +++ b/common/usbx_host_classes/inc/ux_host_class_pima.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_pima.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_PIMA_H #define UX_HOST_CLASS_PIMA_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 PIMA Class constants. */ #define UX_HOST_CLASS_PIMA_CLASS_TRANSFER_TIMEOUT 300000 @@ -572,4 +586,10 @@ UINT _ux_host_class_pima_device_info_get(UX_HOST_CLASS_PIMA *pima, #define ux_host_class_pima_object_handles_get _ux_host_class_pima_object_handles_get #define ux_host_class_pima_num_objects_get _ux_host_class_pima_num_objects_get +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_printer.h b/common/usbx_host_classes/inc/ux_host_class_printer.h index 933c5bae..0a53f229 100644 --- a/common/usbx_host_classes/inc/ux_host_class_printer.h +++ b/common/usbx_host_classes/inc/ux_host_class_printer.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_printer.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_PRINTER_H #define UX_HOST_CLASS_PRINTER_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 Printer Class constants. */ @@ -121,4 +135,10 @@ UINT _ux_host_class_printer_write(UX_HOST_CLASS_PRINTER *printer, UCHAR * dat #define ux_host_class_printer_status_get _ux_host_class_printer_status_get #define ux_host_class_printer_write _ux_host_class_printer_write +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_prolific.h b/common/usbx_host_classes/inc/ux_host_class_prolific.h index 5e69646b..6534f411 100644 --- a/common/usbx_host_classes/inc/ux_host_class_prolific.h +++ b/common/usbx_host_classes/inc/ux_host_class_prolific.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_prolific.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_PROLIFIC_H #define UX_HOST_CLASS_PROLIFIC_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 PROLIFIC Class constants. */ #define UX_HOST_CLASS_PROLIFIC_DEVICE_INIT_DELAY (1 * UX_PERIODIC_RATE) @@ -295,4 +309,10 @@ UINT _ux_host_class_prolific_setup(UX_HOST_CLASS_PROLIFIC *prolific); #define ux_host_class_prolific_reception_start _ux_host_class_prolific_reception_start #define ux_host_class_prolific_setup _ux_host_class_prolific_setup +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_storage.h b/common/usbx_host_classes/inc/ux_host_class_storage.h index 977d66c0..ea4b678c 100755 --- a/common/usbx_host_classes/inc/ux_host_class_storage.h +++ b/common/usbx_host_classes/inc/ux_host_class_storage.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_storage.h PORTABLE C */ -/* 6.1.3 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -57,12 +57,26 @@ /* resulting in version 6.1.2 */ /* 12-31-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1.3 */ +/* 08-02-2021 Chaoqiong Xiao Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_STORAGE_H #define UX_HOST_CLASS_STORAGE_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 + #if !defined(UX_HOST_CLASS_STORAGE_NO_FILEX) /* Include the FileX API. */ @@ -538,4 +552,10 @@ UINT _ux_host_class_storage_unit_ready_test(UX_HOST_CLASS_STORAGE *storage); #define ux_host_class_storage_media_unlock _ux_host_class_storage_media_unlock #endif +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_swar.h b/common/usbx_host_classes/inc/ux_host_class_swar.h index a5e9fb61..e6934d75 100644 --- a/common/usbx_host_classes/inc/ux_host_class_swar.h +++ b/common/usbx_host_classes/inc/ux_host_class_swar.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_swar.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_SWAR_H #define UX_HOST_CLASS_SWAR_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 Sierra Wireless AR Class constants. */ @@ -146,4 +160,10 @@ UINT _ux_host_class_swar_reception_start (UX_HOST_CLASS_SWAR *swar, #define ux_host_class_swar_reception_start _ux_host_class_swar_reception_start #define ux_host_class_swar_setup _ux_host_class_swar_setup +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/inc/ux_host_class_video.h b/common/usbx_host_classes/inc/ux_host_class_video.h index 2d5822b9..109d5c91 100644 --- a/common/usbx_host_classes/inc/ux_host_class_video.h +++ b/common/usbx_host_classes/inc/ux_host_class_video.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_host_class_video.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -49,12 +49,29 @@ /* symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ -/* */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* added new definitions */ +/* according to UVC 1.5 Class */ +/* specification, */ +/* resulting in version 6.1.8 */ +/* */ /**************************************************************************/ #ifndef UX_HOST_CLASS_VIDEO_H #define UX_HOST_CLASS_VIDEO_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 external static data. */ extern UCHAR _ux_system_class_video_interface_descriptor_structure[]; extern UCHAR _ux_system_class_video_input_terminal_descriptor_structure[]; @@ -86,6 +103,7 @@ extern UCHAR _ux_system_host_class_video_name[]; #define UX_HOST_CLASS_VIDEO_SUBCLASS_UNDEFINED 0 #define UX_HOST_CLASS_VIDEO_SUBCLASS_CONTROL 1 #define UX_HOST_CLASS_VIDEO_SUBCLASS_STREAMING 2 +#define UX_HOST_CLASS_VIDEO_SUBCLASS_INTERFACE_COLLECTION 3 /* Define Video Class main descriptor types. */ @@ -106,6 +124,7 @@ extern UCHAR _ux_system_host_class_video_name[]; #define UX_HOST_CLASS_VIDEO_VC_SELECTOR_UNIT 0x04 #define UX_HOST_CLASS_VIDEO_VC_PROCESSING_UNIT 0x05 #define UX_HOST_CLASS_VIDEO_VC_EXTENSION_UNIT 0x06 +#define UX_HOST_CLASS_VIDEO_VC_ENCODING_UNIT 0x07 /* Define Video Class specific VS . */ @@ -123,6 +142,12 @@ extern UCHAR _ux_system_host_class_video_name[]; #define UX_HOST_CLASS_VIDEO_VS_FORMAT_FRAME_BASED 0x10 #define UX_HOST_CLASS_VIDEO_VS_FRAME_FRAME_BASED 0x11 #define UX_HOST_CLASS_VIDEO_VS_FORMAT_STREAM_BASED 0x12 +#define UX_HOST_CLASS_VIDEO_VS_FORMAT_H264 0x13 +#define UX_HOST_CLASS_VIDEO_VS_FRAME_H264 0x14 +#define UX_HOST_CLASS_VIDEO_VS_FORMAT_H264_SIMULCAST 0x15 +#define UX_HOST_CLASS_VIDEO_VS_FORMAT_VP8 0x16 +#define UX_HOST_CLASS_VIDEO_VS_FRAME_VP8 0x17 +#define UX_HOST_CLASS_VIDEO_VS_FORMAT_VP8_SIMULCAST 0x18 /* Define Video Class specific Control Selectors. */ @@ -145,6 +170,10 @@ extern UCHAR _ux_system_host_class_video_name[]; #define UX_HOST_CLASS_VIDEO_CT_ROLL_ABSOLUTE_CONTROL 0x0F #define UX_HOST_CLASS_VIDEO_CT_ROLL_RELATIVE_CONTROL 0x10 #define UX_HOST_CLASS_VIDEO_CT_PRIVACY_CONTROL 0x11 +#define UX_HOST_CLASS_VIDEO_CT_FOCUS_SIMPLE_CONTROL 0x12 +#define UX_HOST_CLASS_VIDEO_CT_WINDOW_CONTROL 0x13 +#define UX_HOST_CLASS_VIDEO_CT_REGION_OF_INTEREST_CONTROL 0x14 + #define UX_HOST_CLASS_VIDEO_PU_CONTROL_UNDEFINED 0x00 #define UX_HOST_CLASS_VIDEO_PU_BACKLIGHT_COMPENSATION_CONTROL 0x01 @@ -165,6 +194,7 @@ extern UCHAR _ux_system_host_class_video_name[]; #define UX_HOST_CLASS_VIDEO_PU_HUE_AUTO_CONTROL 0x10 #define UX_HOST_CLASS_VIDEO_PU_ANALOG_VIDEO_STANDARD_CONTROL 0x11 #define UX_HOST_CLASS_VIDEO_PU_ANALOG_LOCK_STATUS_CONTROL 0x12 +#define UX_HOST_CLASS_VIDEO_PU_CONTRAST_AUTO_CONTROL 0x13 #define UX_HOST_CLASS_VIDEO_VS_CONTROL_UNDEFINED 0x00 @@ -203,6 +233,7 @@ extern UCHAR _ux_system_host_class_video_name[]; #define UX_HOST_CLASS_VIDEO_REQUEST_ERROR_CODE_INVALID_INPUT 0x05 #define UX_HOST_CLASS_VIDEO_REQUEST_ERROR_CODE_INVALID_CONTROL 0x06 #define UX_HOST_CLASS_VIDEO_REQUEST_ERROR_CODE_INVALID_REQUEST 0x07 +#define UX_HOST_CLASS_VIDEO_REQUEST_ERROR_CODE_INVALID_VALUE_WITHIN_RANGE 0x08 #define UX_HOST_CLASS_VIDEO_REQUEST_ERROR_CODE_UNKNOWN 0xFF @@ -245,6 +276,11 @@ extern UCHAR _ux_system_host_class_video_name[]; #define UX_HOST_CLASS_VIDEO_GET_RES 0x84 #define UX_HOST_CLASS_VIDEO_GET_INFO 0x86 #define UX_HOST_CLASS_VIDEO_GET_DEF 0x87 +#define UX_HOST_CLASS_VIDEO_GET_CUR_ALL 0x91 +#define UX_HOST_CLASS_VIDEO_GET_MIN_ALL 0x92 +#define UX_HOST_CLASS_VIDEO_GET_MAX_ALL 0x93 +#define UX_HOST_CLASS_VIDEO_GET_RES_ALL 0x94 +#define UX_HOST_CLASS_VIDEO_GET_GET_DEF_ALL 0x97 /* Define Video Class error codes. */ @@ -302,6 +338,7 @@ extern UCHAR _ux_system_host_class_video_name[]; #define UX_HOST_CLASS_VIDEO_TCS_PU_HUE_AUTO_CONTROL 0x10 #define UX_HOST_CLASS_VIDEO_TCS_PU_ANALOG_VIDEO_STANDARD_CONTROL 0x11 #define UX_HOST_CLASS_VIDEO_TCS_PU_ANALOG_LOCK_STATUS_CONTROL 0x12 +#define UX_HOST_CLASS_VIDEO_TCS_PU_CONTRAST_AUTO_CONTROL 0x13 #define UX_HOST_CLASS_VIDEO_TCS_XU_CONTROL_UNDEFINED 0x00 @@ -650,6 +687,12 @@ UINT _ux_host_class_video_control_request(UX_HOST_CLASS_VIDEO *video, #define ux_host_class_video_entities_parse _ux_host_class_video_entities_parse #define ux_host_class_video_control_request _ux_host_class_video_control_request +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_classes/src/ux_host_class_asix_transmission_callback.c b/common/usbx_host_classes/src/ux_host_class_asix_transmission_callback.c index f21e96ab..a7e3da0a 100644 --- a/common/usbx_host_classes/src/ux_host_class_asix_transmission_callback.c +++ b/common/usbx_host_classes/src/ux_host_class_asix_transmission_callback.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_host_class_asix_transmission_callback PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -71,6 +71,9 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ VOID _ux_host_class_asix_transmission_callback (UX_TRANSFER *transfer_request) @@ -115,7 +118,7 @@ UCHAR *packet_header; /* Load the address of the current packet header of the physical header. */ packet_header = next_packet -> nx_packet_prepend_ptr; - /* Substract 2 USHORT to store length of the packet. */ + /* Subtract 2 USHORT to store length of the packet. */ packet_header -= sizeof(USHORT) * 2; /* Store the length of the payload in the first USHORT. */ diff --git a/common/usbx_host_classes/src/ux_host_class_asix_write.c b/common/usbx_host_classes/src/ux_host_class_asix_write.c index d42ff5d5..b5b49381 100644 --- a/common/usbx_host_classes/src/ux_host_class_asix_write.c +++ b/common/usbx_host_classes/src/ux_host_class_asix_write.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_host_class_asix_write PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -71,6 +71,9 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_host_class_asix_write(VOID *asix_class, NX_PACKET *packet) @@ -105,7 +108,7 @@ UX_HOST_CLASS_ASIX *asix; /* Load the address of the current packet header at the physical header. */ packet_header = packet -> nx_packet_prepend_ptr; - /* Substract 2 USHORT to store length of the packet. */ + /* Subtract 2 USHORT to store length of the packet. */ packet_header -= sizeof(USHORT) * 2; #if defined(UX_HOST_CLASS_ASIX_HEADER_CHECK_ENABLE) diff --git a/common/usbx_host_classes/src/ux_host_class_hid_report_add.c b/common/usbx_host_classes/src/ux_host_class_hid_report_add.c index 65bfaaee..f97ccc74 100644 --- a/common/usbx_host_classes/src/ux_host_class_hid_report_add.c +++ b/common/usbx_host_classes/src/ux_host_class_hid_report_add.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_host_class_hid_report_add PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -75,6 +75,9 @@ /* verified memset and memcpy */ /* cases, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_host_class_hid_report_add(UX_HOST_CLASS_HID *hid, UCHAR *descriptor, UX_HOST_CLASS_HID_ITEM *item) @@ -164,7 +167,7 @@ ULONG current_field_address; if ((hid_report != UX_NULL) && (hid_report -> ux_host_class_hid_report_id == hid_parser -> ux_host_class_hid_parser_global.ux_host_class_hid_global_item_report_id)) { - /* So we did not need a new report afterall! */ + /* So we did not need a new report after all! */ _ux_utility_memory_free(new_hid_report); new_hid_report = hid_report; } diff --git a/common/usbx_host_classes/src/ux_host_class_storage_device_initialize.c b/common/usbx_host_classes/src/ux_host_class_storage_device_initialize.c index e3798a97..799dfeea 100644 --- a/common/usbx_host_classes/src/ux_host_class_storage_device_initialize.c +++ b/common/usbx_host_classes/src/ux_host_class_storage_device_initialize.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_host_class_storage_device_initialize PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -79,6 +79,10 @@ /* added option to disable FX */ /* media integration, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed logic of creating */ +/* multiple storage media, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_host_class_storage_device_initialize(UX_HOST_CLASS_STORAGE *storage) @@ -159,7 +163,9 @@ UINT inst_index; { case UX_HOST_CLASS_STORAGE_MEDIA_FAT_DISK: + /* Fall through. */ case UX_HOST_CLASS_STORAGE_MEDIA_OPTICAL_DISK: + /* Fall through. */ case UX_HOST_CLASS_STORAGE_MEDIA_IOMEGA_CLICK: #if !defined(UX_HOST_CLASS_STORAGE_NO_FILEX) @@ -186,25 +192,28 @@ UINT inst_index; storage_media ++, inst_index++) { - /* Skip used storage media slots. */ - if (storage_media -> ux_host_class_storage_media_storage != UX_NULL) - continue; + /* Find an unused storage media slot. */ + if (storage_media -> ux_host_class_storage_media_storage == UX_NULL) + { - /* Use this free storage media slot. */ - storage_media -> ux_host_class_storage_media_storage = storage; + /* Use this free storage media slot. */ + storage_media -> ux_host_class_storage_media_storage = storage; - /* Save media information. */ - storage_media -> ux_host_class_storage_media_lun = (UCHAR)storage -> ux_host_class_storage_lun; - storage_media -> ux_host_class_storage_media_sector_size = (USHORT)storage -> ux_host_class_storage_sector_size; - storage_media -> ux_host_class_storage_media_number_sectors = storage -> ux_host_class_storage_last_sector_number + 1; + /* Save media information. */ + storage_media -> ux_host_class_storage_media_lun = (UCHAR)storage -> ux_host_class_storage_lun; + storage_media -> ux_host_class_storage_media_sector_size = (USHORT)storage -> ux_host_class_storage_sector_size; + storage_media -> ux_host_class_storage_media_number_sectors = storage -> ux_host_class_storage_last_sector_number + 1; - /* Invoke callback for media insertion. */ - if (_ux_system_host -> ux_system_host_change_function != UX_NULL) - { + /* Invoke callback for media insertion. */ + if (_ux_system_host -> ux_system_host_change_function != UX_NULL) + { - /* Call system change function. */ - _ux_system_host -> ux_system_host_change_function(UX_STORAGE_MEDIA_INSERTION, - storage -> ux_host_class_storage_class, (VOID *) storage_media); + /* Call system change function. */ + _ux_system_host -> ux_system_host_change_function(UX_STORAGE_MEDIA_INSERTION, + storage -> ux_host_class_storage_class, (VOID *) storage_media); + } + + break; } } #endif diff --git a/common/usbx_host_classes/src/ux_host_class_storage_media_get.c b/common/usbx_host_classes/src/ux_host_class_storage_media_get.c index 86b32818..0e35ebc6 100644 --- a/common/usbx_host_classes/src/ux_host_class_storage_media_get.c +++ b/common/usbx_host_classes/src/ux_host_class_storage_media_get.c @@ -36,7 +36,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_host_class_storage_media_get PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -68,6 +68,9 @@ /* DATE NAME DESCRIPTION */ /* */ /* 09-30-2020 Chaoqiong Xiao Initial Version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_host_class_storage_media_get(UX_HOST_CLASS_STORAGE *storage, @@ -89,10 +92,10 @@ UINT scan_index, found_index; /* Get storage class instance. */ class_inst = storage -> ux_host_class_storage_class; - /* Get shared storage medias array. */ + /* Get shared storage media array. */ storage_medias = (UX_HOST_CLASS_STORAGE_MEDIA *)class_inst -> ux_host_class_media; - /* Search medias to find the right one. */ + /* Search media to find the right one. */ for(scan_index = 0, found_index = 0; scan_index < UX_HOST_CLASS_STORAGE_MAX_MEDIA; scan_index ++) diff --git a/common/usbx_host_classes/src/ux_host_class_video_entities_parse.c b/common/usbx_host_classes/src/ux_host_class_video_entities_parse.c index 372f9f38..e628c6ff 100644 --- a/common/usbx_host_classes/src/ux_host_class_video_entities_parse.c +++ b/common/usbx_host_classes/src/ux_host_class_video_entities_parse.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_host_class_video_entities_parse PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -79,6 +79,9 @@ /* DATE NAME DESCRIPTION */ /* */ /* 09-30-2020 Chaoqiong Xiao Initial Version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_host_class_video_entities_parse(UX_HOST_CLASS_VIDEO *video, @@ -133,7 +136,7 @@ UINT status; if (descriptor[5] == UX_HOST_CLASS_VIDEO_CLASS) { - /* VideoControl Inteface. */ + /* VideoControl Interface. */ if (descriptor[6] == UX_HOST_CLASS_VIDEO_SUBCLASS_CONTROL) /* Mark we have found it. */ diff --git a/common/usbx_host_controllers/inc/ux_hcd_ehci.h b/common/usbx_host_controllers/inc/ux_hcd_ehci.h index 2154558e..036bbf04 100755 --- a/common/usbx_host_controllers/inc/ux_hcd_ehci.h +++ b/common/usbx_host_controllers/inc/ux_hcd_ehci.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_hcd_ehci.h PORTABLE C */ -/* 6.1.2 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -50,14 +50,29 @@ /* used unsigned defines, */ /* named unions and structs, */ /* resulting in version 6.1.2 */ +/* 08-02-2021 Chaoqiong Xiao Modified comment(s), */ +/* fixed spelling error, */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HCD_EHCI_H #define UX_HCD_EHCI_H +/* Determine if a C++ compiler is being used. If so, ensure that standard + C is used to process the API information. */ -/* Possible defined EHCI HCD extentions. */ +#ifdef __cplusplus + +/* Yes, C++ compiler is present. Use standard C. */ +extern "C" { + +#endif + + +/* Possible defined EHCI HCD extensions. */ /* Extension for peripheral host mode select (function like). */ /* #define UX_HCD_EHCI_EXT_USB_HOST_MODE_ENABLE(hcd_ehci) */ @@ -827,5 +842,11 @@ VOID _ux_hcd_ehci_transfer_request_process(UX_TRANSFER *transfer_request); #define ux_hcd_ehci_initialize _ux_hcd_ehci_initialize #define ux_hcd_ehci_interrupt_handler _ux_hcd_ehci_interrupt_handler +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_controllers/inc/ux_hcd_ohci.h b/common/usbx_host_controllers/inc/ux_hcd_ohci.h index 47de75e0..f18977e5 100755 --- a/common/usbx_host_controllers/inc/ux_hcd_ohci.h +++ b/common/usbx_host_controllers/inc/ux_hcd_ohci.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_hcd_ohci.h PORTABLE C */ -/* 6.1.2 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* 11-09-2020 Chaoqiong Xiao Modified comment(s), */ /* used unsigned defines, */ /* resulting in version 6.1.2 */ +/* 08-02-2021 Chaoqiong Xiao Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_HCD_OHCI_H #define UX_HCD_OHCI_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 generic OHCI constants. */ @@ -394,5 +408,11 @@ VOID _ux_hcd_ohci_transfer_request_process(UX_TRANSFER *transfer_request); #define ux_hcd_ohci_initialize _ux_hcd_ohci_initialize #define ux_hcd_ohci_interrupt_handler _ux_hcd_ohci_interrupt_handler +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_host_controllers/src/ux_hcd_ehci_initialize.c b/common/usbx_host_controllers/src/ux_hcd_ehci_initialize.c index 347bc093..c8cd7073 100644 --- a/common/usbx_host_controllers/src/ux_hcd_ehci_initialize.c +++ b/common/usbx_host_controllers/src/ux_hcd_ehci_initialize.c @@ -30,7 +30,7 @@ #include "ux_host_stack.h" -/* EHCI HCD extention for host mode select. */ +/* EHCI HCD extension for host mode select. */ #ifndef UX_HCD_EHCI_EXT_USB_HOST_MODE_ENABLE #if defined(K66) || defined(IMX6UL) || defined(XILINX_ZYNQ) || defined(MIMXRT) @@ -60,7 +60,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_hcd_ehci_initialize PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -108,6 +108,9 @@ /* optimized based on compile */ /* definitions, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_hcd_ehci_initialize(UX_HCD *hcd) diff --git a/common/usbx_host_controllers/src/ux_hcd_ehci_port_reset.c b/common/usbx_host_controllers/src/ux_hcd_ehci_port_reset.c index 10cdc2ee..bcc281da 100644 --- a/common/usbx_host_controllers/src/ux_hcd_ehci_port_reset.c +++ b/common/usbx_host_controllers/src/ux_hcd_ehci_port_reset.c @@ -30,7 +30,7 @@ #include "ux_host_stack.h" -/* EHCI HCD extention for host mode select. */ +/* EHCI HCD extension for host mode select. */ #ifndef UX_HCD_EHCI_EXT_USBPHY_HIGHSPEED_MODE_SET #if defined(K66) @@ -88,7 +88,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_hcd_ehci_port_reset PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -124,6 +124,9 @@ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* fixed NXP register base, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_hcd_ehci_port_reset(UX_HCD_EHCI *hcd_ehci, ULONG port_index) diff --git a/common/usbx_host_controllers/src/ux_hcd_ehci_port_status_get.c b/common/usbx_host_controllers/src/ux_hcd_ehci_port_status_get.c index 21fb0277..cee1a415 100644 --- a/common/usbx_host_controllers/src/ux_hcd_ehci_port_status_get.c +++ b/common/usbx_host_controllers/src/ux_hcd_ehci_port_status_get.c @@ -30,7 +30,7 @@ #include "ux_host_stack.h" -/* EHCI HCD extention for host mode select. */ +/* EHCI HCD extension for host mode select. */ #ifndef UX_HCD_EHCI_EXT_USBPHY_HIGHSPEED_MODE_SET #if defined(K66) @@ -88,7 +88,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_hcd_ehci_port_status_get PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -147,6 +147,9 @@ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* fixed NXP register base, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ ULONG _ux_hcd_ehci_port_status_get(UX_HCD_EHCI *hcd_ehci, ULONG port_index) diff --git a/common/usbx_host_controllers/src/ux_hcd_ehci_transfer_abort.c b/common/usbx_host_controllers/src/ux_hcd_ehci_transfer_abort.c index aa12ab03..74c280c7 100755 --- a/common/usbx_host_controllers/src/ux_hcd_ehci_transfer_abort.c +++ b/common/usbx_host_controllers/src/ux_hcd_ehci_transfer_abort.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_hcd_ehci_transfer_abort PORTABLE C */ -/* 6.1.2 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -59,7 +59,7 @@ /* _ux_utility_virtual_address Get virtual address */ /* _ux_utility_mutex_on Get mutex */ /* _ux_utility_mutex_off Put mutex */ -/* _ux_utility_delay_ms Delay miliseconds */ +/* _ux_utility_delay_ms Delay milliseconds */ /* _ux_hcd_ehci_ed_clean Clean TDs on ED */ /* */ /* CALLED BY */ @@ -76,6 +76,9 @@ /* 11-09-2020 Chaoqiong Xiao Modified comment(s), */ /* fixed compile warnings, */ /* resulting in version 6.1.2 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_hcd_ehci_transfer_abort(UX_HCD_EHCI *hcd_ehci,UX_TRANSFER *transfer_request) diff --git a/common/usbx_network/inc/ux_network_driver.h b/common/usbx_network/inc/ux_network_driver.h index ddfc5dbf..2efb15b9 100644 --- a/common/usbx_network/inc/ux_network_driver.h +++ b/common/usbx_network/inc/ux_network_driver.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_network_driver.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -43,12 +43,27 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_NETWORK_DRIVER_H #define UX_NETWORK_DRIVER_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 + #include "tx_api.h" #include "nx_api.h" #define USB_NETWORK_DEVICE_MAX_INSTANCES 8 @@ -72,7 +87,7 @@ typedef struct USB_NETWORK_DEVICE_STRUCT /* interface_ptr is populated by NetX, as part of the interface attachment. */ NX_INTERFACE *ux_network_device_interface_ptr; - /* Define synchronization objecs for deactivation. Note that these are only + /* Define synchronization objects for deactivation. Note that these are only used if the activation/deactivation functions are not called under interrupt. */ UCHAR ux_network_device_activated_by_thread; TX_MUTEX ux_network_device_deactivate_mutex; @@ -110,4 +125,10 @@ VOID _ux_network_driver_link_up(VOID *ux_network_handle); VOID _ux_network_driver_link_down(VOID *ux_network_handle); VOID _ux_network_driver_packet_received(VOID *ux_network_handle, NX_PACKET *packet_ptr); +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_network/src/ux_network_driver.c b/common/usbx_network/src/ux_network_driver.c index ce1c9822..c94fd8d3 100644 --- a/common/usbx_network/src/ux_network_driver.c +++ b/common/usbx_network/src/ux_network_driver.c @@ -95,7 +95,7 @@ UINT status = NX_SUCCESS; /* FUNCTION RELEASE */ /* */ /* _ux_network_driver_activate PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -104,7 +104,7 @@ UINT status = NX_SUCCESS; /* */ /* The USB network driver activate function is called as the USB instance */ /* is created. This API takes a pointer to the instance, and returns a */ -/* ux_network_handle back to the instance. Everytime the instance receives*/ +/* ux_network_handle back to instance. Every time the instance receives */ /* a network packet, it should call ux_network_driver_packet_received with*/ /* ux_network_handle. */ /* */ @@ -145,6 +145,9 @@ UINT status = NX_SUCCESS; /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ @@ -245,7 +248,7 @@ UINT i; /* FUNCTION RELEASE */ /* */ /* _ux_network_driver_deactivate PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -254,7 +257,7 @@ UINT i; /* */ /* The USB network driver activate function is called as the USB instance */ /* is created. This API takes a pointer to the instance, and returns a */ -/* ux_network_handle back to the instance. Everytime the instance receives*/ +/* ux_network_handle back to instance. Every time the instance receives */ /* a network packet, it should call ux_network_driver_packet_received with*/ /* ux_network_handle. */ /* */ @@ -295,6 +298,9 @@ UINT i; /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_network_driver_deactivate(VOID *ux_instance, VOID *ux_network_handle) diff --git a/common/usbx_pictbridge/inc/ux_pictbridge.h b/common/usbx_pictbridge/inc/ux_pictbridge.h index 012b0da6..4fef28d9 100644 --- a/common/usbx_pictbridge/inc/ux_pictbridge.h +++ b/common/usbx_pictbridge/inc/ux_pictbridge.h @@ -26,7 +26,7 @@ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_pictbridge.h PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -46,12 +46,26 @@ /* TX symbols instead of using */ /* them directly, */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* added extern "C" keyword */ +/* for compatibility with C++, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ #ifndef UX_PICTBRIDGE_H #define UX_PICTBRIDGE_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 + struct UX_PICTBRIDGE_STRUCT; /* Define the behaviour of this Pictbridge device : DPSHOST or DPSCLIENT. @@ -1038,6 +1052,12 @@ extern UCHAR _ux_pictbridge_xml_tag_line_fileid[]; extern UCHAR _ux_pictbridge_xml_tag_line_filename[]; extern UCHAR _ux_pictbridge_xml_tag_line_date[]; +/* Determine if a C++ compiler is being used. If so, complete the standard + C conditional started above. */ +#ifdef __cplusplus +} +#endif + #endif diff --git a/common/usbx_pictbridge/src/ux_pictbridge_dpsclient_object_delete.c b/common/usbx_pictbridge/src/ux_pictbridge_dpsclient_object_delete.c index 6eba8b9b..6955b1bf 100644 --- a/common/usbx_pictbridge/src/ux_pictbridge_dpsclient_object_delete.c +++ b/common/usbx_pictbridge/src/ux_pictbridge_dpsclient_object_delete.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _ux_pictbridge_dpsclient_object_delete PORTABLE C */ -/* 6.1 */ +/* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ @@ -66,6 +66,9 @@ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ +/* 08-02-2021 Wen Wang Modified comment(s), */ +/* fixed spelling error, */ +/* resulting in version 6.1.8 */ /* */ /**************************************************************************/ UINT _ux_pictbridge_dpsclient_object_delete(UX_SLAVE_CLASS_PIMA *pima, ULONG object_handle) @@ -74,7 +77,7 @@ UINT _ux_pictbridge_dpsclient_object_delete(UX_SLAVE_CLASS_PIMA *pima, ULONG ob UX_PARAMETER_NOT_USED(pima); UX_PARAMETER_NOT_USED(object_handle); - /* This function is not really usefull in PictBridge. */ + /* This function is not really useful in PictBridge. */ return(UX_SUCCESS); }