All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pkshih <pkshih@realtek.com>
To: "davem@davemloft.net" <davem@davemloft.net>,
	"kvalo@kernel.org" <kvalo@kernel.org>,
	"guozhengkui@vivo.com" <guozhengkui@vivo.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
	"pabeni@redhat.com" <pabeni@redhat.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"kuba@kernel.org" <kuba@kernel.org>
Cc: "zhengkui_guo@outlook.com" <zhengkui_guo@outlook.com>
Subject: Re: [PATCH v2] rtlwifi: btcoex: fix if == else warning
Date: Mon, 25 Apr 2022 03:20:29 +0000	[thread overview]
Message-ID: <aac189b6207e76fa1c1551c3424f295ee532547e.camel@realtek.com> (raw)
In-Reply-To: <20220425031725.5808-1-guozhengkui@vivo.com>

On Mon, 2022-04-25 at 11:17 +0800, Guo Zhengkui wrote:
> Fix the following coccicheck warning:
> 
> drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a1ant.c:1604:2-4:
> WARNING: possible condition with no effect (if == else).
> 
> Signed-off-by: Guo Zhengkui <guozhengkui@vivo.com>

Acked-by: Ping-Ke Shih <pkshih@realtek.com>

Thank you

> ---
> v1 -> v2: Modify the comment according to Ping-Ke's suggestion.
> 
>  .../realtek/rtlwifi/btcoexist/halbtc8821a1ant.c  | 16 ++++------------
>  1 file changed, 4 insertions(+), 12 deletions(-)
> 
> diff --git a/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a1ant.c
> b/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a1ant.c
> index a18dffc8753a..67d0b9aee064 100644
> --- a/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a1ant.c
> +++ b/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a1ant.c
> @@ -1600,18 +1600,10 @@ static void btc8821a1ant_act_wifi_con_bt_acl_busy(struct btc_coexist
> *btcoexist,
>  			coex_dm->auto_tdma_adjust = false;
>  		}
>  	} else if (bt_link_info->hid_exist && bt_link_info->a2dp_exist) {
> -		/* HID+A2DP */
> -		if ((bt_rssi_state == BTC_RSSI_STATE_HIGH) ||
> -		    (bt_rssi_state == BTC_RSSI_STATE_STAY_HIGH)) {
> -			btc8821a1ant_ps_tdma(btcoexist, NORMAL_EXEC,
> -					     true, 14);
> -			coex_dm->auto_tdma_adjust = false;
> -		} else {
> -			/*for low BT RSSI*/
> -			btc8821a1ant_ps_tdma(btcoexist, NORMAL_EXEC,
> -					     true, 14);
> -			coex_dm->auto_tdma_adjust = false;
> -		}
> +		/* HID+A2DP (no need to consider BT RSSI) */
> +		btc8821a1ant_ps_tdma(btcoexist, NORMAL_EXEC,
> +				     true, 14);
> +		coex_dm->auto_tdma_adjust = false;
>  
>  		btc8821a1ant_coex_table_with_type(btcoexist, NORMAL_EXEC, 1);
>  	} else if ((bt_link_info->pan_only) ||



  reply	other threads:[~2022-04-25  3:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-24  7:55 [PATCH] rtlwifi: btcoex: fix if == else warning Guo Zhengkui
2022-04-25  0:04 ` Pkshih
2022-04-25  3:17   ` [PATCH v2] " Guo Zhengkui
2022-04-25  3:20     ` Pkshih [this message]
2022-04-27  5:04     ` Kalle Valo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aac189b6207e76fa1c1551c3424f295ee532547e.camel@realtek.com \
    --to=pkshih@realtek.com \
    --cc=davem@davemloft.net \
    --cc=guozhengkui@vivo.com \
    --cc=kuba@kernel.org \
    --cc=kvalo@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=zhengkui_guo@outlook.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.