From nobody Fri Apr 11 21:26:18 2025 X-Original-To: dev-commits-src-all@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 4ZZ8rB5wq6z5shpT; Fri, 11 Apr 2025 21:26:18 +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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4ZZ8rB4PQFz3tgp; Fri, 11 Apr 2025 21:26:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1744406778; 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=VBEDs0R3WXRKlEKa8D+YqN8kJ6hLXT37EB66irml6B0=; b=abZRUcobPkr9W9cTAWEKhx8rDlOezvGhvwj0/QdLnnQU/U/ZCV3UvIHrKpUckDUEMc4FJq 769CFhk7jFOa/fkop4EzdtVO44gwOKw2g7FjIZh0MPDXHwoOcyFiHrzZbRZ9wmm0otj3yl 3/bB6mrP3xG7GQUg2o58VzkYim1eyT06f9sAdQmz3lR3niDyZD8/AS1r8fBWoHh/HBXQ+n BkCPKEAEJPTWfKKDexEVH3LfqkimsyjdLQq7eF9KRDWbd3nR8+ccY68vGEuDusuAzRULmJ 3YsXzPs6O2EIkYalOurJBtJ33oN5/RRvNc4GpCW9/PACU2PkYXmXuZ+6YQuvnA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1744406778; a=rsa-sha256; cv=none; b=W4S+y2T++3U8UW9GjLORI9Eiu/0rZiH9QtJPZH7WURqITdXDUU8FzpRzy2nRHC7GlX6kFx m4pOD4JAWB9dViD+JXJ8tRvFJ0UeedIgGBI8hMwcfm0HR+ExGrhFnkr88VC8ApNIQxcnI+ Vwz2vIvCMaZtcIEC89JM7yU6mZAAqOULuxtVpxPim56IUGe2EQvHqwBZIxfgOfH4DYBP6f KLr9f8APhVeWcCo7SUKY6WR3dsPiINzMQ7RZWbbcwKlBSIiogJUaJS3EDw3I/0uR12Q3su B4DHZbRgK2ynsKtuOZFQ/sjWfqLgxUtxmFNI7SPJA6iuFqELV3uxewBc1SYmDQ== 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=1744406778; 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=VBEDs0R3WXRKlEKa8D+YqN8kJ6hLXT37EB66irml6B0=; b=kcs9tx7e7lz8LRI5IW6sp/IVXkaDGDQPv/VkLp4kwC0xwQkGo+mhBQjqRnT9HZ0gncLYEq jzmP6QclREZ6WYhctGJXisthtmKd6XhzQZLRUp1k5JU75FQNR2ptciFY3sL8UBeB+9XTKO HHaVJO8spU0OIb8IJf3b97woF9J/PrSXDyC0ZnYx5tAMskLHBuo0Lwk4HXiacz1+Z0cAdi q5Jb9pzgIGhFteOH6t4FLug+JjJNb2CS2dTG+Tuc1WZSakuHwETzJ2Oyj/t/MtqhmJHOJg /Jx4vz+2DSmpamtTRQRAH/NIRNNDH5tIywMX6ranV2U4wMNfxO5Q/6YiGdJOhg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4ZZ8rB3ygYzpy1; Fri, 11 Apr 2025 21:26:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 53BLQIpb078158; Fri, 11 Apr 2025 21:26:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 53BLQIuI078155; Fri, 11 Apr 2025 21:26:18 GMT (envelope-from git) Date: Fri, 11 Apr 2025 21:26:18 GMT Message-Id: <202504112126.53BLQIuI078155@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 11604b2a1659 - main - LinuxKPI: 802.11: move chanctx_conf from vif to vif->bss_conf List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org 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/main X-Git-Reftype: branch X-Git-Commit: 11604b2a1659fd6da9bbfdc6acf9758884cb2b36 Auto-Submitted: auto-generated The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=11604b2a1659fd6da9bbfdc6acf9758884cb2b36 commit 11604b2a1659fd6da9bbfdc6acf9758884cb2b36 Author: Bjoern A. Zeeb AuthorDate: 2025-04-08 00:56:36 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-04-11 21:17:55 +0000 LinuxKPI: 802.11: move chanctx_conf from vif to vif->bss_conf In preparations for MLD support chanctx_conf was moved from vif to the bss_conf as it will be per-link later. Follow accordingly. Sponsored by: The FreeBSD Foundation PR: 280546 MFC after: 3 days Tested by: Oleksandr Kryvulia (shuriku shurik.kiev.ua) Tested by: Oleg Nauman (oleg.nauman gmail.com) [rtw88] Differential Revision: https://reviews.freebsd.org/D49734 --- sys/compat/linuxkpi/common/include/net/mac80211.h | 1 - sys/compat/linuxkpi/common/src/linux_80211.c | 20 ++++++++++---------- sys/compat/linuxkpi/common/src/linux_80211_macops.c | 2 +- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/net/mac80211.h b/sys/compat/linuxkpi/common/include/net/mac80211.h index 95991dd2ac42..016143874564 100644 --- a/sys/compat/linuxkpi/common/include/net/mac80211.h +++ b/sys/compat/linuxkpi/common/include/net/mac80211.h @@ -839,7 +839,6 @@ struct ieee80211_vif { bool probe_req_reg; uint8_t addr[ETH_ALEN]; struct ieee80211_vif_cfg cfg; - struct ieee80211_chanctx_conf *chanctx_conf; /* XXX-BZ no longer used anywhere but in linuxkpi 802.11 internally; now in bss_conf per-link? */ struct ieee80211_txq *txq; struct ieee80211_bss_conf bss_conf; struct ieee80211_bss_conf *link_conf[IEEE80211_MLD_MAX_NUM_LINKS]; /* rcu? */ diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 5c50060e3dc0..28bd2c062427 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -1736,14 +1736,14 @@ static void lkpi_remove_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif *vif) { /* Take the chan ctx down. */ - if (vif->chanctx_conf != NULL) { + if (vif->bss_conf.chanctx_conf != NULL) { struct lkpi_chanctx *lchanctx; struct ieee80211_chanctx_conf *chanctx_conf; - chanctx_conf = vif->chanctx_conf; + chanctx_conf = vif->bss_conf.chanctx_conf; /* Remove vif context. */ - lkpi_80211_mo_unassign_vif_chanctx(hw, vif, &vif->bss_conf, &vif->chanctx_conf); - /* NB: vif->chanctx_conf is NULL now. */ + lkpi_80211_mo_unassign_vif_chanctx(hw, vif, &vif->bss_conf, &vif->bss_conf.chanctx_conf); + /* NB: vif->bss_conf.chanctx_conf is NULL now. */ lkpi_hw_conf_idle(hw, true); @@ -1840,8 +1840,8 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int LKPI_80211_LHW_LOCK(lhw); /* Add chanctx (or if exists, change it). */ - if (vif->chanctx_conf != NULL) { - chanctx_conf = vif->chanctx_conf; + if (vif->bss_conf.chanctx_conf != NULL) { + chanctx_conf = vif->bss_conf.chanctx_conf; lchanctx = CHANCTX_CONF_TO_LCHANCTX(chanctx_conf); IMPROVE("diff changes for changed, working on live copy, rcu"); } else { @@ -1916,7 +1916,7 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int bss_changed |= lkpi_update_dtim_tsf(vif, ni, vap, __func__, __LINE__); error = 0; - if (vif->chanctx_conf != NULL) { + if (vif->bss_conf.chanctx_conf != NULL) { changed = IEEE80211_CHANCTX_CHANGE_MIN_WIDTH; changed |= IEEE80211_CHANCTX_CHANGE_RADAR; changed |= IEEE80211_CHANCTX_CHANGE_RX_CHAINS; @@ -3470,7 +3470,7 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], /* XXX-BZ hardcoded for now! */ #if 1 - vif->chanctx_conf = NULL; + vif->bss_conf.chanctx_conf = NULL; vif->bss_conf.vif = vif; /* vap->iv_myaddr is not set until net80211::vap_setup or vap_attach. */ IEEE80211_ADDR_COPY(vif->bss_conf.addr, mac); @@ -5970,10 +5970,10 @@ linuxkpi_ieee80211_iterate_chan_contexts(struct ieee80211_hw *hw, TAILQ_FOREACH(lvif, &lhw->lvif_head, lvif_entry) { vif = LVIF_TO_VIF(lvif); - if (vif->chanctx_conf == NULL) + if (vif->bss_conf.chanctx_conf == NULL) continue; - lchanctx = CHANCTX_CONF_TO_LCHANCTX(vif->chanctx_conf); + lchanctx = CHANCTX_CONF_TO_LCHANCTX(vif->bss_conf.chanctx_conf); if (!lchanctx->added_to_drv) continue; diff --git a/sys/compat/linuxkpi/common/src/linux_80211_macops.c b/sys/compat/linuxkpi/common/src/linux_80211_macops.c index fde23d02af5e..9a7207424b2f 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211_macops.c +++ b/sys/compat/linuxkpi/common/src/linux_80211_macops.c @@ -458,7 +458,7 @@ lkpi_80211_mo_assign_vif_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif * hw, vif, conf, chanctx_conf); error = lhw->ops->assign_vif_chanctx(hw, vif, conf, chanctx_conf); if (error == 0) - vif->chanctx_conf = chanctx_conf; + vif->bss_conf.chanctx_conf = chanctx_conf; out: return (error);