Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp1442729pxf; Fri, 2 Apr 2021 10:33:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyITeMm5hZkEtBvEIu0991dpFGjwVaHWnquIRZv/5rzyQ8/oyAvWCY+0cJqus0CTJ49y9rf X-Received: by 2002:a17:907:2bd9:: with SMTP id gv25mr1174684ejc.225.1617384803509; Fri, 02 Apr 2021 10:33:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617384803; cv=none; d=google.com; s=arc-20160816; b=Zn1fQcsVno4rAI1I3WqyHqpYLZqeQ/D4yje/wr2g2vE70rEJAnPsZ2USkjpeDbexht PJbT6niXIl6tVGwflpww1SV9NVsPdaFmKakxHOJWs1ldpFrOz9B4SHMzDnzMQC5DxUP+ v6Q3WKL9KmIk9lHriY73Yvt7c/mIIiNIwAFTF/N1McoTWWj0fdxIniwHifPCWH6Uo7Vw Bu8xh5mev2ICyFLsVtE0mGFxYTKP1OF7/qOGbnVxmzhkPB2+F/ZzkanrdIZHFQv9a0uT oOGw0Ypzn0uJQdC36p1HqeUwZABA9UqWeayFKT70jMcLdBIyySDtYEvCu590KwxZpoug ebFg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=EjDhroCmccT+2xNhEjbohPeuUdj7bnQTqKMqJeKrwKo=; b=J4C+px3EM8H0WYJAE5F7W0D+M12r6KUTjUNCOM1gqnRD+y42Wuwezu4T2R0uyITQwk QT66kHxcSiV32W/1Eyg6NMYSCl7dyfe6664q4IPPRonqzK9V8iB2PJHJs0LfIfs2XVFx LO8fqAMR0XF3ytVOWo22Jik41/IsmiDnGPV8JJTh47XSCD0dzC9Y5Dm3oVfvCHZRdcH1 MG20r1bAZZRLraKCxVw3UJi4rPwt9dyfU8NtrTKxlJMYGiJiUjvKrr2x3fyZEj/GzEZL 2Zbu9zzsPt02xd2TefVHt3eVcdJdmKkgDvhx0D2K/5/j4C0kbIZVhoaF/eiCdzDAQf/G UC0A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=My3pKvL3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bc2si6835008edb.263.2021.04.02.10.33.00; Fri, 02 Apr 2021 10:33:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=My3pKvL3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235767AbhDBRa5 (ORCPT + 99 others); Fri, 2 Apr 2021 13:30:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57142 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235421AbhDBRai (ORCPT ); Fri, 2 Apr 2021 13:30:38 -0400 Received: from mail-wr1-x42f.google.com (mail-wr1-x42f.google.com [IPv6:2a00:1450:4864:20::42f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 479CFC061788 for ; Fri, 2 Apr 2021 10:30:36 -0700 (PDT) Received: by mail-wr1-x42f.google.com with SMTP id v4so5273014wrp.13 for ; Fri, 02 Apr 2021 10:30:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=EjDhroCmccT+2xNhEjbohPeuUdj7bnQTqKMqJeKrwKo=; b=My3pKvL326k5Ea3HsOapHyllYXcsdzq0HZ/OTZzELo7EHKN7hLiofEsGDKtvEghrrY MXK84LKqJsf5I8GZZwLg2OAH/KY7w496XAGU4vNjjPltXfOP7b/HaFca0cjSPNJIw8Bk 8NlZLFlxFWRJIvTacnqLbUeYImt4PmI8qPshBPbG2lX41uOToo1OpYCaHNbk0I2noYtN eeK0pmlHY+UsllQNqplK9FMxiYwKMpMkqWKyq6xivL+sboeQabXkzew11PsjY1In+HEf 9oZkftMtlqCKgU8vRwnx1QEv36x4tiCLF9e8rmBHVb2AS+2Awe2kE/7UpdQ2lk8F2UEW RaWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=EjDhroCmccT+2xNhEjbohPeuUdj7bnQTqKMqJeKrwKo=; b=iPD8MFbifrBZsWVBBlaQg5PjR1w40lmwCxXG11Mzii+pOay0oyGq6p06h1A5pcbmKY nNJ3PIuIKO5pKdDj9jA5Qg0TgcKjBdlGV7F5gKebzdDB40091+V8V0x4klrB+trg3vNL U5wMaCwAu+BqnjBufSdAzdPe5ggr+SxdS71yYY97r7mtO/SJK1e/7rRlKYrPV+XQjgZy Qeic3X/F8/qrkTcFgwDUeIssvJELtRRPWXnyuDr6k+yLfCvZcpBtt9SZFI3baMe0Trjk zbwre0eEpG84AUZbReJ5KLsNVtv7xvju7DWqVOoUPg/kmmUo7W1jnrhtG2XQTa8k9Wwa 0l7w== X-Gm-Message-State: AOAM530EzMg3QHedPGluK7QD102GelTyiaon1AbH6YIR0JC7TmZQmAVc LV8oOU+UrVqtuJQZ+ZjaK/A= X-Received: by 2002:a5d:49c7:: with SMTP id t7mr16345831wrs.306.1617384635045; Fri, 02 Apr 2021 10:30:35 -0700 (PDT) Received: from agape ([5.171.81.4]) by smtp.gmail.com with ESMTPSA id c9sm13446725wml.42.2021.04.02.10.30.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Apr 2021 10:30:34 -0700 (PDT) From: Fabio Aiuto To: gregkh@linuxfoundation.org Cc: dan.carpenter@oracle.com, joe@perches.com, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, Fabio Aiuto Subject: [PATCH v2 11/30] staging: rtl8723bs: remove RT_TRACE logs in core/rtw_cmd.c Date: Fri, 2 Apr 2021 19:29:53 +0200 Message-Id: <1df8807df77b12245772f3e8c21f602522eb3e1f.1617384172.git.fabioaiuto83@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org remove all RT_TRACE logs removed a variable, left unused after RT_TRACE removal Signed-off-by: Fabio Aiuto --- drivers/staging/rtl8723bs/core/rtw_cmd.c | 53 +++--------------------- 1 file changed, 6 insertions(+), 47 deletions(-) diff --git a/drivers/staging/rtl8723bs/core/rtw_cmd.c b/drivers/staging/rtl8723bs/core/rtw_cmd.c index 2aaf25b48f96..2086df056c44 100644 --- a/drivers/staging/rtl8723bs/core/rtw_cmd.c +++ b/drivers/staging/rtl8723bs/core/rtw_cmd.c @@ -221,8 +221,6 @@ int rtw_init_evt_priv(struct evt_priv *pevtpriv) void _rtw_free_evt_priv(struct evt_priv *pevtpriv) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, ("+_rtw_free_evt_priv\n")); - _cancel_workitem_sync(&pevtpriv->c2h_wk); while (pevtpriv->c2h_wk_alive) msleep(10); @@ -233,8 +231,6 @@ void _rtw_free_evt_priv(struct evt_priv *pevtpriv) kfree(c2h); } kfree(pevtpriv->c2h_queue); - - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, ("-_rtw_free_evt_priv\n")); } void _rtw_free_cmd_priv(struct cmd_priv *pcmdpriv) @@ -299,13 +295,11 @@ struct cmd_obj *_rtw_dequeue_cmd(struct __queue *queue) void rtw_free_evt_priv(struct evt_priv *pevtpriv) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, ("rtw_free_evt_priv\n")); _rtw_free_evt_priv(pevtpriv); } void rtw_free_cmd_priv(struct cmd_priv *pcmdpriv) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, ("rtw_free_cmd_priv\n")); _rtw_free_cmd_priv(pcmdpriv); } @@ -415,8 +409,6 @@ int rtw_cmd_thread(void *context) atomic_set(&(pcmdpriv->cmdthd_running), true); complete(&pcmdpriv->terminate_cmdthread_comp); - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, ("start r871x rtw_cmd_thread !!!!\n")); - while (1) { if (wait_for_completion_interruptible(&pcmdpriv->cmd_queue_comp)) { DBG_871X_LEVEL(_drv_always_, FUNC_ADPT_FMT" wait_for_completion_interruptible(&pcmdpriv->cmd_queue_comp) return != 0, break\n", FUNC_ADPT_ARG(padapter)); @@ -439,11 +431,8 @@ int rtw_cmd_thread(void *context) continue; } - if (rtw_register_cmd_alive(padapter) != _SUCCESS) { - RT_TRACE(_module_hal_xmit_c_, _drv_notice_, - ("%s: wait to leave LPS_LCLK\n", __func__)); + if (rtw_register_cmd_alive(padapter) != _SUCCESS) continue; - } _next: if ((padapter->bDriverStopped == true) || (padapter->bSurpriseRemoved == true)) { @@ -512,14 +501,12 @@ int rtw_cmd_thread(void *context) if (pcmd->cmdcode < ARRAY_SIZE(rtw_cmd_callback)) { pcmd_callback = rtw_cmd_callback[pcmd->cmdcode].callback; if (pcmd_callback == NULL) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, ("mlme_cmd_hdl(): pcmd_callback = 0x%p, cmdcode = 0x%x\n", pcmd_callback, pcmd->cmdcode)); rtw_free_cmd_obj(pcmd); } else { /* todo: !!! fill rsp_buf to pcmd->rsp if (pcmd->rsp!= NULL) */ pcmd_callback(pcmd->padapter, pcmd);/* need consider that free cmd_obj in rtw_cmd_callback */ } } else { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("%s: cmdcode = 0x%x callback not defined!\n", __func__, pcmd->cmdcode)); rtw_free_cmd_obj(pcmd); } @@ -583,8 +570,6 @@ u8 rtw_sitesurvey_cmd(struct adapter *padapter, struct ndis_802_11_ssid *ssid, rtw_free_network_queue(padapter, false); - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, ("%s: flush network queue\n", __func__)); - init_h2fwcmd_w_parm_no_rsp(ph2c, psurveyPara, GEN_CMD_CODE(_SiteSurvey)); /* psurveyPara->bsslimit = 48; */ @@ -672,15 +657,9 @@ u8 rtw_createbss_cmd(struct adapter *padapter) { struct cmd_obj *pcmd; struct cmd_priv *pcmdpriv = &padapter->cmdpriv; - struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct wlan_bssid_ex *pdev_network = &padapter->registrypriv.dev_network; u8 res = _SUCCESS; - if (pmlmepriv->assoc_ssid.SsidLength == 0) - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, (" createbss for Any SSid:%s\n", pmlmepriv->assoc_ssid.Ssid)); - else - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, (" createbss for SSid:%s\n", pmlmepriv->assoc_ssid.Ssid)); - pcmd = rtw_zmalloc(sizeof(struct cmd_obj)); if (pcmd == NULL) { res = _FAIL; @@ -766,15 +745,9 @@ u8 rtw_joinbss_cmd(struct adapter *padapter, struct wlan_network *pnetwork) u32 tmp_len; u8 *ptmp = NULL; - if (pmlmepriv->assoc_ssid.SsidLength == 0) - RT_TRACE(_module_rtl871x_cmd_c_, _drv_info_, ("+Join cmd: Any SSid\n")); - else - RT_TRACE(_module_rtl871x_cmd_c_, _drv_notice_, ("+Join cmd: SSid =[%s]\n", pmlmepriv->assoc_ssid.Ssid)); - pcmd = rtw_zmalloc(sizeof(struct cmd_obj)); if (pcmd == NULL) { res = _FAIL; - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("rtw_joinbss_cmd: memory allocate for cmd_obj fail!!!\n")); goto exit; } /* for IEs is fix buf size */ @@ -883,8 +856,6 @@ u8 rtw_disassoc_cmd(struct adapter *padapter, u32 deauth_timeout_ms, bool enqueu struct cmd_priv *cmdpriv = &padapter->cmdpriv; u8 res = _SUCCESS; - RT_TRACE(_module_rtl871x_cmd_c_, _drv_notice_, ("+rtw_disassoc_cmd\n")); - /* prepare cmd parameter */ param = rtw_zmalloc(sizeof(*param)); if (param == NULL) { @@ -1209,8 +1180,6 @@ u8 rtw_set_chplan_cmd(struct adapter *padapter, u8 chplan, u8 enqueue, u8 swconf u8 res = _SUCCESS; - RT_TRACE(_module_rtl871x_cmd_c_, _drv_notice_, ("+rtw_set_chplan_cmd\n")); - /* check if allow software config */ if (swconfig && rtw_hal_is_disable_sw_channel_plan(padapter) == true) { res = _FAIL; @@ -1981,7 +1950,6 @@ void rtw_survey_cmd_callback(struct adapter *padapter, struct cmd_obj *pcmd) _set_timer(&pmlmepriv->scan_to_timer, 1); } else if (pcmd->res != H2C_SUCCESS) { _set_timer(&pmlmepriv->scan_to_timer, 1); - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("\n ********Error: MgntActrtw_set_802_11_bssid_LIST_SCAN Fail ************\n\n.")); } /* free cmd */ @@ -1997,7 +1965,6 @@ void rtw_disassoc_cmd_callback(struct adapter *padapter, struct cmd_obj *pcmd) set_fwstate(pmlmepriv, _FW_LINKED); spin_unlock_bh(&pmlmepriv->lock); - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("\n ***Error: disconnect_cmd_callback Fail ***\n.")); return; } /* free cmd */ @@ -2030,10 +1997,8 @@ void rtw_createbss_cmd_callback(struct adapter *padapter, struct cmd_obj *pcmd) if (pcmd->parmbuf == NULL) goto exit; - if ((pcmd->res != H2C_SUCCESS)) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("\n ********Error: rtw_createbss_cmd_callback Fail ************\n\n.")); + if ((pcmd->res != H2C_SUCCESS)) _set_timer(&pmlmepriv->assoc_timer, 1); - } del_timer_sync(&pmlmepriv->assoc_timer); @@ -2044,10 +2009,8 @@ void rtw_createbss_cmd_callback(struct adapter *padapter, struct cmd_obj *pcmd) psta = rtw_get_stainfo(&padapter->stapriv, pnetwork->MacAddress); if (!psta) { psta = rtw_alloc_stainfo(&padapter->stapriv, pnetwork->MacAddress); - if (psta == NULL) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("\nCan't alloc sta_info when createbss_cmd_callback\n")); + if (psta == NULL) goto createbss_cmd_fail; - } } rtw_indicate_connect(padapter); @@ -2057,7 +2020,6 @@ void rtw_createbss_cmd_callback(struct adapter *padapter, struct cmd_obj *pcmd) if (pwlan == NULL) { pwlan = rtw_get_oldest_wlan_network(&pmlmepriv->scanned_queue); if (pwlan == NULL) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("\n Error: can't get pwlan in rtw_joinbss_event_callback\n")); spin_unlock_bh(&(pmlmepriv->scanned_queue.lock)); goto createbss_cmd_fail; } @@ -2101,10 +2063,9 @@ void rtw_setstaKey_cmdrsp_callback(struct adapter *padapter, struct cmd_obj *pc struct set_stakey_rsp *psetstakey_rsp = (struct set_stakey_rsp *) (pcmd->rsp); struct sta_info *psta = rtw_get_stainfo(pstapriv, psetstakey_rsp->addr); - if (psta == NULL) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("\nERROR: rtw_setstaKey_cmdrsp_callback => can't get sta_info\n\n")); + if (psta == NULL) goto exit; - } + exit: rtw_free_cmd_obj(pcmd); } @@ -2117,10 +2078,8 @@ void rtw_setassocsta_cmdrsp_callback(struct adapter *padapter, struct cmd_obj * struct set_assocsta_rsp *passocsta_rsp = (struct set_assocsta_rsp *) (pcmd->rsp); struct sta_info *psta = rtw_get_stainfo(pstapriv, passocsta_parm->addr); - if (psta == NULL) { - RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("\nERROR: setassocsta_cmdrsp_callbac => can't get sta_info\n\n")); + if (psta == NULL) goto exit; - } psta->aid = passocsta_rsp->cam_id; psta->mac_id = passocsta_rsp->cam_id; -- 2.20.1