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 /** ThreadX Component */
17 /** */
18 /** Module */
19 /** */
20 /**************************************************************************/
21 /**************************************************************************/
22
23 #define TXM_MODULE
24 #include "txm_module.h"
25 #ifndef TXM_TIMER_PERFORMANCE_INFO_GET_CALL_NOT_USED
26 /**************************************************************************/
27 /* */
28 /* FUNCTION RELEASE */
29 /* */
30 /* _tx_timer_performance_info_get PORTABLE C */
31 /* 6.1.10 */
32 /* AUTHOR */
33 /* */
34 /* Scott Larson, Microsoft Corporation */
35 /* */
36 /* DESCRIPTION */
37 /* */
38 /* This function retrieves performance information from the specified */
39 /* timer. */
40 /* */
41 /* INPUT */
42 /* */
43 /* timer_ptr Pointer to timer control block */
44 /* activates Destination for the number of */
45 /* activations of this timer */
46 /* reactivates Destination for the number of */
47 /* reactivations of this timer */
48 /* deactivates Destination for the number of */
49 /* deactivations of this timer */
50 /* expirations Destination for the number of */
51 /* expirations of this timer */
52 /* expiration_adjusts Destination for the number of */
53 /* expiration adjustments of this */
54 /* timer */
55 /* */
56 /* OUTPUT */
57 /* */
58 /* status Completion status */
59 /* */
60 /* CALLS */
61 /* */
62 /* _txm_module_kernel_call_dispatcher */
63 /* */
64 /* CALLED BY */
65 /* */
66 /* Module application code */
67 /* */
68 /* RELEASE HISTORY */
69 /* */
70 /* DATE NAME DESCRIPTION */
71 /* */
72 /* 09-30-2020 Scott Larson Initial Version 6.1 */
73 /* 01-31-2022 Scott Larson Modified comments and added */
74 /* CALL_NOT_USED option, */
75 /* resulting in version 6.1.10 */
76 /* */
77 /**************************************************************************/
_tx_timer_performance_info_get(TX_TIMER * timer_ptr,ULONG * activates,ULONG * reactivates,ULONG * deactivates,ULONG * expirations,ULONG * expiration_adjusts)78 UINT _tx_timer_performance_info_get(TX_TIMER *timer_ptr, ULONG *activates, ULONG *reactivates, ULONG *deactivates, ULONG *expirations, ULONG *expiration_adjusts)
79 {
80
81 UINT return_value;
82 ALIGN_TYPE extra_parameters[4];
83
84 extra_parameters[0] = (ALIGN_TYPE) reactivates;
85 extra_parameters[1] = (ALIGN_TYPE) deactivates;
86 extra_parameters[2] = (ALIGN_TYPE) expirations;
87 extra_parameters[3] = (ALIGN_TYPE) expiration_adjusts;
88
89 /* Call module manager dispatcher. */
90 return_value = (UINT) (_txm_module_kernel_call_dispatcher)(TXM_TIMER_PERFORMANCE_INFO_GET_CALL, (ALIGN_TYPE) timer_ptr, (ALIGN_TYPE) activates, (ALIGN_TYPE) extra_parameters);
91
92 /* Return value to the caller. */
93 return(return_value);
94 }
95 #endif
96