From: merez@codeaurora.org
To: "Gustavo A. R. Silva" <gustavo@embeddedor.com>
Cc: Kalle Valo <kvalo@codeaurora.org>,
"David S. Miller" <davem@davemloft.net>,
Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>,
linux-wireless@vger.kernel.org, wil6210@qti.qualcomm.com,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-wireless-owner@vger.kernel.org
Subject: Re: [PATCH] wil6210: fix potential out-of-bounds read
Date: Mon, 15 Apr 2019 20:24:10 +0300 [thread overview]
Message-ID: <514f4e102c3cbbd59f4ba0805b091b36@codeaurora.org> (raw)
In-Reply-To: <20190415145646.GA16597@embeddedor>
On 2019-04-15 17:56, Gustavo A. R. Silva wrote:
> Notice that *rc* can evaluate to up to 5, include/linux/netdevice.h:
>
> enum gro_result {
> GRO_MERGED,
> GRO_MERGED_FREE,
> GRO_HELD,
> GRO_NORMAL,
> GRO_DROP,
> GRO_CONSUMED,
> };
> typedef enum gro_result gro_result_t;
>
> In case *rc* evaluates to 5, we end up having an out-of-bounds read
> at drivers/net/wireless/ath/wil6210/txrx.c:821:
>
> wil_dbg_txrx(wil, "Rx complete %d bytes => %s\n",
> len, gro_res_str[rc]);
>
> Fix this by adding element "GRO_CONSUMED" to array gro_res_str.
>
> Addresses-Coverity-ID: 1444666 ("Out-of-bounds read")
> Fixes: 194b482b5055 ("wil6210: Debug print GRO Rx result")
> Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
> ---
> drivers/net/wireless/ath/wil6210/txrx.c | 1 +
> 1 file changed, 1 insertion(+)
Reviewed-by: Maya Erez <merez@codeaurora.org>
--
Maya Erez
Qualcomm Israel, Inc. on behalf of Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a
Linux Foundation Collaborative Project
next prev parent reply other threads:[~2019-04-15 17:24 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-15 14:56 [PATCH] wil6210: fix potential out-of-bounds read Gustavo A. R. Silva
2019-04-15 17:24 ` merez [this message]
2019-04-15 17:29 ` Gustavo A. R. Silva
2019-04-29 15:00 ` Kalle Valo
[not found] ` <20190429150007.69D8E60741@smtp.codeaurora.org>
2019-04-29 15:23 ` Gustavo A. R. Silva
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=514f4e102c3cbbd59f4ba0805b091b36@codeaurora.org \
--to=merez@codeaurora.org \
--cc=davem@davemloft.net \
--cc=gustavo@embeddedor.com \
--cc=kvalo@codeaurora.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless-owner@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=qca_vkondrat@qca.qualcomm.com \
--cc=wil6210@qti.qualcomm.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).