From nobody Thu May 23 23:46:13 2024 X-Original-To: dev-commits-src-main@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 4VllDj2gsKz5Lbdm; Thu, 23 May 2024 23:46:13 +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 4VllDj24qgz4TZr; Thu, 23 May 2024 23:46:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1716507973; 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=6bko5/PeaOj6QpLAX2nsIBnlmcZ9IjA+Poj4XjoDpac=; b=RVD5fj1R6J6LHosPZOA9RC5OA0+a3nOxnGltdZZKneCjha6lS1UwGhU7e08QbbJ190KOXA eocDpSGXsKdL3RQV2X+S2ToBsTFAmF82UpLO1pvzwYF9HM7itIes/bPTKK3lz+aCgDOQ5D lklkkgPa96ulT1LQHIQ+IUeuSL/U3CFYADdaq/hZhGtyhxDGS79pdXIkvTKL0qIsjpOlyQ n1FzJEmJrwhXN8i5FJ8yZjsSR3h8udw4nVgLvCoNq7Bn4uFbSC4b1/riD92a3nM0CZ26JV 715sZqKEjYVyWK6fHKYytOE2iS7m5MMajTmF5VbZL6Nu0I9XH99FxLRt8n9V4Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1716507973; a=rsa-sha256; cv=none; b=pvY8DOtWl98McyQx7eNdYsB0fkpxGs/bMlueHmhl6OeJaNFyQ4aOOXnlqi+73CGf3GxZ8R daJ7qsABkDzRh0jcvL1gIL3wfy7txR3y6k97I+2UXTCH3D1CMky7KmHtu4KS+fwwo/ZKpI NpV5f7IOM15PRpGnTLXxZxpeRQT3vaARtEj3UeHc13KLPfqKfDM7na97RQtt8TLvr+gDjK jUU4uGNIGpGTfqOCWR7PuuI7BvIsjJQm2KN0vizGX+eSRteysW8+Mg4dAWDHF7J8oEyR8A 60IxEgz4LTRa9EcIn2wR5bcf07oHaxSxsx8Rmewr2M0wGhuDQ4DJ4/Sm+QGP7A== 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=1716507973; 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=6bko5/PeaOj6QpLAX2nsIBnlmcZ9IjA+Poj4XjoDpac=; b=sdUxgfNlQvFwoPWcrVaSR7egbkW6tX4Tz32NuN8hqs9MtIoe1rHeyIHDo/g9CwpIb9C6mz EDH80KkUc3iOaA+uBUSPhMnr4WIzuZXqr/fqot/g5K9W+YcY9b1QKXuPGEJU4SHI7vPCSi tsKmb5FtXD1JPwcjDyNvK6EULo4CUIeC96IjqF9Bk7s9/dS67X96R6nRg1S61rKxVEPiiJ fWfFtaghm1XGoxLbvvKyzfCRFxRJon+HipR0AJiKtJxQjMdjrrPICIkQCwPBUVEjHAr++1 Yf9sAxZNnqjM0hGet0DNTFmmI5kYNLwy1XGl+ANbwEK2vx8AO8bNrXpoDm+A/g== 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 4VllDj1Xf6z18nQ; Thu, 23 May 2024 23:46:13 +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 44NNkDsU092943; Thu, 23 May 2024 23:46:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 44NNkD4m092940; Thu, 23 May 2024 23:46:13 GMT (envelope-from git) Date: Thu, 23 May 2024 23:46:13 GMT Message-Id: <202405232346.44NNkD4m092940@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: 45bce6fa306f - main - LinuxKPI: 802.11: lock MO tx/wake_tx_queue() downcalls List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 45bce6fa306fc3a211949f63c9bbb7932fe5a3bd Auto-Submitted: auto-generated The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=45bce6fa306fc3a211949f63c9bbb7932fe5a3bd commit 45bce6fa306fc3a211949f63c9bbb7932fe5a3bd Author: Bjoern A. Zeeb AuthorDate: 2024-02-18 21:07:08 +0000 Commit: Bjoern A. Zeeb CommitDate: 2024-05-23 23:43:29 +0000 LinuxKPI: 802.11: lock MO tx/wake_tx_queue() downcalls Lock the two TX MO downcalls into driver/firmware in lkpi_80211_txq_tx_one() to make sure they cannot happen in the middle of other (net80211 triggered) updates calling down into the driver/firmware. Sponsored by: The FreeBSD Foundation (commit) MFC after: 3 days Reviewed by: cc Differential Revision: https://reviews.freebsd.org/D43966 --- sys/compat/linuxkpi/common/src/linux_80211.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 72b39e840bfd..03b36e6526bd 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -3769,7 +3769,9 @@ lkpi_80211_txq_tx_one(struct lkpi_sta *lsta, struct mbuf *m) ltxq->txq.tid, ac, skb->priority, skb->qmap); #endif LKPI_80211_LTXQ_UNLOCK(ltxq); + LKPI_80211_LHW_LOCK(lhw); lkpi_80211_mo_wake_tx_queue(hw, <xq->txq); + LKPI_80211_LHW_UNLOCK(lhw); return; ops_tx: @@ -3782,7 +3784,9 @@ ops_tx: #endif memset(&control, 0, sizeof(control)); control.sta = sta; + LKPI_80211_LHW_LOCK(lhw); lkpi_80211_mo_tx(hw, &control, skb); + LKPI_80211_LHW_UNLOCK(lhw); } static void