summaryrefslogtreecommitdiff
path: root/components/drivers
diff options
context:
space:
mode:
authorarmink <[email protected]>2019-04-12 10:18:57 +0800
committerarmink <[email protected]>2019-04-12 10:18:57 +0800
commitfa4d4ab7cf774ccb701d01a6fd1371ce8d9474e9 (patch)
tree89cb48115a065516808cc8b0d6402b9924e06c4c /components/drivers
parent35bb75b96bb793e12b267cf987a2bf47f34d6510 (diff)
Update all of debug log definition to DBG_TAG and DBG_LVL.
Diffstat (limited to 'components/drivers')
-rw-r--r--components/drivers/misc/adc.c4
-rw-r--r--components/drivers/sdio/block_dev.c6
-rw-r--r--components/drivers/sdio/mmc.c6
-rw-r--r--components/drivers/sdio/mmcsd_core.c6
-rw-r--r--components/drivers/sdio/sd.c6
-rw-r--r--components/drivers/sdio/sdio.c6
-rw-r--r--components/drivers/sensors/sensor.c4
-rw-r--r--components/drivers/sensors/sensor_cmd.c4
-rw-r--r--components/drivers/serial/serial.c4
-rw-r--r--components/drivers/wlan/wlan_cfg.c8
-rw-r--r--components/drivers/wlan/wlan_dev.c8
-rw-r--r--components/drivers/wlan/wlan_lwip.c8
-rw-r--r--components/drivers/wlan/wlan_mgnt.c9
-rw-r--r--components/drivers/wlan/wlan_prot.c8
-rw-r--r--components/drivers/wlan/wlan_workqueue.c4
15 files changed, 45 insertions, 46 deletions
diff --git a/components/drivers/misc/adc.c b/components/drivers/misc/adc.c
index fec4f736e0..2d26beb243 100644
--- a/components/drivers/misc/adc.c
+++ b/components/drivers/misc/adc.c
@@ -15,8 +15,8 @@
#include <string.h>
#include <stdlib.h>
-#define DBG_SECTION_NAME "adc"
-#define DBG_LEVEL DBG_INFO
+#define DBG_TAG "adc"
+#define DBG_LVL DBG_INFO
#include <rtdbg.h>
static rt_size_t _adc_read(rt_device_t dev, rt_off_t pos, void *buffer, rt_size_t size)
diff --git a/components/drivers/sdio/block_dev.c b/components/drivers/sdio/block_dev.c
index dcfbc0ca7b..cac4fc5036 100644
--- a/components/drivers/sdio/block_dev.c
+++ b/components/drivers/sdio/block_dev.c
@@ -13,11 +13,11 @@
#include <drivers/mmcsd_core.h>
-#define DBG_SECTION_NAME "SDIO"
+#define DBG_TAG "SDIO"
#ifdef RT_SDIO_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
+#define DBG_LVL DBG_INFO
#endif /* RT_SDIO_DEBUG */
#include <rtdbg.h>
diff --git a/components/drivers/sdio/mmc.c b/components/drivers/sdio/mmc.c
index 5f9259ef52..5c7ddcb258 100644
--- a/components/drivers/sdio/mmc.c
+++ b/components/drivers/sdio/mmc.c
@@ -11,11 +11,11 @@
#include <drivers/mmcsd_core.h>
#include <drivers/mmc.h>
-#define DBG_SECTION_NAME "SDIO"
+#define DBG_TAG "SDIO"
#ifdef RT_SDIO_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
+#define DBG_LVL DBG_INFO
#endif /* RT_SDIO_DEBUG */
#include <rtdbg.h>
diff --git a/components/drivers/sdio/mmcsd_core.c b/components/drivers/sdio/mmcsd_core.c
index 160defa645..8131a33133 100644
--- a/components/drivers/sdio/mmcsd_core.c
+++ b/components/drivers/sdio/mmcsd_core.c
@@ -14,11 +14,11 @@
#include <drivers/mmc.h>
#include <drivers/sdio.h>
-#define DBG_SECTION_NAME "SDIO"
+#define DBG_TAG "SDIO"
#ifdef RT_SDIO_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
+#define DBG_LVL DBG_INFO
#endif /* RT_SDIO_DEBUG */
#include <rtdbg.h>
diff --git a/components/drivers/sdio/sd.c b/components/drivers/sdio/sd.c
index f4e925507c..3e7ad1cd16 100644
--- a/components/drivers/sdio/sd.c
+++ b/components/drivers/sdio/sd.c
@@ -11,11 +11,11 @@
#include <drivers/mmcsd_core.h>
#include <drivers/sd.h>
-#define DBG_SECTION_NAME "SDIO"
+#define DBG_TAG "SDIO"
#ifdef RT_SDIO_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
+#define DBG_LVL DBG_INFO
#endif /* RT_SDIO_DEBUG */
#include <rtdbg.h>
diff --git a/components/drivers/sdio/sdio.c b/components/drivers/sdio/sdio.c
index b0516704fd..f31f5b81a8 100644
--- a/components/drivers/sdio/sdio.c
+++ b/components/drivers/sdio/sdio.c
@@ -12,11 +12,11 @@
#include <drivers/sdio.h>
#include <drivers/sd.h>
-#define DBG_SECTION_NAME "SDIO"
+#define DBG_TAG "SDIO"
#ifdef RT_SDIO_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
+#define DBG_LVL DBG_INFO
#endif /* RT_SDIO_DEBUG */
#include <rtdbg.h>
diff --git a/components/drivers/sensors/sensor.c b/components/drivers/sensors/sensor.c
index ec1ad98fb6..c86f96c14d 100644
--- a/components/drivers/sensors/sensor.c
+++ b/components/drivers/sensors/sensor.c
@@ -10,8 +10,8 @@
#include "sensor.h"
-#define DBG_LEVEL DBG_INFO
-#define DBG_SECTION_NAME "sensor"
+#define DBG_TAG "sensor"
+#define DBG_LVL DBG_INFO
#include <rtdbg.h>
#include <string.h>
diff --git a/components/drivers/sensors/sensor_cmd.c b/components/drivers/sensors/sensor_cmd.c
index 4658a42722..3369ee376a 100644
--- a/components/drivers/sensors/sensor_cmd.c
+++ b/components/drivers/sensors/sensor_cmd.c
@@ -10,8 +10,8 @@
#include "sensor.h"
-#define DBG_LEVEL DBG_INFO
-#define DBG_SECTION_NAME "sensor.cmd"
+#define DBG_TAG "sensor.cmd"
+#define DBG_LVL DBG_INFO
#include <rtdbg.h>
#include <stdlib.h>
diff --git a/components/drivers/serial/serial.c b/components/drivers/serial/serial.c
index 13bf54e721..d4cf35414c 100644
--- a/components/drivers/serial/serial.c
+++ b/components/drivers/serial/serial.c
@@ -28,8 +28,8 @@
#include <rtthread.h>
#include <rtdevice.h>
-#define DBG_LEVEL DBG_INFO
-#define DBG_SECTION_NAME "UART"
+#define DBG_TAG "UART"
+#define DBG_LVL DBG_INFO
#include <rtdbg.h>
#ifdef RT_USING_POSIX
diff --git a/components/drivers/wlan/wlan_cfg.c b/components/drivers/wlan/wlan_cfg.c
index 00e9dbc83e..43fed8e6e8 100644
--- a/components/drivers/wlan/wlan_cfg.c
+++ b/components/drivers/wlan/wlan_cfg.c
@@ -11,12 +11,12 @@
#include <rtthread.h>
#include <wlan_cfg.h>
+#define DBG_TAG "WLAN.cfg"
#ifdef RT_WLAN_CFG_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
-#endif
-#define DBG_SECTION_NAME "WLAN.cfg"
+#define DBG_LVL DBG_INFO
+#endif /* RT_WLAN_CFG_DEBUG */
#include <rtdbg.h>
#define WLAN_CFG_LOCK() (rt_mutex_take(&cfg_mutex, RT_WAITING_FOREVER))
diff --git a/components/drivers/wlan/wlan_dev.c b/components/drivers/wlan/wlan_dev.c
index 3f4adf35ad..82fa4e73e7 100644
--- a/components/drivers/wlan/wlan_dev.c
+++ b/components/drivers/wlan/wlan_dev.c
@@ -13,12 +13,12 @@
#include <wlan_dev.h>
#include <wlan_prot.h>
+#define DBG_TAG "WLAN.dev"
#ifdef RT_WLAN_DEV_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
-#endif
-#define DBG_SECTION_NAME "WLAN.dev"
+#define DBG_LVL DBG_INFO
+#endif /* RT_WLAN_DEV_DEBUG */
#include <rtdbg.h>
#ifndef RT_DEVICE
diff --git a/components/drivers/wlan/wlan_lwip.c b/components/drivers/wlan/wlan_lwip.c
index 052c2afd2e..84b448c68f 100644
--- a/components/drivers/wlan/wlan_lwip.c
+++ b/components/drivers/wlan/wlan_lwip.c
@@ -21,12 +21,12 @@
#include <dhcp_server.h>
#endif
+#define DBG_TAG "WLAN.lwip"
#ifdef RT_WLAN_LWIP_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
-#endif
-#define DBG_SECTION_NAME "WLAN.lwip"
+#define DBG_LVL DBG_INFO
+#endif /* RT_WLAN_LWIP_DEBUG */
#include <rtdbg.h>
#ifndef IPADDR_STRLEN_MAX
diff --git a/components/drivers/wlan/wlan_mgnt.c b/components/drivers/wlan/wlan_mgnt.c
index ced5bfa1c2..91a77e43d0 100644
--- a/components/drivers/wlan/wlan_mgnt.c
+++ b/components/drivers/wlan/wlan_mgnt.c
@@ -16,13 +16,12 @@
#include <wlan_prot.h>
#include <wlan_workqueue.h>
-
+#define DBG_TAG "WLAN.mgnt"
#ifdef RT_WLAN_MGNT_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
-#endif
-#define DBG_SECTION_NAME "WLAN.mgnt"
+#define DBG_LVL DBG_INFO
+#endif /* RT_WLAN_MGNT_DEBUG */
#include <rtdbg.h>
#ifndef RT_WLAN_DEVICE
diff --git a/components/drivers/wlan/wlan_prot.c b/components/drivers/wlan/wlan_prot.c
index 48adbc48f3..0402962e01 100644
--- a/components/drivers/wlan/wlan_prot.c
+++ b/components/drivers/wlan/wlan_prot.c
@@ -13,12 +13,12 @@
#include <wlan_dev.h>
#include <wlan_prot.h>
+#define DBG_TAG "WLAN.prot"
#ifdef RT_WLAN_PROT_DEBUG
-#define DBG_LEVEL DBG_LOG
+#define DBG_LVL DBG_LOG
#else
-#define DBG_LEVEL DBG_INFO
-#endif
-#define DBG_SECTION_NAME "WLAN.prot"
+#define DBG_LVL DBG_INFO
+#endif /* RT_WLAN_PROT_DEBUG */
#include <rtdbg.h>
#if RT_WLAN_PROT_NAME_LEN < 4
diff --git a/components/drivers/wlan/wlan_workqueue.c b/components/drivers/wlan/wlan_workqueue.c
index 23823afae0..ec21243d60 100644
--- a/components/drivers/wlan/wlan_workqueue.c
+++ b/components/drivers/wlan/wlan_workqueue.c
@@ -13,8 +13,8 @@
#include <wlan_workqueue.h>
#include <ipc/workqueue.h>
-#define DBG_LEVEL DBG_INFO
-#define DBG_SECTION_NAME "WLAN.work"
+#define DBG_TAG "WLAN.work"
+#define DBG_LVL DBG_INFO
#include <rtdbg.h>
struct rt_wlan_work