From: Ivan Grokhotkov Date: Wed, 31 Jan 2018 06:01:07 +0000 (+0800) Subject: tcpip_adapter: make log output at debug level less noisy X-Git-Tag: v3.1-beta1~406^2~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b3be1b5190ac97ae377e33adac77964eb4c6dc73;p=esp-idf tcpip_adapter: make log output at debug level less noisy At debug log level, tcpip_adapter would print logs for each function call scheduled onto the tcpip task. These logs contained pointers which idf_monitor decoded, adding even more noise and useless vertical space in logs. This change moves these log statements to verbose level. --- diff --git a/components/tcpip_adapter/include/tcpip_adapter.h b/components/tcpip_adapter/include/tcpip_adapter.h index ab095c87ae..4777f16057 100644 --- a/components/tcpip_adapter/include/tcpip_adapter.h +++ b/components/tcpip_adapter/include/tcpip_adapter.h @@ -184,10 +184,10 @@ typedef struct tcpip_adapter_dns_param_s { msg.data = (void*)(_data);\ msg.api_fn = (_fn);\ if (TCPIP_ADAPTER_IPC_REMOTE == tcpip_adapter_ipc_check(&msg)) {\ - ESP_LOGD(TAG, "check: remote, if=%d fn=%p\n", (_if), (_fn));\ + ESP_LOGV(TAG, "check: remote, if=%d fn=%p\n", (_if), (_fn));\ return msg.ret;\ } else {\ - ESP_LOGD(TAG, "check: local, if=%d fn=%p\n", (_if), (_fn));\ + ESP_LOGV(TAG, "check: local, if=%d fn=%p\n", (_if), (_fn));\ }\ }while(0) diff --git a/components/tcpip_adapter/tcpip_adapter_lwip.c b/components/tcpip_adapter/tcpip_adapter_lwip.c index ca57338526..313e9b1d58 100644 --- a/components/tcpip_adapter/tcpip_adapter_lwip.c +++ b/components/tcpip_adapter/tcpip_adapter_lwip.c @@ -67,7 +67,7 @@ static sys_sem_t api_sync_sem = NULL; static bool tcpip_inited = false; static sys_sem_t api_lock_sem = NULL; extern sys_thread_t g_lwip_task; -#define TAG "tcpip_adapter" +static const char* TAG = "tcpip_adapter"; static void tcpip_adapter_api_cb(void* api_msg) { @@ -79,7 +79,7 @@ static void tcpip_adapter_api_cb(void* api_msg) } msg->ret = msg->api_fn(msg); - ESP_LOGD(TAG, "call api in lwip: ret=0x%x, give sem", msg->ret); + ESP_LOGV(TAG, "call api in lwip: ret=0x%x, give sem", msg->ret); sys_sem_signal(&api_sync_sem); return;