mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-08-20 21:29:42 +08:00
Merge pull request #2388 from armink/fix_rtdbg
Remove the DBG_COLOR and DBG_ENABLE definition.
This commit is contained in:
@@ -12,10 +12,8 @@
|
||||
|
||||
#include <dfs.h>
|
||||
|
||||
// #define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "DFS"
|
||||
#define DBG_COLOR
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#include <rtdbg.h>
|
||||
|
||||
#define NO_WORKING_DIR "system does not support working directory\n"
|
||||
|
||||
@@ -111,7 +111,7 @@ int dfs_file_open(struct dfs_fd *fd, const char *path, int flags)
|
||||
fd->flags |= DFS_F_DIRECTORY;
|
||||
}
|
||||
|
||||
LOG_I("open successful");
|
||||
LOG_D("open successful");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -15,10 +15,8 @@
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "adc"
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
static rt_size_t _adc_read(rt_device_t dev, rt_off_t pos, void *buffer, rt_size_t size)
|
||||
|
||||
@@ -13,14 +13,12 @@
|
||||
|
||||
#include <drivers/mmcsd_core.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "SDIO"
|
||||
#ifdef RT_SDIO_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif /* RT_SDIO_DEBUG */
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
static rt_list_t blk_devices = RT_LIST_OBJECT_INIT(blk_devices);
|
||||
@@ -369,7 +367,7 @@ rt_int32_t rt_mmcsd_blk_probe(struct rt_mmcsd_card *card)
|
||||
return err;
|
||||
}
|
||||
|
||||
LOG_I("probe mmcsd block device!");
|
||||
LOG_D("probe mmcsd block device!");
|
||||
|
||||
/* get the first sector to read partition table */
|
||||
sector = (rt_uint8_t *)rt_malloc(SECTOR_SIZE);
|
||||
|
||||
@@ -11,14 +11,12 @@
|
||||
#include <drivers/mmcsd_core.h>
|
||||
#include <drivers/mmc.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "SDIO"
|
||||
#ifdef RT_SDIO_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif /* RT_SDIO_DEBUG */
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
static const rt_uint32_t tran_unit[] =
|
||||
|
||||
@@ -14,14 +14,12 @@
|
||||
#include <drivers/mmc.h>
|
||||
#include <drivers/sdio.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "SDIO"
|
||||
#ifdef RT_SDIO_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif /* RT_SDIO_DEBUG */
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#ifndef RT_MMCSD_STACK_SIZE
|
||||
|
||||
@@ -11,14 +11,12 @@
|
||||
#include <drivers/mmcsd_core.h>
|
||||
#include <drivers/sd.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "SDIO"
|
||||
#ifdef RT_SDIO_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif /* RT_SDIO_DEBUG */
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
static const rt_uint32_t tran_unit[] =
|
||||
|
||||
@@ -12,14 +12,12 @@
|
||||
#include <drivers/sdio.h>
|
||||
#include <drivers/sd.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "SDIO"
|
||||
#ifdef RT_SDIO_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif /* RT_SDIO_DEBUG */
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#ifndef RT_SDIO_STACK_SIZE
|
||||
|
||||
@@ -10,10 +10,8 @@
|
||||
|
||||
#include "sensor.h"
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#define DBG_SECTION_NAME "sensor"
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#include <string.h>
|
||||
|
||||
@@ -10,10 +10,8 @@
|
||||
|
||||
#include "sensor.h"
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#define DBG_SECTION_NAME "sensor.cmd"
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
@@ -28,10 +28,8 @@
|
||||
#include <rtthread.h>
|
||||
#include <rtdevice.h>
|
||||
|
||||
// #define DEBUG_ENABLE
|
||||
#define DEBUG_LEVEL DBG_LOG
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#define DBG_SECTION_NAME "UART"
|
||||
#define DEBUG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#ifdef RT_USING_POSIX
|
||||
|
||||
@@ -11,14 +11,12 @@
|
||||
#include <rtthread.h>
|
||||
#include <wlan_cfg.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#ifdef RT_WLAN_CFG_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif
|
||||
#define DBG_SECTION_NAME "WLAN.cfg"
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#define WLAN_CFG_LOCK() (rt_mutex_take(&cfg_mutex, RT_WAITING_FOREVER))
|
||||
|
||||
@@ -13,14 +13,12 @@
|
||||
#include <wlan_dev.h>
|
||||
#include <wlan_prot.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#ifdef RT_WLAN_DEV_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif
|
||||
#define DBG_SECTION_NAME "WLAN.dev"
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#ifndef RT_DEVICE
|
||||
|
||||
@@ -21,14 +21,12 @@
|
||||
#include <dhcp_server.h>
|
||||
#endif
|
||||
|
||||
#define DBG_ENABLE
|
||||
#ifdef RT_WLAN_LWIP_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif
|
||||
#define DBG_SECTION_NAME "WLAN.lwip"
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#ifndef IPADDR_STRLEN_MAX
|
||||
|
||||
@@ -16,14 +16,13 @@
|
||||
#include <wlan_prot.h>
|
||||
#include <wlan_workqueue.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
|
||||
#ifdef RT_WLAN_MGNT_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif
|
||||
#define DBG_SECTION_NAME "WLAN.mgnt"
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#ifndef RT_WLAN_DEVICE
|
||||
|
||||
@@ -13,14 +13,12 @@
|
||||
#include <wlan_dev.h>
|
||||
#include <wlan_prot.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#ifdef RT_WLAN_PROT_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif
|
||||
#define DBG_SECTION_NAME "WLAN.prot"
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#if RT_WLAN_PROT_NAME_LEN < 4
|
||||
|
||||
@@ -13,10 +13,8 @@
|
||||
#include <wlan_workqueue.h>
|
||||
#include <ipc/workqueue.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#define DBG_SECTION_NAME "WLAN.work"
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
struct rt_wlan_work
|
||||
|
||||
@@ -12,9 +12,7 @@
|
||||
#include "dlelf.h"
|
||||
|
||||
#define DBG_SECTION_NAME "DLMD"
|
||||
#define DBG_ENABLE // enable debug macro
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h> // must after of DEBUG_ENABLE or some other options
|
||||
|
||||
rt_err_t dlmodule_load_shared_object(struct rt_dlmodule* module, void *module_ptr)
|
||||
|
||||
@@ -17,9 +17,7 @@
|
||||
#include <dfs_posix.h>
|
||||
|
||||
#define DBG_SECTION_NAME "DLMD"
|
||||
#define DBG_ENABLE // enable debug macro
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h> // must after of DEBUG_ENABLE or some other options
|
||||
|
||||
static struct rt_module_symtab *_rt_module_symtab_begin = RT_NULL;
|
||||
|
||||
@@ -19,9 +19,7 @@
|
||||
|
||||
#include "lwp.h"
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "LWP"
|
||||
#define DBG_COLOR
|
||||
#define DBG_LEVEL DBG_WARNING
|
||||
#include <rtdbg.h>
|
||||
|
||||
|
||||
@@ -11,9 +11,7 @@
|
||||
#include <rtthread.h>
|
||||
#include <lwp.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "LWPMEM"
|
||||
#define DBG_COLOR
|
||||
#define DBG_LEVEL DBG_WARNING
|
||||
#include <rtdbg.h>
|
||||
|
||||
|
||||
@@ -24,9 +24,7 @@
|
||||
#define SYSCALL_NET(f) ((void*)sys_notimpl)
|
||||
#endif
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "LWP_CALL"
|
||||
#define DBG_COLOR
|
||||
#define DBG_LEVEL DBG_WARNING
|
||||
#include <rtdbg.h>
|
||||
|
||||
|
||||
@@ -12,9 +12,6 @@
|
||||
* NOTE: DO NOT include this file on the header file.
|
||||
*/
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_COLOR
|
||||
|
||||
#ifndef LOG_TAG
|
||||
#define DBG_SECTION_NAME "at"
|
||||
#else
|
||||
|
||||
@@ -19,10 +19,8 @@
|
||||
#endif
|
||||
#include <sal.h>
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "SAL_SOC"
|
||||
#define DBG_SECTION_NAME "SAL_SKT"
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#define SOCKET_TABLE_STEP_LEN 4
|
||||
|
||||
@@ -222,12 +222,6 @@ config RT_USING_ULOG
|
||||
select ULOG_OUTPUT_TIME
|
||||
select ULOG_USING_FILTER
|
||||
default n
|
||||
|
||||
config ULOG_SW_VERSION_NUM
|
||||
hex
|
||||
default 0x00101
|
||||
help
|
||||
sfotware module version number
|
||||
endif
|
||||
|
||||
config RT_USING_UTEST
|
||||
|
||||
@@ -47,7 +47,7 @@ extern "C" {
|
||||
#define DBG_INFO LOG_LVL_INFO
|
||||
#define DBG_LOG LOG_LVL_DBG
|
||||
#define dbg_log(level, ...) \
|
||||
if ((level) <= DBG_LEVEL) \
|
||||
if ((level) <= LOG_LVL) \
|
||||
{ \
|
||||
ulog_output(level, LOG_TAG, RT_FALSE, __VA_ARGS__);\
|
||||
}
|
||||
|
||||
@@ -17,17 +17,13 @@
|
||||
|
||||
#undef DBG_SECTION_NAME
|
||||
#undef DBG_LEVEL
|
||||
#undef DBG_COLOR
|
||||
#undef DBG_ENABLE
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "utest"
|
||||
#ifdef UTEST_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#if RT_CONSOLEBUF_SIZE < 256
|
||||
|
||||
@@ -17,17 +17,13 @@
|
||||
|
||||
#undef DBG_SECTION_NAME
|
||||
#undef DBG_LEVEL
|
||||
#undef DBG_COLOR
|
||||
#undef DBG_ENABLE
|
||||
|
||||
#define DBG_ENABLE
|
||||
#define DBG_SECTION_NAME "testcase"
|
||||
#ifdef UTEST_DEBUG
|
||||
#define DBG_LEVEL DBG_LOG
|
||||
#else
|
||||
#define DBG_LEVEL DBG_INFO
|
||||
#endif
|
||||
#define DBG_COLOR
|
||||
#include <rtdbg.h>
|
||||
|
||||
#define UTEST_LOG_ALL (1u)
|
||||
|
||||
Reference in New Issue
Block a user