From: Kalle Valo <kvalo@codeaurora.org>
To: Arnd Bergmann <arnd@kernel.org>
Cc: Felix Fietkau <nbd@nbd.name>,
Lorenzo Bianconi <lorenzo.bianconi83@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Matthias Brugger <matthias.bgg@gmail.com>,
Arnd Bergmann <arnd@arndb.de>, Ryder Lee <ryder.lee@mediatek.com>,
Nathan Chancellor <nathan@kernel.org>,
Nick Desaulniers <ndesaulniers@google.com>,
Sean Wang <sean.wang@mediatek.com>,
Soul Huang <Soul.Huang@mediatek.com>,
linux-wireless@vger.kernel.org, netdev@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org,
clang-built-linux@googlegroups.com
Subject: Re: [PATCH 2/2] mt76: mt7921: remove incorrect error handling
Date: Fri, 26 Feb 2021 09:22:37 +0000 (UTC) [thread overview]
Message-ID: <20210226092237.AC8BFC43466@smtp.codeaurora.org> (raw)
In-Reply-To: <20210225145953.404859-2-arnd@kernel.org>
Arnd Bergmann <arnd@kernel.org> wrote:
> From: Arnd Bergmann <arnd@arndb.de>
>
> Clang points out a mistake in the error handling in
> mt7921_mcu_tx_rate_report(), which tries to dereference a pointer that
> cannot be initialized because of the error that is being handled:
>
> drivers/net/wireless/mediatek/mt76/mt7921/mcu.c:409:3: warning: variable 'stats' is uninitialized when used here [-Wuninitialized]
> stats->tx_rate = rate;
> ^~~~~
> drivers/net/wireless/mediatek/mt76/mt7921/mcu.c:401:32: note: initialize the variable 'stats' to silence this warning
> struct mt7921_sta_stats *stats;
> ^
> Just remove the obviously incorrect line.
>
> Fixes: 1c099ab44727 ("mt76: mt7921: add MCU support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Patch applied to wireless-drivers.git, thanks.
fb5fabb192b2 mt76: mt7921: remove incorrect error handling
--
https://patchwork.kernel.org/project/linux-wireless/patch/20210225145953.404859-2-arnd@kernel.org/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
next prev parent reply other threads:[~2021-02-26 9:25 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-25 14:59 [PATCH 1/2] mt76: mt7915: fix unused 'mode' variable Arnd Bergmann
2021-02-25 14:59 ` [PATCH 2/2] mt76: mt7921: remove incorrect error handling Arnd Bergmann
2021-02-25 21:41 ` Nick Desaulniers
2021-02-26 9:22 ` Kalle Valo [this message]
2021-02-25 16:00 ` [PATCH 1/2] mt76: mt7915: fix unused 'mode' variable Kalle Valo
2021-02-25 17:58 ` Nathan Chancellor
2021-02-26 9:23 ` 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=20210226092237.AC8BFC43466@smtp.codeaurora.org \
--to=kvalo@codeaurora.org \
--cc=Soul.Huang@mediatek.com \
--cc=arnd@arndb.de \
--cc=arnd@kernel.org \
--cc=clang-built-linux@googlegroups.com \
--cc=davem@davemloft.net \
--cc=kuba@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-wireless@vger.kernel.org \
--cc=lorenzo.bianconi83@gmail.com \
--cc=matthias.bgg@gmail.com \
--cc=nathan@kernel.org \
--cc=nbd@nbd.name \
--cc=ndesaulniers@google.com \
--cc=netdev@vger.kernel.org \
--cc=ryder.lee@mediatek.com \
--cc=sean.wang@mediatek.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;
as well as URLs for NNTP newsgroup(s).