The Android Open Source Project | e9df6ba | 2012-12-13 14:55:37 -0800 | [diff] [blame] | 1 | /****************************************************************************** |
| 2 | * |
| 3 | * Copyright (C) 2012 Broadcom Corporation |
| 4 | * |
| 5 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | * you may not use this file except in compliance with the License. |
| 7 | * You may obtain a copy of the License at: |
| 8 | * |
| 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | * |
| 11 | * Unless required by applicable law or agreed to in writing, software |
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | * See the License for the specific language governing permissions and |
| 15 | * limitations under the License. |
| 16 | * |
| 17 | ******************************************************************************/ |
| 18 | |
| 19 | /****************************************************************************** |
| 20 | * |
| 21 | * Override the Android logging macro(s) from |
| 22 | * /system/core/include/cutils/log.h. This header must be the first header |
| 23 | * included by a *.cpp file so the original Android macro can be replaced. |
| 24 | * Do not include this header in another header, because that will create |
| 25 | * unnecessary dependency. |
| 26 | * |
| 27 | ******************************************************************************/ |
| 28 | #pragma once |
| 29 | |
Ruchi Kandoi | 6767aec | 2017-09-26 09:46:26 -0700 | [diff] [blame] | 30 | #include <android-base/stringprintf.h> |
| 31 | #include <base/logging.h> |
Evan Chu | a24be4f | 2013-11-13 15:30:16 -0500 | [diff] [blame] | 32 | #include "bt_types.h" |
The Android Open Source Project | e9df6ba | 2012-12-13 14:55:37 -0800 | [diff] [blame] | 33 | |
Ruchi Kandoi | 6767aec | 2017-09-26 09:46:26 -0700 | [diff] [blame] | 34 | using android::base::StringPrintf; |
| 35 | |
| 36 | extern bool nfc_debug_enabled; |
Ruchi Kandoi | 512ee63 | 2017-01-03 13:59:10 -0800 | [diff] [blame] | 37 | extern uint32_t ScrProtocolTraceFlag; |
Love Khanna | d7852c9 | 2017-06-02 19:55:05 +0530 | [diff] [blame] | 38 | /* defined for run time DTA mode selection */ |
| 39 | extern unsigned char appl_dta_mode_flag; |
| 40 | |
| 41 | void initializeGlobalAppDtaMode(); |
The Android Open Source Project | e9df6ba | 2012-12-13 14:55:37 -0800 | [diff] [blame] | 42 | |
The Android Open Source Project | e9df6ba | 2012-12-13 14:55:37 -0800 | [diff] [blame] | 43 | /******************************************************************************* |
| 44 | ** |
| 45 | ** Function: initializeGlobalAppLogLevel |
| 46 | ** |
| 47 | ** Description: Initialize and get global logging level from .conf or |
| 48 | ** Android property nfc.app_log_level. The Android property |
| 49 | ** overrides .conf variable. |
| 50 | ** |
| 51 | ** Returns: Global log level: |
Ruchi Kandoi | 6767aec | 2017-09-26 09:46:26 -0700 | [diff] [blame] | 52 | ** 0 * No trace messages to be generated |
| 53 | ** 1 * Debug messages |
The Android Open Source Project | e9df6ba | 2012-12-13 14:55:37 -0800 | [diff] [blame] | 54 | ** |
| 55 | *******************************************************************************/ |
Ruchi Kandoi | 6fca02d | 2017-01-30 14:28:16 -0800 | [diff] [blame] | 56 | unsigned char initializeGlobalAppLogLevel(); |
| 57 | uint32_t initializeProtocolLogLevel(); |