1 /**************************************************************************/ 2 /* */ 3 /* Copyright (c) Microsoft Corporation. All rights reserved. */ 4 /* */ 5 /* This software is licensed under the Microsoft Software License */ 6 /* Terms for Microsoft Azure RTOS. Full text of the license can be */ 7 /* found in the LICENSE file at https://aka.ms/AzureRTOS_EULA */ 8 /* and in the root directory of this software. */ 9 /* */ 10 /**************************************************************************/ 11 12 13 /**************************************************************************/ 14 /**************************************************************************/ 15 /** */ 16 /** USBX Component */ 17 /** */ 18 /** System */ 19 /** */ 20 /**************************************************************************/ 21 /**************************************************************************/ 22 23 /* Include necessary system files. */ 24 25 #define UX_SOURCE_CODE 26 27 #include "ux_api.h" 28 #include "ux_system.h" 29 #include "ux_host_stack.h" 30 #include "ux_device_stack.h" 31 32 33 #if defined(UX_STANDALONE) || defined(UX_HOST_STANDALONE) || defined(UX_DEVICE_STANDALONE) || defined(UX_OTG_STANDALONE) 34 /**************************************************************************/ 35 /* */ 36 /* FUNCTION RELEASE */ 37 /* */ 38 /* _ux_system_tasks_run PORTABLE C */ 39 /* 6.1.10 */ 40 /* AUTHOR */ 41 /* */ 42 /* Chaoqiong Xiao, Microsoft Corporation */ 43 /* */ 44 /* DESCRIPTION */ 45 /* */ 46 /* This function runs USB system tasks, including possible tasks for */ 47 /* host, device and OTG. */ 48 /* */ 49 /* It's for standalone mode. */ 50 /* */ 51 /* INPUT */ 52 /* */ 53 /* None */ 54 /* */ 55 /* OUTPUT */ 56 /* */ 57 /* None */ 58 /* */ 59 /* CALLS */ 60 /* */ 61 /* _ux_device_stack_tasks_run Run device tasks */ 62 /* _ux_host_stack_tasks_run Run host tasks */ 63 /* */ 64 /* CALLED BY */ 65 /* */ 66 /* Application */ 67 /* */ 68 /* RELEASE HISTORY */ 69 /* */ 70 /* DATE NAME DESCRIPTION */ 71 /* */ 72 /* 01-31-2022 Chaoqiong Xiao Initial Version 6.1.10 */ 73 /* */ 74 /**************************************************************************/ _ux_system_tasks_run(VOID)75UINT _ux_system_tasks_run(VOID) 76 { 77 #if defined(UX_DEVICE_STANDALONE) && !defined(UX_HOST_SIDE_ONLY) 78 _ux_device_stack_tasks_run(); 79 #endif 80 #if defined(UX_HOST_STANDALONE) && !defined(UX_DEVICE_SIDE_ONLY) 81 _ux_host_stack_tasks_run(); 82 #endif 83 #if defined(UX_OTG_STANDALONE) && defined(UX_OTG_SUPPORT) 84 _ux_otg_tasks_run(); 85 #endif 86 87 /* Return code not used now. */ 88 return(0); 89 } 90 #endif 91