5 * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
7 * Contact: Jeesun Kim <iamjs.kim@samsung.com>
9 * Licensed under the Apache License, Version 2.0 (the "License");
10 * you may not use this file except in compliance with the License.
11 * You may obtain a copy of the License at
13 * http://www.apache.org/licenses/LICENSE-2.0
15 * Unless required by applicable law or agreed to in writing, software
16 * distributed under the License is distributed on an "AS IS" BASIS,
17 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 * See the License for the specific language governing permissions and
19 * limitations under the License.
23 #ifndef __LOCKUPINFO_UTIL_LOG_H__
24 #define __LOCKUPINFO_UTIL_LOG_H__
30 #define LOG_TAG "LOCKUPINFO"
31 #define _E(fmt, arg...) fprintf(stderr, "[%s,%d] "fmt,__FUNCTION__,__LINE__,##arg)
32 #define _D(fmt, arg...) fprintf(stderr, "[%s,%d] "fmt,__FUNCTION__,__LINE__,##arg)
33 //#define _E(fmt, arg...) LOGE("[%s,%d] "fmt,__FUNCTION__,__LINE__,##arg)
34 //#define _D(fmt, arg...) LOGD("[%s,%d] "fmt,__FUNCTION__,__LINE__,##arg)
36 #define retvm_if(expr, val, fmt, arg...) do { \
39 _E("(%s) -> %s() return", #expr, __FUNCTION__); \
44 #define retv_if(expr, val) do { \
46 _E("(%s) -> %s() return", #expr, __FUNCTION__); \
51 #define retm_if(expr, fmt, arg...) do { \
54 _E("(%s) -> %s() return", #expr, __FUNCTION__); \
59 #define ret_if(expr) do { \
61 _E("(%s) -> %s() return", #expr, __FUNCTION__); \
67 #endif /* __LOCKUPINFO_UTIL_LOG_H__ */