From nobody Wed May 27 06:26:20 2026 X-Original-To: dev-commits-src-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4gQKQ45h0vz6fT2w for ; Wed, 27 May 2026 06:26:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R13" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4gQKQ42PJKz47c0 for ; Wed, 27 May 2026 06:26:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1779863180; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OPjpk30jIjqgHD/P+jWixMML3vhA92hb7vC20ioKl9w=; b=xF2BvQa+sgI83ipCTXlWt+OApZFfZaL9l1fzaU3XIvGfJJLWSz0bFH18op5ilIstVh5oy1 uQtpYq+WP1JEseOQLOjEiTEzDsngpJ9ffh1ed2fs5m5W00fwjj5P3lmfP1C6eLanmqrEW1 ocqXof6vsJMD7zUivz7SCF3HYARMsIy+zYmQEV4pztQwhVlz7CYUlTmDyl4ctFDfWebjr4 dkpJ3aaqWOQU7p+rrlk1dYAG6pHZa78YBn8+HdPsrEYqttucclV5rSZdVg4/89kkohLDQR XSZP9T1rbqRN+MPETGArGGU6kJpXDa44CtBcda2GVWNJqpTobYV0vH+yysKlTw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1779863180; a=rsa-sha256; cv=none; b=tcXz/bLAvKKrS44Q7iwTu8jWiDeh6aSwWiyNFSLBfl9MKQXyb4IAjXRkf3JzZLR4BpICHh l6DgtR+VI9LvnJ1YzgVBUOP0gn81m/wQnj0wL6uPu/FOqs1RBbhSwf+Z4fT/Qam8sXAfu8 JTVZGFu2mImBDInzdE5Yxi56H6ab6rTt0/KdOD+lpLuu6ys2LEa/nWGX8hNYMZURUOAq2p CSrNopW0cZig0wTHTFv8aJKRdlO5FKp7Q3KcBSYnHHcq0ymrfpPVb/sRFsRuuV50uZtvY+ 2MvGEJ6i3iJ4PFKclZygZ7/9UPoW2A+XDqizPSl8rElN9Umm86LAIWw9/nDuQQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1779863180; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OPjpk30jIjqgHD/P+jWixMML3vhA92hb7vC20ioKl9w=; b=PW8AWZcwZWgT7vK/00LVGFjq0KZivVsaMfTTd6BmCuwKnKxvREu6LP5xdfmQHUmQpd+Ssv HDIFniY7Z2ypuTt1gxI5rKXfpBB8yIJfOqny+6yS6Wm7PmRgwDckzhScuVskNyd9xLrDJi pVz/daoLflFbCxgDsdIYUi1q8lI6OUD4keCe/rsdyNLxZLRmFjvHJZQG+i6dRJKlwixLB7 /8/tSLlIfdP0JqDhGuW3tiC4yVU5RLs4cB+XKBTEePzDFL1kjdaRh+6wNA+eCQGPbdbc+y VtDC7nW3Te5NpPgXwZvTpon6E8/kewv14Wa8O9TjiovRu2TmzXVtZ8ymtl0d6w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4gQKQ41T1bznm8 for ; Wed, 27 May 2026 06:26:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 45b02 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 27 May 2026 06:26:20 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Bjoern A. Zeeb Subject: git: de65e20f8579 - stable/15 - LinuxKPI: 802.11: reset chanctx when recycling List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: de65e20f8579e659adce86a1de05e194199427cf Auto-Submitted: auto-generated Date: Wed, 27 May 2026 06:26:20 +0000 Message-Id: <6a168e8c.45b02.46e05830@gitrepo.freebsd.org> The branch stable/15 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=de65e20f8579e659adce86a1de05e194199427cf commit de65e20f8579e659adce86a1de05e194199427cf Author: Bjoern A. Zeeb AuthorDate: 2026-05-23 21:06:32 +0000 Commit: Bjoern A. Zeeb CommitDate: 2026-05-27 01:31:01 +0000 LinuxKPI: 802.11: reset chanctx when recycling When we no longer need a channel context and put it back on the reserved list, zero it for all but the vif so that we get the same state as if it was freshly allocated. Sponsored by: The FreeBSD Foundation Fixes: e62c92c0a5cf, 88cb1e17f471 (cherry picked from commit 8ead19207e56790bd4c64dba4ddbf2e0eb6922f7) --- sys/compat/linuxkpi/common/src/linux_80211.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index b9528295ad8e..efd1d9bae3cc 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2426,6 +2426,8 @@ lkpi_set_chanctx_conf(struct ieee80211_hw *hw, struct ieee80211_vif *vif, rcu_assign_pointer(vif->bss_conf.chanctx_conf, NULL); lchanctx = CHANCTX_CONF_TO_LCHANCTX(chanctx_conf); list_del(&lchanctx->entry); + memset(lchanctx, 0, sizeof(*lchanctx)); + lchanctx->lvif = VIF_TO_LVIF(vif); list_add_rcu(&lchanctx->entry, &lhw->lchanctx_list_reserved); } @@ -2460,6 +2462,8 @@ lkpi_remove_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif *vif) lchanctx = CHANCTX_CONF_TO_LCHANCTX(chanctx_conf); list_del(&lchanctx->entry); lhw = HW_TO_LHW(hw); + memset(lchanctx, 0, sizeof(*lchanctx)); + lchanctx->lvif = VIF_TO_LVIF(vif); list_add_rcu(&lchanctx->entry, &lhw->lchanctx_list_reserved); } @@ -6806,6 +6810,7 @@ linuxkpi_ieee80211_iffree(struct ieee80211_hw *hw) lkpi_80211_mo_remove_chanctx(hw, chanctx_conf); } list_del(&lchanctx->entry); + /* No need to reset the lchanctx here as we will free it below. */ list_add_rcu(&lchanctx->entry, &lhw->lchanctx_list_reserved); } }