• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2021 Bestechnic (Shanghai) Co., Ltd. All rights reserved.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 #include "hal_trace_mod.h"
16 #include "plat_types.h"
17 
18 #undef _TR_MODULE_DEF_A
19 #define _TR_MODULE_DEF_A(p, m)              # m
20 
21 static const char * mod_desc[] = {
22     _TR_MODULE_LIST
23 };
24 
hal_trace_get_log_module_desc(enum TR_MODULE_T module)25 const char *hal_trace_get_log_module_desc(enum TR_MODULE_T module)
26 {
27     if (module < ARRAY_SIZE(mod_desc)) {
28         return mod_desc[module];
29     }
30     return NULL;
31 }
32 
33