1
0

qcacmn: Selectively reduce the dbr logs

Reduce loglevel of some logs from info to debug.

Change-Id: Id4cc241b48defeb5abb122a8c50ef4e81fff9760
CRs-Fixed: 2607982
Este cometimento está contido em:
Arun Kumar Khandavalli
2020-01-20 12:25:05 +05:30
cometido por nshrivas
ascendente d3ebfc2db6
cometimento 7c3ce2d05f
2 ficheiros modificados com 48 adições e 47 eliminações

Ver ficheiro

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017-2019 The Linux Foundation. All rights reserved.
* Copyright (c) 2017-2020 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@@ -168,7 +168,7 @@ QDF_STATUS direct_buf_rx_deinit(void)
if (QDF_IS_STATUS_ERROR(status))
direct_buf_rx_err("Failed to unregister psoc create handler");
direct_buf_rx_info("Direct Buffer RX pdev,psoc create and destroy handlers unregistered");
direct_buf_rx_debug("Direct Buffer RX pdev,psoc create and destroy handlers unregistered");
return status;
}
@@ -187,7 +187,7 @@ QDF_STATUS direct_buf_rx_target_attach(struct wlan_objmgr_psoc *psoc,
dbr_psoc_obj = wlan_objmgr_psoc_get_comp_private_obj(psoc,
WLAN_TARGET_IF_COMP_DIRECT_BUF_RX);
direct_buf_rx_info("Dbr psoc obj %pK", dbr_psoc_obj);
direct_buf_rx_debug("Dbr psoc obj %pK", dbr_psoc_obj);
if (!dbr_psoc_obj) {
direct_buf_rx_err("dir buf rx psoc obj is null");

Ver ficheiro

@@ -402,9 +402,9 @@ QDF_STATUS target_if_direct_buf_rx_pdev_create_handler(
dbr_pdev_obj;
num_modules = get_num_dbr_modules_per_pdev(pdev);
direct_buf_rx_info("Number of modules = %d pdev %d DBR pdev obj %pK",
num_modules, wlan_objmgr_pdev_get_pdev_id(pdev),
dbr_pdev_obj);
direct_buf_rx_debug("Number of modules = %d pdev %d DBR pdev obj %pK",
num_modules, wlan_objmgr_pdev_get_pdev_id(pdev),
dbr_pdev_obj);
dbr_pdev_obj->num_modules = num_modules;
if (!dbr_pdev_obj->num_modules) {
@@ -412,7 +412,7 @@ QDF_STATUS target_if_direct_buf_rx_pdev_create_handler(
return QDF_STATUS_SUCCESS;
}
direct_buf_rx_info("sring number = %d", DBR_SRNG_NUM);
direct_buf_rx_debug("sring number = %d", DBR_SRNG_NUM);
dbr_pdev_obj->dbr_mod_param = qdf_mem_malloc(num_modules *
DBR_SRNG_NUM *
sizeof(struct direct_buf_rx_module_param));
@@ -512,7 +512,7 @@ QDF_STATUS target_if_direct_buf_rx_psoc_create_handler(
if (!dbr_psoc_obj)
return QDF_STATUS_E_NOMEM;
direct_buf_rx_info("Dbr psoc obj %pK", dbr_psoc_obj);
direct_buf_rx_debug("Dbr psoc obj %pK", dbr_psoc_obj);
status = wlan_objmgr_psoc_component_obj_attach(psoc,
WLAN_TARGET_IF_COMP_DIRECT_BUF_RX, dbr_psoc_obj,
@@ -1158,8 +1158,8 @@ static QDF_STATUS target_if_dbr_init_ring(struct wlan_objmgr_pdev *pdev,
DIR_BUF_RX_DMA_SRC);
entry_size = hal_srng_get_entrysize(dbr_psoc_obj->hal_soc,
DIR_BUF_RX_DMA_SRC);
direct_buf_rx_info("Max Entries = %d", max_entries);
direct_buf_rx_info("Entry Size = %d", entry_size);
direct_buf_rx_debug("Max Entries = %d", max_entries);
direct_buf_rx_debug("Entry Size = %d", entry_size);
status = populate_dbr_cap_mod_param(pdev, mod_param);
if (QDF_IS_STATUS_ERROR(status)) {
@@ -1171,7 +1171,7 @@ static QDF_STATUS target_if_dbr_init_ring(struct wlan_objmgr_pdev *pdev,
dbr_ring_cfg = mod_param->dbr_ring_cfg;
num_entries = dbr_ring_cap->ring_elems_min > max_entries ?
max_entries : dbr_ring_cap->ring_elems_min;
direct_buf_rx_info("Num entries = %d", num_entries);
direct_buf_rx_debug("Num entries = %d", num_entries);
dbr_ring_cfg->num_ptr = num_entries;
mod_param->dbr_buf_pool = qdf_mem_malloc(num_entries * sizeof(
struct direct_buf_rx_buf_info));
@@ -1180,11 +1180,11 @@ static QDF_STATUS target_if_dbr_init_ring(struct wlan_objmgr_pdev *pdev,
ring_alloc_size = (num_entries * entry_size) + DBR_RING_BASE_ALIGN - 1;
dbr_ring_cfg->ring_alloc_size = ring_alloc_size;
direct_buf_rx_info("dbr_psoc_obj %pK", dbr_psoc_obj);
direct_buf_rx_debug("dbr_psoc_obj %pK", dbr_psoc_obj);
dbr_ring_cfg->base_vaddr_unaligned = qdf_mem_alloc_consistent(
dbr_psoc_obj->osdev, dbr_psoc_obj->osdev->dev, ring_alloc_size,
&paddr);
direct_buf_rx_info("vaddr aligned allocated");
direct_buf_rx_debug("vaddr aligned allocated");
dbr_ring_cfg->base_paddr_unaligned = paddr;
if (!dbr_ring_cfg->base_vaddr_unaligned) {
direct_buf_rx_err("dir buf rx vaddr alloc failed");
@@ -1232,7 +1232,7 @@ static QDF_STATUS target_if_dbr_init_srng(struct wlan_objmgr_pdev *pdev,
{
QDF_STATUS status;
direct_buf_rx_info("Init DBR srng");
direct_buf_rx_debug("Init DBR srng");
if (!mod_param) {
direct_buf_rx_err("dir buf rx module param is null");
@@ -1314,20 +1314,21 @@ static QDF_STATUS target_if_dbr_cfg_tgt(struct wlan_objmgr_pdev *pdev,
dbr_cfg_req.buf_size = dbr_ring_cap->min_buf_size;
dbr_cfg_req.num_resp_per_event = dbr_config->num_resp_per_event;
dbr_cfg_req.event_timeout_ms = dbr_config->event_timeout_in_ms;
direct_buf_rx_info("pdev id %d mod id %d base addr lo %x\n"
"base addr hi %x head idx addr lo %x\n"
"head idx addr hi %x tail idx addr lo %x\n"
"tail idx addr hi %x num ptr %d\n"
"num resp %d event timeout %d\n",
dbr_cfg_req.pdev_id, dbr_cfg_req.mod_id,
dbr_cfg_req.base_paddr_lo, dbr_cfg_req.base_paddr_hi,
dbr_cfg_req.head_idx_paddr_lo,
dbr_cfg_req.head_idx_paddr_hi,
dbr_cfg_req.tail_idx_paddr_lo,
dbr_cfg_req.tail_idx_paddr_hi,
dbr_cfg_req.num_elems,
dbr_cfg_req.num_resp_per_event,
dbr_cfg_req.event_timeout_ms);
direct_buf_rx_debug("pdev id %d mod id %d base addr lo %x\n"
"base addr hi %x head idx addr lo %x\n"
"head idx addr hi %x tail idx addr lo %x\n"
"tail idx addr hi %x num ptr %d\n"
"num resp %d event timeout %d\n",
dbr_cfg_req.pdev_id, dbr_cfg_req.mod_id,
dbr_cfg_req.base_paddr_lo,
dbr_cfg_req.base_paddr_hi,
dbr_cfg_req.head_idx_paddr_lo,
dbr_cfg_req.head_idx_paddr_hi,
dbr_cfg_req.tail_idx_paddr_lo,
dbr_cfg_req.tail_idx_paddr_hi,
dbr_cfg_req.num_elems,
dbr_cfg_req.num_resp_per_event,
dbr_cfg_req.event_timeout_ms);
status = wmi_unified_dbr_ring_cfg(wmi_hdl, &dbr_cfg_req);
return status;
@@ -1340,8 +1341,8 @@ static QDF_STATUS target_if_init_dbr_ring(struct wlan_objmgr_pdev *pdev,
QDF_STATUS status = QDF_STATUS_SUCCESS;
struct direct_buf_rx_module_param *mod_param;
direct_buf_rx_info("Init DBR ring for module %d, srng %d",
mod_id, srng_id);
direct_buf_rx_debug("Init DBR ring for module %d, srng %d",
mod_id, srng_id);
if (!dbr_pdev_obj) {
direct_buf_rx_err("dir buf rx object is null");
@@ -1355,7 +1356,7 @@ static QDF_STATUS target_if_init_dbr_ring(struct wlan_objmgr_pdev *pdev,
return QDF_STATUS_E_FAILURE;
}
direct_buf_rx_info("mod_param %pK", mod_param);
direct_buf_rx_debug("mod_param %pK", mod_param);
mod_param->mod_id = mod_id;
mod_param->pdev_id = dbr_get_pdev_id(
@@ -1419,7 +1420,7 @@ QDF_STATUS target_if_direct_buf_rx_module_register(
return QDF_STATUS_E_FAILURE;
}
direct_buf_rx_info("Dbr pdev obj %pK", dbr_pdev_obj);
direct_buf_rx_debug("Dbr pdev obj %pK", dbr_pdev_obj);
if (!dbr_pdev_obj->dbr_mod_param) {
direct_buf_rx_err("dbr_pdev_obj->dbr_mod_param is NULL");
@@ -1474,7 +1475,7 @@ QDF_STATUS target_if_direct_buf_rx_module_unregister(
return QDF_STATUS_E_FAILURE;
}
direct_buf_rx_info("Dbr pdev obj %pK", dbr_pdev_obj);
direct_buf_rx_debug("Dbr pdev obj %pK", dbr_pdev_obj);
if (!dbr_pdev_obj->dbr_mod_param) {
direct_buf_rx_err("dbr_pdev_obj->dbr_mod_param is NULL");
@@ -1508,7 +1509,7 @@ static void *target_if_dbr_vaddr_lookup(
dbr_buf_pool[cookie].offset;
}
direct_buf_rx_err("Incorrect paddr found on cookie slot");
direct_buf_rx_debug("Incorrect paddr found on cookie slot");
return NULL;
}
@@ -1653,8 +1654,8 @@ dbr_get_pdev_and_srng_id(struct wlan_objmgr_psoc *psoc, uint8_t pdev_id,
pdev = wlan_objmgr_get_pdev_by_id(psoc, TGT_WMI_PDEV_ID_SOC,
dbr_mod_id);
if (pdev) {
direct_buf_rx_info("update srng id from %d to %d",
*srng_id, pdev_id);
direct_buf_rx_debug("update srng id from %d to %d",
*srng_id, pdev_id);
*srng_id = pdev_id;
}
}
@@ -1946,7 +1947,7 @@ static QDF_STATUS target_if_dbr_deinit_ring(struct wlan_objmgr_pdev *pdev,
direct_buf_rx_err("dir buf rx psoc object is null");
return QDF_STATUS_E_FAILURE;
}
direct_buf_rx_info("dbr_psoc_obj %pK", dbr_psoc_obj);
direct_buf_rx_debug("dbr_psoc_obj %pK", dbr_psoc_obj);
dbr_ring_cfg = mod_param->dbr_ring_cfg;
if (dbr_ring_cfg) {
@@ -1970,7 +1971,7 @@ static QDF_STATUS target_if_dbr_deinit_srng(
direct_buf_rx_enter();
dbr_buf_pool = mod_param->dbr_buf_pool;
direct_buf_rx_info("dbr buf pool %pK", dbr_buf_pool);
direct_buf_rx_debug("dbr buf pool %pK", dbr_buf_pool);
target_if_dbr_deinit_ring(pdev, mod_param);
if (mod_param->dbr_buf_pool)
qdf_mem_free(dbr_buf_pool);
@@ -2022,7 +2023,7 @@ QDF_STATUS target_if_direct_buf_rx_register_events(
WMI_RX_UMAC_CTX);
if (ret)
direct_buf_rx_info("event handler not supported, ret=%d", ret);
direct_buf_rx_debug("event handler not supported, ret=%d", ret);
return QDF_STATUS_SUCCESS;
}
@@ -2067,9 +2068,9 @@ QDF_STATUS target_if_direct_buf_rx_print_ring_stat(
WLAN_TARGET_IF_COMP_DIRECT_BUF_RX);
hal_soc = dbr_psoc_obj->hal_soc;
num_modules = dbr_pdev_obj->num_modules;
direct_buf_rx_err("--------------------------------------------------");
direct_buf_rx_err("| Module ID | Module | Head Idx | Tail Idx |");
direct_buf_rx_err("--------------------------------------------------");
direct_buf_rx_debug("--------------------------------------------------");
direct_buf_rx_debug("| Module ID | Module | Head Idx | Tail Idx |");
direct_buf_rx_debug("--------------------------------------------------");
for (mod_idx = 0; mod_idx < num_modules; mod_idx++) {
for (srng_id = 0; srng_id < DBR_SRNG_NUM; srng_id++) {
mod_param =
@@ -2077,13 +2078,13 @@ QDF_STATUS target_if_direct_buf_rx_print_ring_stat(
dbr_ring_cfg = mod_param->dbr_ring_cfg;
srng = dbr_ring_cfg->srng;
hal_get_sw_hptp(hal_soc, srng, &tp, &hp);
direct_buf_rx_err("|%11d|%14s|%10x|%10x|",
mod_idx, g_dbr_module_name[mod_idx].
module_name_str,
hp, tp);
direct_buf_rx_debug("|%11d|%14s|%10x|%10x|",
mod_idx, g_dbr_module_name[mod_idx].
module_name_str,
hp, tp);
}
}
direct_buf_rx_err("--------------------------------------------------");
direct_buf_rx_debug("--------------------------------------------------");
return QDF_STATUS_SUCCESS;
}