linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kalle Valo <kvalo@codeaurora.org>
To: Zekun Shen <bruceshenzk@gmail.com>
Cc: Pontus Fuchs <pontus.fuchs@gmail.com>,
	"David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	linux-wireless@vger.kernel.org, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ar5523: Fix null-ptr-deref with unexpected WDCMSG_TARGET_START reply
Date: Fri, 29 Oct 2021 06:53:30 +0300	[thread overview]
Message-ID: <87tuh0xz9h.fsf@tynnyri.adurom.net> (raw)
In-Reply-To: <YXsmPQ3awHFLuAj2@10-18-43-117.dynapool.wireless.nyu.edu> (Zekun Shen's message of "Thu, 28 Oct 2021 18:37:49 -0400")

Zekun Shen <bruceshenzk@gmail.com> writes:

> Unexpected WDCMSG_TARGET_START replay can lead to null-ptr-deref
> when ar->tx_cmd->odata is NULL. The patch adds a null check to
> prevent such case.
>
> KASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007]
>  ar5523_cmd+0x46a/0x581 [ar5523]
>  ar5523_probe.cold+0x1b7/0x18da [ar5523]
>  ? ar5523_cmd_rx_cb+0x7a0/0x7a0 [ar5523]
>  ? __pm_runtime_set_status+0x54a/0x8f0
>  ? _raw_spin_trylock_bh+0x120/0x120
>  ? pm_runtime_barrier+0x220/0x220
>  ? __pm_runtime_resume+0xb1/0xf0
>  usb_probe_interface+0x25b/0x710
>  really_probe+0x209/0x5d0
>  driver_probe_device+0xc6/0x1b0
>  device_driver_attach+0xe2/0x120
>
> Signed-off-by: Zekun Shen <bruceshenzk@gmail.com>

How did you test this?

-- 
https://patchwork.kernel.org/project/linux-wireless/list/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches

  reply	other threads:[~2021-10-29  3:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-28 22:37 [PATCH] ar5523: Fix null-ptr-deref with unexpected WDCMSG_TARGET_START reply Zekun Shen
2021-10-29  3:53 ` Kalle Valo [this message]
2021-10-29 13:53   ` [PATCH] ar5523: Fix null-ptr-deref with unexpected WDCMSG_TARGET_START reply^[ Zekun Shen
2021-11-10 14:56     ` Kalle Valo
2021-11-12  7:54 ` [PATCH] ar5523: Fix null-ptr-deref with unexpected WDCMSG_TARGET_START reply 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=87tuh0xz9h.fsf@tynnyri.adurom.net \
    --to=kvalo@codeaurora.org \
    --cc=bruceshenzk@gmail.com \
    --cc=davem@davemloft.net \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pontus.fuchs@gmail.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).