From: Arend van Spriel <arend.vanspriel@broadcom.com>
To: Michele Dionisio <michele.dionisio@gmail.com>
Cc: Arend van Spriel <arend.vanspriel@broadcom.com>,
Hante Meuleman <meuleman@broadcom.com>,
Fan Wu <fanwu01@zju.edu.cn>, Kalle Valo <kvalo@kernel.org>,
Pieter-Paul Giesberts <pieterpg@broadcom.com>,
linux-wireless@vger.kernel.org, brcm80211@lists.linux.dev,
brcm80211-dev-list.pdl@broadcom.com,
linux-kernel@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH wireless 1/1] wifi: brcmfmac: fix P2P device removal race in brcmf_detach()
Date: Sun, 4 Oct 2026 05:28:57 -0700 [thread overview]
Message-ID: <20261004122857.1391917-1-arend.vanspriel@broadcom.com> (raw)
In-Reply-To: <20260924123027.4122909-2-michele.dionisio@gmail.com>
On 9/24/2026 2:30 PM, Michele Dionisio wrote:
> When the driver is removed while the user space process that created
> the P2P device (e.g. wpa_supplicant) is still exiting, the P2P device
> interface is removed twice and the kernel crashes.
[...]
> For the interface without a netdev (the P2P device), take RTNL and the
> wiphy mutex in brcmf_detach() before reading iflist, and remove it with
> locked=true. If brcmf_p2p_del_vif() runs first, brcmf_detach() finds the
> slot empty. If brcmf_detach() runs first, nl80211 does not find the wdev
> any more. The interfaces with a netdev are removed as before, because
> brcmf_del_if() takes RTNL on its own for the primary interface.
>
> Fixes: 9831bcb987df ("brcmfmac: Deleting of p2p device is leaking memory.")
> Cc: stable@vger.kernel.org
> Assisted-by: claude-opus-5-5
Acked-by: Arend van Spriel <arend.vanspriel@broadcom.com>
> Signed-off-by: Michele Dionisio <michele.dionisio@gmail.com>
next prev parent reply other threads:[~2026-10-04 12:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-24 12:30 [PATCH wireless 0/1] wifi: brcmfmac: fix oops on removal while wpa_supplicant exits Michele Dionisio
2026-09-24 12:30 ` [PATCH wireless 1/1] wifi: brcmfmac: fix P2P device removal race in brcmf_detach() Michele Dionisio
2026-10-04 12:28 ` Arend van Spriel [this message]
-- strict thread matches above, loose matches on Subject: below --
2026-10-05 8:47 dolph-in
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=20261004122857.1391917-1-arend.vanspriel@broadcom.com \
--to=arend.vanspriel@broadcom.com \
--cc=brcm80211-dev-list.pdl@broadcom.com \
--cc=brcm80211@lists.linux.dev \
--cc=fanwu01@zju.edu.cn \
--cc=kvalo@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=meuleman@broadcom.com \
--cc=michele.dionisio@gmail.com \
--cc=pieterpg@broadcom.com \
--cc=stable@vger.kernel.org \
/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