1 /*
2  * Copyright (c) 2023 Huawei Device Co., Ltd.
3  *
4  * HDF is dual licensed: you can use it either under the terms of
5  * the GPL, or the BSD license, at your option.
6  * See the LICENSE file in the root of this repository for complete details.
7  */
8 
9 #ifndef CLOCK_TEST_H
10 #define CLOCK_TEST_H
11 
12 #include "clock_if.h"
13 
14 #ifdef __cplusplus
15 #if __cplusplus
16 extern "C" {
17 #endif
18 #endif /* __cplusplus */
19 
20 struct ClockTestConfig {
21     uint32_t deviceIndex;
22 };
23 
24 struct ClockTester {
25     struct ClockTestConfig config;
26     DevHandle handle;
27 };
28 
29 enum ClockTestCmd {
30     CLOCK_TEST_CMD_ENABLE = 0,
31     CLOCK_TEST_CMD_DISABLE,
32     CLOCK_TEST_CMD_SET_RATE,
33     CLOCK_TEST_CMD_GET_RATE,
34     CLOCK_TEST_CMD_GET_PARENT,
35     CLOCK_TEST_CMD_SET_PARENT,
36     CLOCK_TEST_CMD_MULTI_THREAD,
37     CLOCK_TEST_CMD_RELIABILITY,
38     CLOCK_IF_PERFORMANCE_TEST,
39     CLOCK_TEST_CMD_MAX,
40 };
41 
42 int32_t ClockTestExecute(int cmd);
43 
44 #ifdef __cplusplus
45 #if __cplusplus
46 }
47 #endif
48 #endif /* __cplusplus */
49 
50 #endif /* CLOCK_TEST_H */
51