From nobody Wed Apr 8 02:48:25 2026 Received: from mail-oo1-f72.google.com (mail-oo1-f72.google.com [209.85.161.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C56272FB965 for ; Tue, 10 Mar 2026 15:27:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.161.72 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773156428; cv=none; b=IrbbH6dFnbyk4IlXBxKBvG1ttRK6Qr/RNVW9tlLRM8X46ePT6J7gq9GXbMSNHTM3LyYVMjhb2Prff4Im6r5/LyRmobMIzW0fu9D3aau4SPNzIg0ENtqamaUGVyGaETxpZx+sqadH+tG4eKdnA+GhmiO+uf4bcTYZ9whUJl4ahlI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773156428; c=relaxed/simple; bh=OnU4cWyxRu8tYdQXS41MTuKjLHBpkt0k2kFmSeYiGoo=; h=MIME-Version:Date:In-Reply-To:Message-ID:Subject:From:To: Content-Type; b=pwcOx10tSo/XnNH9lvz12gnY6rTPD4x7kOZOI0/MNAHV/mFO2IgbWYaLdg28p9MN+gYVxhhPk2PUWV/TAIXJlMwevB6Baf+ERDOt905FVj/TEdSib4V0M/3ytVmjMMmUefYk2r8HNYLpjc9c0bfnVavZIBnd7ISrJ7D6L0m8Qwg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=syzkaller.appspotmail.com; spf=pass smtp.mailfrom=M3KW2WVRGUFZ5GODRSRYTGD7.apphosting.bounces.google.com; arc=none smtp.client-ip=209.85.161.72 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=syzkaller.appspotmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=M3KW2WVRGUFZ5GODRSRYTGD7.apphosting.bounces.google.com Received: by mail-oo1-f72.google.com with SMTP id 006d021491bc7-672c40f3873so220046053eaf.2 for ; Tue, 10 Mar 2026 08:27:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1773156426; x=1773761226; h=to:from:subject:message-id:in-reply-to:date:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=MDEMYPdT4kowag4hoFkOSADx4tkcGu3w8PKrbANnaFI=; b=soldmr4a5nxWIaD8KgVhbciEf3eXOvrU/DwheNE0ktrwTs0DCU8AwNlxE9rTr8SLnI BFxtWQATUTzey4JUPhMTnNzRLpijE9XZgsmgoslUizEl/Dps+f6CLl8ZcEeMkeKfEq5t thsSa+TlAzhjo9XGb2aEIP4Qjt/eawHcPVbv0l38qdC4ov2Y/yfFWmO8iJzpyt2X9qZW VtJZ3IaiIF4g3rEuWRjgIAqBrzgReSHnHO3d3HL+T/gpnkD9FhJGyCQX381uEmBy+DBs tU5sG2/K2bLNUeyx3Z/cf6q95p51HpUHjftrqwf10GUOJ9KyUuR4Jsv7RNwhWSI2hrFE 9dBA== X-Gm-Message-State: AOJu0YwV9RUs34JaPKkV9pMpcff4xxriKi2jDpg31rtqbPlWtZYXstHL ECyes+Obr7rUONxfLbsz+qas0INDsEQmyIJIT9riNj3Ac8dp4/cTz4SJ4fL7rtLqLfnuBDEqBs5 j3u+L6w46qfTn8O22hMGnVhM1oso8drGa43wi4BRGV/+OrYJdrxvH1zTIC0Q= Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Received: by 2002:a05:6820:4410:b0:67b:b40e:fc8c with SMTP id 006d021491bc7-67bb40efee5mr3719562eaf.55.1773156425756; Tue, 10 Mar 2026 08:27:05 -0700 (PDT) Date: Tue, 10 Mar 2026 08:27:05 -0700 In-Reply-To: <69af0a04.050a0220.310d8.002e.GAE@google.com> X-Google-Appengine-App-Id: s~syzkaller X-Google-Appengine-App-Id-Alias: syzkaller Message-ID: <69b03849.a70a0220.be77.0115.GAE@google.com> Subject: Forwarded: [PATCH] wifi: mac80211: fix WARN_ON_ONCE in ieee80211_tdls_oper From: syzbot To: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" For archival purposes, forwarding an incoming command email to linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com. *** Subject: [PATCH] wifi: mac80211: fix WARN_ON_ONCE in ieee80211_tdls_oper Author: kartikey406@gmail.com #syz test: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git= master NL80211_TDLS_ENABLE_LINK can be called without completing the TDLS setup handshake, or after the TDLS_PEER_SETUP_TIMEOUT (15 seconds) has expired and tdls_peer_del_work has zeroed out the peer address. In both cases the WARN_ON_ONCE triggers because tdls_peer is either zero or mismatched with the requested peer. Replace the WARN_ON_ONCE with a proper check that returns -ENOLINK to enforce that ENABLE_LINK can only proceed after a successful TDLS handshake. Reported-by: syzbot+56b6a844a4ea74487b7b@syzkaller.appspotmail.com Closes: https://syzkaller.appspot.com/bug?extid=3D56b6a844a4ea74487b7b Signed-off-by: Deepanshu Kartikey --- net/mac80211/tdls.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/net/mac80211/tdls.c b/net/mac80211/tdls.c index dbbfe2d6842f..d7d8b2fcc3ee 100644 --- a/net/mac80211/tdls.c +++ b/net/mac80211/tdls.c @@ -1457,8 +1457,9 @@ int ieee80211_tdls_oper(struct wiphy *wiphy, struct n= et_device *dev, =20 set_sta_flag(sta, WLAN_STA_TDLS_PEER_AUTH); =20 - WARN_ON_ONCE(is_zero_ether_addr(sdata->u.mgd.tdls_peer) || - !ether_addr_equal(sdata->u.mgd.tdls_peer, peer)); + if (is_zero_ether_addr(sdata->u.mgd.tdls_peer) || + !ether_addr_equal(sdata->u.mgd.tdls_peer, peer)) + return -ENOLINK; break; case NL80211_TDLS_DISABLE_LINK: /* --=20 2.43.0