From: Sergey Matyukevich <sergey.matyukevich.os@quantenna.com>
To: Kalle Valo <kvalo@codeaurora.org>
Cc: Igor Mitsyanko <imitsyanko@quantenna.com>,
Arnd Bergmann <arnd@arndb.de>,
Igor Mitsyanko <igor.mitsyanko.os@quantenna.com>,
Avinash Patil <avinashp@quantenna.com>,
Sergey Matyukevich <smatyukevich@quantenna.com>,
Kalle Valo <kvalo@codeaurora.org>,
"David S. Miller" <davem@davemloft.net>,
Andrey Shevchenko <ashevchenko@quantenna.com>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] qtnfmac: avoid uninitialized variable access
Date: Wed, 10 Oct 2018 14:56:33 +0000 [thread overview]
Message-ID: <20181010145625.fn2dy2np7e6xxdci@bars> (raw)
In-Reply-To: <20181009202507.xs5bcaq5pi4zcps3@bars>
> > When qtnf_trans_send_cmd_with_resp() fails, we have not yet initialized
> > 'resp', as pointed out by a valid gcc warning:
> >
> > drivers/net/wireless/quantenna/qtnfmac/commands.c: In function 'qtnf_cmd_send_with_reply':
> > drivers/net/wireless/quantenna/qtnfmac/commands.c:133:54: error: 'resp' may be used uninitialized in this function [-Werror=maybe-uninitialized]
> >
> > Since 'resp_skb' is also not set here, we can skip all further
> > processing and just print the warning and return the failure code.
> >
> > Fixes: c6ed298ffe09 ("qtnfmac: cleanup and unify command error handling")
> > Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>
> Thanks for the patch! And for reminding me that I forgot to enable
> gcc warnings in CI builds in addition to sparse checks.
>
> Reviewed-by: Sergey Matyukevich <sergey.matyukevich.os@quantenna.com>
Hi Kalle,
Could you please hold back applying this patch for now. We have got
another report for the same function, this time static analysis tool
warning. It looks like the patch from Arnd does not cover both cases.
So we will take a closer look and send a combined fix later.
Regards,
Sergey
next prev parent reply other threads:[~2018-10-10 14:56 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-09 15:57 [PATCH] qtnfmac: avoid uninitialized variable access Arnd Bergmann
2018-10-09 20:25 ` Sergey Matyukevich
2018-10-10 14:56 ` Sergey Matyukevich [this message]
2018-10-11 8:08 ` 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=20181010145625.fn2dy2np7e6xxdci@bars \
--to=sergey.matyukevich.os@quantenna.com \
--cc=arnd@arndb.de \
--cc=ashevchenko@quantenna.com \
--cc=avinashp@quantenna.com \
--cc=davem@davemloft.net \
--cc=igor.mitsyanko.os@quantenna.com \
--cc=imitsyanko@quantenna.com \
--cc=kvalo@codeaurora.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=smatyukevich@quantenna.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