From: Kees Cook <keescook@chromium.org>
To: Ping-Ke Shih <pkshih@realtek.com>
Cc: Kees Cook <keescook@chromium.org>,
Kalle Valo <kvalo@codeaurora.org>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Larry Finger <Larry.Finger@lwfinger.net>,
Colin Ian King <colin.king@canonical.com>,
Kaixu Xia <kaixuxia@tencent.com>, Joe Perches <joe@perches.com>,
linux-wireless@vger.kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-hardening@vger.kernel.org
Subject: [PATCH] rtlwifi: rtl8192de: Restore channel index initialization
Date: Wed, 25 Aug 2021 11:31:03 -0700 [thread overview]
Message-ID: <20210825183103.1142909-1-keescook@chromium.org> (raw)
2G channel indexes still need "place" to be initialized, since it is
returned from this function when channel is less than 14.
Fixes: 369956ae5720 ("rtlwifi: rtl8192de: Remove redundant variable initializations")
Cc: Ping-Ke Shih <pkshih@realtek.com>
Cc: Kalle Valo <kvalo@codeaurora.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jakub Kicinski <kuba@kernel.org>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Colin Ian King <colin.king@canonical.com>
Cc: Kaixu Xia <kaixuxia@tencent.com>
Cc: Joe Perches <joe@perches.com>
Cc: linux-wireless@vger.kernel.org
Cc: netdev@vger.kernel.org
Signed-off-by: Kees Cook <keescook@chromium.org>
---
drivers/net/wireless/realtek/rtlwifi/rtl8192de/phy.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192de/phy.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192de/phy.c
index 8ae69d914312..b32fa7a75f17 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8192de/phy.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192de/phy.c
@@ -896,7 +896,7 @@ static void _rtl92d_ccxpower_index_check(struct ieee80211_hw *hw,
static u8 _rtl92c_phy_get_rightchnlplace(u8 chnl)
{
- u8 place;
+ u8 place = chnl;
if (chnl > 14) {
for (place = 14; place < sizeof(channel5g); place++) {
--
2.30.2
next reply other threads:[~2021-08-25 18:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-25 18:31 Kees Cook [this message]
2021-08-26 0:45 ` [PATCH] rtlwifi: rtl8192de: Restore channel index initialization Pkshih
2021-08-26 2:36 ` Kees Cook
2021-08-26 3:48 ` Pkshih
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=20210825183103.1142909-1-keescook@chromium.org \
--to=keescook@chromium.org \
--cc=Larry.Finger@lwfinger.net \
--cc=colin.king@canonical.com \
--cc=davem@davemloft.net \
--cc=joe@perches.com \
--cc=kaixuxia@tencent.com \
--cc=kuba@kernel.org \
--cc=kvalo@codeaurora.org \
--cc=linux-hardening@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pkshih@realtek.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox