1 /*
2 * Copyright (c) 2020 Huawei Device Co., Ltd.
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
16 #include "ohos_init.h"
17 #include "hiview_config.h"
18
19 HiviewConfig g_hiviewConfig = {
20 .outputOption = OUTPUT_OPTION,
21 .level = OUTPUT_LEVEL, /* Control log output level. HILOG_LV_XXX, default is HILOG_LV_DEBUG */
22 .logSwitch = HILOG_LITE_SWITCH,
23 .dumpSwitch = DUMP_LITE_SWITCH,
24 .eventSwitch = HIEVENT_LITE_SWITCH,
25 .logOutputModule = 0,
26 .writeFailureCount = 0,
27 };
28
HiviewConfigInit(void)29 static void HiviewConfigInit(void)
30 {
31 g_hiviewConfig.hiviewInited = FALSE;
32 g_hiviewConfig.logOutputModule = (uint64_t)LOG_OUTPUT_MODULE;
33 g_hiviewConfig.writeFailureCount = 0;
34 }
35 CORE_INIT_PRI(HiviewConfigInit, 0);
36