diff options
| author | Yuxin Zhou <[email protected]> | 2021-07-28 07:25:46 +0000 |
|---|---|---|
| committer | Yuxin Zhou <[email protected]> | 2021-07-28 07:25:46 +0000 |
| commit | 3574b6bc518553adefe70d82db907ae801786d6f (patch) | |
| tree | eadc713a8c532d2519bff2b6da93d31c8a98995b /common/usbx_host_classes/src | |
| parent | 756899739082fd013048ae6a39dab556fddc8a11 (diff) | |
Release 6.1.8v6.1.8_rel
Diffstat (limited to 'common/usbx_host_classes/src')
6 files changed, 51 insertions, 27 deletions
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 f21e96a..a7e3da0 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 d42ff5d..b5b4938 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 65bfaae..f97ccc7 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 e3798a9..799dfee 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 86b3281..0e35ebc 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 372f9f3..e628c6f 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. */ |
