Skip to content

Commit

Permalink
Fixed standalone device HID issue and enable all tests by default. (#129
Browse files Browse the repository at this point in the history
)

* Fixed device hid receiver save position issue.
* Enable all tests by default.
  • Loading branch information
xiaocq2001 authored Dec 1, 2023
1 parent 6ed7092 commit f856e41
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/regression_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
tests_to_run:
description: 'all, single or multiple of default_build_coverage error_check_build_full_coverage tracex_enable_build device_buffer_owner_build device_zero_copy_build nofx_build_coverage optimized_build standalone_device_build_coverage standalone_device_buffer_owner_build standalone_device_zero_copy_build standalone_host_build_coverage standalone_build_coverage generic_build otg_support_build memory_management_build_coverage msrc_rtos_build msrc_standalone_build'
required: false
default: 'default_build_coverage'
default: 'all'
skip_coverage:
required: false
type: boolean
Expand Down Expand Up @@ -55,7 +55,7 @@ jobs:
uses: azure-rtos/threadx/.github/workflows/regression_template.yml@master
with:
cmake_path: ./test/cmake/usbx
build_script: ./scripts/build.sh default_build_coverage
test_script: ./scripts/test.sh default_build_coverage
build_script: ./scripts/build.sh all
test_script: ./scripts/test.sh all
coverage_name: default_build_coverage
skip_coverage: false
Original file line number Diff line number Diff line change
Expand Up @@ -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 */
Expand Down Expand Up @@ -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)
Expand Down Expand Up @@ -165,14 +168,16 @@ 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. */
temp = transfer -> ux_slave_transfer_request_actual_length;
#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,
Expand Down

0 comments on commit f856e41

Please sign in to comment.