All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ping-Ke Shih <pkshih@realtek.com>
To: Dmitry Antipov <dmantipov@yandex.ru>
Cc: Kalle Valo <kvalo@kernel.org>,
	"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Subject: RE: [PATCH] wifi: rtlwifi: use convenient list_count_nodes()
Date: Wed, 11 Oct 2023 01:24:21 +0000	[thread overview]
Message-ID: <cbbd8f38e9ef4e3dba415952cf466ee8@realtek.com> (raw)
In-Reply-To: <20231010130353.30461-1-dmantipov@yandex.ru>



> -----Original Message-----
> From: Dmitry Antipov <dmantipov@yandex.ru>
> Sent: Tuesday, October 10, 2023 9:04 PM
> To: Ping-Ke Shih <pkshih@realtek.com>
> Cc: Kalle Valo <kvalo@kernel.org>; linux-wireless@vger.kernel.org; Dmitry Antipov <dmantipov@yandex.ru>
> Subject: [PATCH] wifi: rtlwifi: use convenient list_count_nodes()
> 
> Simplify 'rtl92ee_dm_common_info_self_update()',
> 'rtl8723be_dm_common_info_self_update()', and
> 'rtl8821ae_dm_common_info_self_update()' by using
> 'list_count_nodes()'. Compile tested only.
> 
> Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru>
> ---
>  drivers/net/wireless/realtek/rtlwifi/rtl8192ee/dm.c | 5 +----
>  drivers/net/wireless/realtek/rtlwifi/rtl8723be/dm.c | 5 +----
>  drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c | 4 +---
>  3 files changed, 3 insertions(+), 11 deletions(-)
> 
> diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192ee/dm.c
> b/drivers/net/wireless/realtek/rtlwifi/rtl8192ee/dm.c
> index 997ff115b9ab..efd22b75c05f 100644
> --- a/drivers/net/wireless/realtek/rtlwifi/rtl8192ee/dm.c
> +++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192ee/dm.c
> @@ -936,7 +936,6 @@ void rtl92ee_dm_init(struct ieee80211_hw *hw)
>  static void rtl92ee_dm_common_info_self_update(struct ieee80211_hw *hw)
>  {
>         struct rtl_priv *rtlpriv = rtl_priv(hw);
> -       struct rtl_sta_info *drv_priv;
>         u8 cnt = 0;

After 'cnt = list_count_nodes(...)', this initializer is not necessary.
As well as other two cases. 



  reply	other threads:[~2023-10-11  1:24 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-10 13:03 [PATCH] wifi: rtlwifi: use convenient list_count_nodes() Dmitry Antipov
2023-10-11  1:24 ` Ping-Ke Shih [this message]
2023-10-11  4:52   ` [PATCH] [v2] " Dmitry Antipov
2023-10-11  5:34     ` Ping-Ke Shih
2023-10-12 12:14     ` 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=cbbd8f38e9ef4e3dba415952cf466ee8@realtek.com \
    --to=pkshih@realtek.com \
    --cc=dmantipov@yandex.ru \
    --cc=kvalo@kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    /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.