From: Jeff Johnson <jeff.johnson@oss.qualcomm.com>
To: Aditya Kumar Singh <quic_adisi@quicinc.com>,
Kalle Valo <kvalo@kernel.org>, Jeff Johnson <jjohnson@kernel.org>,
Rameshkumar Sundaram <quic_ramess@quicinc.com>,
Sriram R <quic_srirrama@quicinc.com>
Cc: Kalle Valo <quic_kvalo@quicinc.com>,
linux-wireless@vger.kernel.org, ath12k@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] wifi: ath12k: fix read pointer after free in ath12k_mac_assign_vif_to_vdev()
Date: Mon, 9 Dec 2024 22:04:58 -0800 [thread overview]
Message-ID: <fc745e1c-cfad-4ccf-aa9c-77cb76c2f23d@oss.qualcomm.com> (raw)
In-Reply-To: <20241210-read_after_free-v1-1-969f69c7d66c@quicinc.com>
On 12/9/2024 9:26 PM, Aditya Kumar Singh wrote:
> In ath12k_mac_assign_vif_to_vdev(), if arvif is created on a different
> radio, it gets deleted from that radio through a call to
> ath12k_mac_unassign_link_vif(). This action frees the arvif pointer.
> Subsequently, there is a check involving arvif, which will result in a
> read-after-free scenario.
>
> Fix this by moving this check after arvif is again assigned via call to
> ath12k_mac_assign_link_vif().
>
> Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.3.1-00173-QCAHKSWPL_SILICONZ-1
>
> Closes: https://scan5.scan.coverity.com/#/project-view/63541/10063?selectedIssue=1636423
> Fixes: b5068bc9180d ("wifi: ath12k: Cache vdev configs before vdev create")
> Signed-off-by: Aditya Kumar Singh <quic_adisi@quicinc.com>
Acked-by: Jeff Johnson <jeff.johnson@oss.qualcomm.com>
next prev parent reply other threads:[~2024-12-10 6:43 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-10 5:26 [PATCH] wifi: ath12k: fix read pointer after free in ath12k_mac_assign_vif_to_vdev() Aditya Kumar Singh
2024-12-10 6:04 ` Jeff Johnson [this message]
2024-12-12 11:26 ` Kalle Valo
2024-12-12 18:29 ` Jeff Johnson
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=fc745e1c-cfad-4ccf-aa9c-77cb76c2f23d@oss.qualcomm.com \
--to=jeff.johnson@oss.qualcomm.com \
--cc=ath12k@lists.infradead.org \
--cc=jjohnson@kernel.org \
--cc=kvalo@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=quic_adisi@quicinc.com \
--cc=quic_kvalo@quicinc.com \
--cc=quic_ramess@quicinc.com \
--cc=quic_srirrama@quicinc.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