mirror of
https://github.com/azure-rtos/usbx.git
synced 2025-01-28 07:03:07 +08:00
Fixed device hid receiver save position issue.
This commit is contained in:
parent
6ed7092b77
commit
44ab01fd5f
@ -35,7 +35,7 @@
|
||||
/* FUNCTION RELEASE */
|
||||
/* */
|
||||
/* _ux_device_class_hid_receiver_tasks_run PORTABLE C */
|
||||
/* 6.3.0 */
|
||||
/* 6.x */
|
||||
/* AUTHOR */
|
||||
/* */
|
||||
/* Chaoqiong Xiao, Microsoft Corporation */
|
||||
@ -70,6 +70,9 @@
|
||||
/* 10-31-2023 Chaoqiong Xiao Modified comment(s), */
|
||||
/* added zero copy support, */
|
||||
/* resulting in version 6.3.0 */
|
||||
/* xx-xx-xxxx Chaoqiong Xiao Modified comment(s), */
|
||||
/* fixed save position issue, */
|
||||
/* resulting in version 6.x */
|
||||
/* */
|
||||
/**************************************************************************/
|
||||
UINT _ux_device_class_hid_receiver_tasks_run(UX_SLAVE_CLASS_HID *hid)
|
||||
@ -165,6 +168,9 @@ ULONG temp;
|
||||
return(UX_STATE_NEXT);
|
||||
}
|
||||
|
||||
/* Get current save position. */
|
||||
pos = receiver -> ux_device_class_hid_receiver_event_save_pos;
|
||||
|
||||
#if (UX_DEVICE_ENDPOINT_BUFFER_OWNER == 1) && defined(UX_DEVICE_CLASS_HID_ZERO_COPY)
|
||||
|
||||
/* Save received event length. */
|
||||
@ -172,7 +178,6 @@ ULONG temp;
|
||||
#else
|
||||
|
||||
/* Save received event data and length. */
|
||||
pos = receiver -> ux_device_class_hid_receiver_event_save_pos;
|
||||
buffer = (UCHAR *)&pos -> ux_device_class_hid_received_event_data;
|
||||
temp = transfer -> ux_slave_transfer_request_actual_length;
|
||||
_ux_utility_memory_copy(buffer,
|
||||
|
Loading…
x
Reference in New Issue
Block a user