From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 78DCC38BF9B for ; Mon, 9 Mar 2026 10:19:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773051580; cv=none; b=p0SiQmAcwu8NuTbxqpEyCWPjMhLBGM4PlQJ+gYbqjZtKCls/fXGqJEqva8rd/yrXZD1Q+hJiy6TCb3IZV2mG3c7e88cq/TJSvFQAiz9ROxelj/wbwYdZByFZeXRO3Ini1UWxh9psYUzX73FhEbj07ySHrBmqQTr0Lu080qC5mqA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773051580; c=relaxed/simple; bh=gygdEvpnhJzsq2pG+XisBLTAnZNKgbUv9GTgG90dQc4=; h=Subject:To:Cc:From:Date:Message-ID:MIME-Version:Content-Type; b=t0JRk2HAywZY1ANNuNlq5Hoxji+G2ZMXzgJhymxmVlep35MOI21DqY/M371LYCpSREq21IDy1jzcpKBL7b0I9c6TA5daCyQE6e958+DQtL/YdgC6GsPzIeU5D7fmy9Ni52UZny1lTacP6bqrlZDLUsCtLRRa7uyLTuGfEJUzf9Q= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=nKtnOmZM; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="nKtnOmZM" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0CF4AC19423; Mon, 9 Mar 2026 10:19:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1773051580; bh=gygdEvpnhJzsq2pG+XisBLTAnZNKgbUv9GTgG90dQc4=; h=Subject:To:Cc:From:Date:From; b=nKtnOmZMNYZIP1lbm4k9DOTwA6E+mjpvp4xJGogGA1LGV8P7VPJuxu6C4a1M4pSPd gqnOwBOIkysANIIYljibmBvyflANmhgw2zZ9oIKy13VbbLm5Sfm+lk8AsiG+JHp6XH ui8Y7rw4nXKHTYgFOgp4hqLV+/liM1M7Dgntk/P4= Subject: FAILED: patch "[PATCH] wifi: cfg80211: cancel rfkill_block work in" failed to apply to 6.1-stable tree To: d.dulov@aladdin.ru,johannes.berg@intel.com Cc: From: Date: Mon, 09 Mar 2026 11:19:34 +0100 Message-ID: <2026030934-undocked-comic-8b24@gregkh> Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit The patch below does not apply to the 6.1-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . To reproduce the conflict and resubmit, you may use the following commands: git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.1.y git checkout FETCH_HEAD git cherry-pick -x 767d23ade706d5fa51c36168e92a9c5533c351a1 # git commit -s git send-email --to '' --in-reply-to '2026030934-undocked-comic-8b24@gregkh' --subject-prefix 'PATCH 6.1.y' HEAD^.. Possible dependencies: thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From 767d23ade706d5fa51c36168e92a9c5533c351a1 Mon Sep 17 00:00:00 2001 From: Daniil Dulov Date: Wed, 11 Feb 2026 11:20:24 +0300 Subject: [PATCH] wifi: cfg80211: cancel rfkill_block work in wiphy_unregister() There is a use-after-free error in cfg80211_shutdown_all_interfaces found by syzkaller: BUG: KASAN: use-after-free in cfg80211_shutdown_all_interfaces+0x213/0x220 Read of size 8 at addr ffff888112a78d98 by task kworker/0:5/5326 CPU: 0 UID: 0 PID: 5326 Comm: kworker/0:5 Not tainted 6.19.0-rc2 #2 PREEMPT(voluntary) Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.15.0-1 04/01/2014 Workqueue: events cfg80211_rfkill_block_work Call Trace: dump_stack_lvl+0x116/0x1f0 print_report+0xcd/0x630 kasan_report+0xe0/0x110 cfg80211_shutdown_all_interfaces+0x213/0x220 cfg80211_rfkill_block_work+0x1e/0x30 process_one_work+0x9cf/0x1b70 worker_thread+0x6c8/0xf10 kthread+0x3c5/0x780 ret_from_fork+0x56d/0x700 ret_from_fork_asm+0x1a/0x30 The problem arises due to the rfkill_block work is not cancelled when wiphy is being unregistered. In order to fix the issue cancel the corresponding work in wiphy_unregister(). Found by Linux Verification Center (linuxtesting.org) with Syzkaller. Fixes: 1f87f7d3a3b4 ("cfg80211: add rfkill support") Cc: stable@vger.kernel.org Signed-off-by: Daniil Dulov Link: https://patch.msgid.link/20260211082024.1967588-1-d.dulov@aladdin.ru Signed-off-by: Johannes Berg diff --git a/net/wireless/core.c b/net/wireless/core.c index 9af85d655027..d35cf04cbc81 100644 --- a/net/wireless/core.c +++ b/net/wireless/core.c @@ -1212,6 +1212,7 @@ void wiphy_unregister(struct wiphy *wiphy) /* this has nothing to do now but make sure it's gone */ cancel_work_sync(&rdev->wiphy_work); + cancel_work_sync(&rdev->rfkill_block); cancel_work_sync(&rdev->conn_work); flush_work(&rdev->event_work); cancel_delayed_work_sync(&rdev->dfs_update_channels_wk);