staging: wilc1000: align defines
Align some defines in linux_wlan_common.h Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
c3ea8a7200
commit
3f4d1c09ae
@ -32,11 +32,7 @@ enum debug_region {
|
|||||||
#define RX_DBG (1 << RX_debug)
|
#define RX_DBG (1 << RX_debug)
|
||||||
#define LOCK_DBG (1 << Lock_debug)
|
#define LOCK_DBG (1 << Lock_debug)
|
||||||
#define TCP_ENH (1 << Tcp_enhance)
|
#define TCP_ENH (1 << Tcp_enhance)
|
||||||
|
|
||||||
|
|
||||||
/*Added by Amr - BugID_4720*/
|
|
||||||
#define SPIN_DEBUG (1 << Spin_debug)
|
#define SPIN_DEBUG (1 << Spin_debug)
|
||||||
|
|
||||||
#define INIT_DBG (1 << Init_debug)
|
#define INIT_DBG (1 << Init_debug)
|
||||||
#define BUS_DBG (1 << Bus_debug)
|
#define BUS_DBG (1 << Bus_debug)
|
||||||
#define MEM_DBG (1 << Mem_debug)
|
#define MEM_DBG (1 << Mem_debug)
|
||||||
@ -54,33 +50,40 @@ extern atomic_t DEBUG_LEVEL;
|
|||||||
#define WRN (1 << 2)
|
#define WRN (1 << 2)
|
||||||
#define ERR (1 << 3)
|
#define ERR (1 << 3)
|
||||||
|
|
||||||
#define PRINT_D(region, ...) do { \
|
#define PRINT_D(region, ...) \
|
||||||
if ((atomic_read(&DEBUG_LEVEL) & DEBUG) && ((atomic_read(®ION)) & (region))) { \
|
do { \
|
||||||
|
if ((atomic_read(&DEBUG_LEVEL) & DEBUG) && \
|
||||||
|
((atomic_read(®ION)) & (region))) { \
|
||||||
printk("DBG [%s: %d]", __FUNCTION__, __LINE__); \
|
printk("DBG [%s: %d]", __FUNCTION__, __LINE__); \
|
||||||
printk(__VA_ARGS__); \
|
printk(__VA_ARGS__); \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define PRINT_INFO(region, ...) do { \
|
#define PRINT_INFO(region, ...) \
|
||||||
if ((atomic_read(&DEBUG_LEVEL) & INFO) && ((atomic_read(®ION)) & (region))) { \
|
do { \
|
||||||
|
if ((atomic_read(&DEBUG_LEVEL) & INFO) && \
|
||||||
|
((atomic_read(®ION)) & (region))) { \
|
||||||
printk("INFO [%s]", __FUNCTION__); \
|
printk("INFO [%s]", __FUNCTION__); \
|
||||||
printk(__VA_ARGS__); \
|
printk(__VA_ARGS__); \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define PRINT_WRN(region, ...) do { \
|
#define PRINT_WRN(region, ...) \
|
||||||
if ((atomic_read(&DEBUG_LEVEL) & WRN) && ((atomic_read(®ION)) & (region))) { \
|
do { \
|
||||||
|
if ((atomic_read(&DEBUG_LEVEL) & WRN) && \
|
||||||
|
((atomic_read(®ION)) & (region))) { \
|
||||||
printk("WRN [%s: %d]", __FUNCTION__, __LINE__); \
|
printk("WRN [%s: %d]", __FUNCTION__, __LINE__); \
|
||||||
printk(__VA_ARGS__); \
|
printk(__VA_ARGS__); \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define PRINT_ER(...) do { \
|
#define PRINT_ER(...) \
|
||||||
|
do { \
|
||||||
if ((atomic_read(&DEBUG_LEVEL) & ERR)) { \
|
if ((atomic_read(&DEBUG_LEVEL) & ERR)) { \
|
||||||
printk("ERR [%s: %d]", __FUNCTION__, __LINE__); \
|
printk("ERR [%s: %d]", __FUNCTION__, __LINE__); \
|
||||||
printk(__VA_ARGS__); \
|
printk(__VA_ARGS__); \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
@ -89,25 +92,34 @@ extern atomic_t DEBUG_LEVEL;
|
|||||||
#define DEBUG 1
|
#define DEBUG 1
|
||||||
#define INFO 0
|
#define INFO 0
|
||||||
#define WRN 0
|
#define WRN 0
|
||||||
#define PRINT_D(region, ...) do { if (DEBUG == 1 && ((REGION)&(region))) { \
|
|
||||||
|
#define PRINT_D(region, ...) \
|
||||||
|
do { \
|
||||||
|
if (DEBUG == 1 && ((REGION)&(region))) { \
|
||||||
printk("DBG [%s: %d]", __FUNCTION__, __LINE__); \
|
printk("DBG [%s: %d]", __FUNCTION__, __LINE__); \
|
||||||
printk(__VA_ARGS__); \
|
printk(__VA_ARGS__); \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define PRINT_INFO(region, ...) do { if (INFO == 1 && ((REGION)&(region))) { \
|
#define PRINT_INFO(region, ...) \
|
||||||
|
do { \
|
||||||
|
if (INFO == 1 && ((REGION)&(region))) { \
|
||||||
printk("INFO [%s]", __FUNCTION__); \
|
printk("INFO [%s]", __FUNCTION__); \
|
||||||
printk(__VA_ARGS__); \
|
printk(__VA_ARGS__); \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define PRINT_WRN(region, ...) do { if (WRN == 1 && ((REGION)&(region))) { \
|
#define PRINT_WRN(region, ...) \
|
||||||
|
do { \
|
||||||
|
if (WRN == 1 && ((REGION)&(region))) { \
|
||||||
printk("WRN [%s: %d]", __FUNCTION__, __LINE__); \
|
printk("WRN [%s: %d]", __FUNCTION__, __LINE__); \
|
||||||
printk(__VA_ARGS__); \
|
printk(__VA_ARGS__); \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define PRINT_ER(...) do { printk("ERR [%s: %d]", __FUNCTION__, __LINE__); \
|
#define PRINT_ER(...) \
|
||||||
|
do { \
|
||||||
|
printk("ERR [%s: %d]", __FUNCTION__, __LINE__); \
|
||||||
printk(__VA_ARGS__); \
|
printk(__VA_ARGS__); \
|
||||||
} while (0)
|
} while (0)
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user