From nobody Mon Oct 09 23:16:24 2023 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 4S4FK44Y4Yz4wh59; Mon, 9 Oct 2023 23:16:24 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S4FK436WLz3R20; Mon, 9 Oct 2023 23:16:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696893384; 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=gnqYoHzDcFUlvEIHYI0L1TgFAbu9QHWOlPN8D51Yd1k=; b=xvfHSQJmMdJXCQvgMqL4hAtDH5+92ym+oYAOFIZ4YcToaKMRqE2+zhGckrZ2yPljLEnOcc +ebm8h7jEoy49KVCHxEfk0qfJkIrnm7Z9a/W4tH0yekb4VZ4q5ZQKTCIq9wFEOJWmLFqPI EI2ewxjpMxNu1rcsrNQBSLzdZeFFgA+nVwS+WcdZVwXfmUso6xkqXGmDiNl3h/UOEXQxvy EkO0PvJP63hz1nyIiqIzNNp1bet3MgHYI7bnr6HwuYJYKRNS9w4f8TWKsDihem3FtGzpGN Y/ByaHywMELJNQkkvoZWcx9zcmws2alldc5nSH4sgmxXoApZZT+ar9LL5q1T9Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696893384; a=rsa-sha256; cv=none; b=vC4Y+2p8dqA9gmmy/nl3Itc9bE6c1yI52VqakMZ4wfXujCQWEYYyp9W1P8SNqdl9k/z0W5 rYyGf27MRwckvLnVrI80bdFetmA0+40qYz+HiEOYQqds6otx0mKY6w3/nWXWcAmcRFaOQ6 XCttMSwfP5AFe1R28+6j+gA2pHToma+vLHmcA8s9h7SvqHd5Ft2Xxqyo+zwY50ZIjWkhfU dyYn0SIchZMufy4ygF9UqQWY19yXFPSu+E0u/aOFjXvH4Ymu8ijrSkR1txaRDiH8hNKQsT /sKqcwruwI12q66e8LKVM4g1AxCSg8mqJJ/xNblj4VxWfwfuwkSF+EoKlKPLAg== 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=1696893384; 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=gnqYoHzDcFUlvEIHYI0L1TgFAbu9QHWOlPN8D51Yd1k=; b=Ws8Y1MgikyeEnqyHzkOmzDLtuN56xR1Sm0fBUmHccv2MU96hq4XjfCM4/Dn/RKHb9R6Hzd 4YGW98IuLr1NjXBWMwyZcgvweQoSz4j7iUV1AXvRhRIagYQHU/yfSNWuedF2x2UjW9+68m y810Y0MigN2t0hT9sUP42Ilb28f4zG+Mk1H5ggoCBEqBF/WM7gtDeaHbgEJjZeCuhJWlEP JRpHUGMJER27Do/YXz9rTMwRu+DCcivysY/lecthdQoazfDruEVSxbOHsY2yfxWVWEn0eg GSppRW50uMLKUFJPVdG3jWSlvRfVo8iw7DCFsnAdJgC+KUZEbB9xmwOs7g29NA== 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 4S4FK42BP9zl7; Mon, 9 Oct 2023 23:16:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 399NGO4k071680; Mon, 9 Oct 2023 23:16:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 399NGONb071677; Mon, 9 Oct 2023 23:16:24 GMT (envelope-from git) Date: Mon, 9 Oct 2023 23:16:24 GMT Message-Id: <202310092316.399NGONb071677@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: da24b50552e7 - releng/14.0 - LinuxKPI: 802.11: inialize tx queue params 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: 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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: da24b50552e72d5d7ff6f995902777125f3d202d Auto-Submitted: auto-generated The branch releng/14.0 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=da24b50552e72d5d7ff6f995902777125f3d202d commit da24b50552e72d5d7ff6f995902777125f3d202d Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 12:36:38 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-09 23:14:54 +0000 LinuxKPI: 802.11: inialize tx queue params When adding a VAP (vif) initialize its tx queue parameters calling mo_conf_tx(). I could not spot net80211 providing some of the values needed before having a node so currrently we use hard-coded values with a comment with a reference on how to properly calculate the values in the future (e.g., in case of 11b or other cases). Sponsored by: The FreeBSD Foundation Approved by: re (gjb) (cherry picked from commit a6042e17c8999c4965bd4d762c4564b322f1ae7b) (cherry picked from commit 68e1e25baf2e5576011ed532d5a30e70997d488c) --- sys/compat/linuxkpi/common/src/linux_80211.c | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 7ffe658a628d..e89979521296 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2244,9 +2244,11 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], struct lkpi_vif *lvif; struct ieee80211vap *vap; struct ieee80211_vif *vif; + struct ieee80211_tx_queue_params txqp; enum ieee80211_bss_changed changed; size_t len; int error, i; + uint16_t ac; if (!TAILQ_EMPTY(&ic->ic_vaps)) /* 1 so far. Add once this works. */ return (NULL); @@ -2345,7 +2347,24 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], changed = 0; lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, changed); - /* conf_tx setup; default WME? */ + /* Configure tx queues (conf_tx), default WME & send BSS_CHANGED_QOS. */ + IMPROVE("Hardcoded values; to fix see 802.11-2016, 9.4.2.29 EDCA Parameter Set element"); + LKPI_80211_LHW_LOCK(lhw); + for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) { + + bzero(&txqp, sizeof(txqp)); + txqp.cw_min = 15; + txqp.cw_max = 1023; + txqp.txop = 0; + txqp.aifs = 2; + error = lkpi_80211_mo_conf_tx(hw, vif, /* link_id */0, ac, &txqp); + if (error != 0) + ic_printf(ic, "%s: conf_tx ac %u failed %d\n", + __func__, ac, error); + } + LKPI_80211_LHW_UNLOCK(lhw); + changed = BSS_CHANGED_QOS; + lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, changed); /* Force MC init. */ lkpi_update_mcast_filter(ic, true);