From nobody Wed Jan 18 16:24:59 2023 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 4NxrhD2PsPz2yJ1d; Wed, 18 Jan 2023 16:25:00 +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 4NxrhC6ydrz3FCr; Wed, 18 Jan 2023 16:24:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674059100; 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=dmxB06OSkEEONIFB2KLcDXd8m8rCx3IF6TQiqUvtmZs=; b=VSWrTAb7Sf47YaA1lKbL3GooIYplT8nmd6zmsCdnREtIHAoMXNyXRT1D+TtDxEdRw62D9s oQbd4gvkgqFE48klQznhhJ35u9b/6gXA6QnjSZXJUZqunyGkJJF1ECviI4jiy5UbTZz7oo fFa3MkOQ0qyvrHmshLSqOq1ceDJa1j4N6HJmnkqmA9B60JGdzDJP6fFXxKLaqvjhCQl21j 3ofJOEd0ejcZwvN4pvpAIRuZgUkHB4CGr6sUmAXpU392v/++VgSebpfvnWp7V58Vvxe92a FPq2PEqRaCbWV7V75G+wAhkRUPVO6AxDUUfv9O2TcRZ2D0o6MEPOMJEH2qKaAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674059100; 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=dmxB06OSkEEONIFB2KLcDXd8m8rCx3IF6TQiqUvtmZs=; b=t4s6Dwot/2VS8PeYWG5zn5LWZt/ybF/llgpP0eIO7Kba6kjoPOB//Taa81oxB0Tj7eCytv Y7gUVX4Uc09fr16Fx3Ynu9TWDadn+h0pkZxg8eEy0Xs6yeyRVN/GeIbhjSxt7QAEnDzJJ1 UWTeOyJtDFyLg5iqSGz05LoUYFZv2Vkpj1BV+FoAuNit+JMmpKyagrsgPauHC0atFhV8qz Wex3QWJjwyKNEYXQySAz+63At+fYcS6bTcJ5G/6l1QqU/CqlO9e19F5y0WpzJ5QvWzsyvJ GeaJjcEI/ZI13nTRvVrQenNhneR1xO/m/FxFOY0CGd/CUcCiI1dzIftRAZH5ZA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1674059100; a=rsa-sha256; cv=none; b=mGFaWxR2c82t12gp6IIQcEJvwtJUmNuw4T3U1XdRK2I2bIykmnq3QiLgYWhOXF7EPsHLMP 4i6XmG8Ui3oaFJ6At1FQQ6pXE+Cu6ls5OJuRlO4w9+3osyWPeP8M8GE6Na9KAYTIPT6Ktd 9gOhG4y3+fftU07DFdaivW97Yoe8zF2y2UaqihN/8txQLsONML5D9VDS5Gd9Z5MWJZGhpp rn46HwEOZdiGK1IEtTT1zNbZneLzD2voWBZghqoUUG5XsoktJw7/rxjmJCfF6QpGNmZ6Fx C9HmhtpBw7kIkKqXWfoNOFEbEqDxmb4bLd16GEApF6pdQJT6jGAFICMIpmEAIg== 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 4NxrhC63HvzJ3d; Wed, 18 Jan 2023 16:24:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 30IGOxGM038172; Wed, 18 Jan 2023 16:24:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 30IGOx7J038171; Wed, 18 Jan 2023 16:24:59 GMT (envelope-from git) Date: Wed, 18 Jan 2023 16:24:59 GMT Message-Id: <202301181624.30IGOx7J038171@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: 43f7ed9d85ac - stable/13 - LinuxKPI: 802.11: move ieee80211_{unregister,restart}_hw out of header 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: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 43f7ed9d85ac42a1e9e412694b6baaa64dd966b5 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=43f7ed9d85ac42a1e9e412694b6baaa64dd966b5 commit 43f7ed9d85ac42a1e9e412694b6baaa64dd966b5 Author: Bjoern A. Zeeb AuthorDate: 2022-12-31 02:24:23 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-01-18 13:26:13 +0000 LinuxKPI: 802.11: move ieee80211_{unregister,restart}_hw out of header Migrate the two functions from the header into the implementation file in order to have access to more facilities and not to run into possible allocation/locking/... problems in the future. Sponsored by: The FreeBSD Foundation (cherry picked from commit 4b0af114370a5cb876012c381d3156c8fbdf7f40) --- sys/compat/linuxkpi/common/include/net/mac80211.h | 22 +++++++++++----------- sys/compat/linuxkpi/common/src/linux_80211.c | 17 +++++++++++++++++ 2 files changed, 28 insertions(+), 11 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/net/mac80211.h b/sys/compat/linuxkpi/common/include/net/mac80211.h index 22b00726a727..230d42947e7b 100644 --- a/sys/compat/linuxkpi/common/include/net/mac80211.h +++ b/sys/compat/linuxkpi/common/include/net/mac80211.h @@ -980,7 +980,9 @@ void linuxkpi_ieee80211_iffree(struct ieee80211_hw *); void linuxkpi_set_ieee80211_dev(struct ieee80211_hw *, char *); int linuxkpi_ieee80211_ifattach(struct ieee80211_hw *); void linuxkpi_ieee80211_ifdetach(struct ieee80211_hw *); +void linuxkpi_ieee80211_unregister_hw(struct ieee80211_hw *); struct ieee80211_hw * linuxkpi_wiphy_to_ieee80211_hw(struct wiphy *); +void linuxkpi_ieee80211_restart_hw(struct ieee80211_hw *); void linuxkpi_ieee80211_iterate_interfaces( struct ieee80211_hw *hw, enum ieee80211_iface_iter flags, void(*iterfunc)(void *, uint8_t *, struct ieee80211_vif *), @@ -1110,14 +1112,11 @@ ieee80211_register_hw(struct ieee80211_hw *hw) return (error); } -static __inline void +static inline void ieee80211_unregister_hw(struct ieee80211_hw *hw) { - wiphy_unregister(hw->wiphy); - linuxkpi_ieee80211_ifdetach(hw); - - IMPROVE(); + linuxkpi_ieee80211_unregister_hw(hw); } static __inline struct ieee80211_hw * @@ -1127,6 +1126,13 @@ wiphy_to_ieee80211_hw(struct wiphy *wiphy) return (linuxkpi_wiphy_to_ieee80211_hw(wiphy)); } +static inline void +ieee80211_restart_hw(struct ieee80211_hw *hw) +{ + linuxkpi_ieee80211_restart_hw(hw); +} + + /* -------------------------------------------------------------------------- */ static __inline bool @@ -1830,12 +1836,6 @@ ieee80211_free_txskb(struct ieee80211_hw *hw, struct sk_buff *skb) linuxkpi_ieee80211_free_txskb(hw, skb, 0x455458); } -static __inline void -ieee80211_restart_hw(struct ieee80211_hw *hw) -{ - TODO(); -} - static __inline void ieee80211_ready_on_channel(struct ieee80211_hw *hw) { diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 170f6162cd6b..ee4b58e60f4d 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2345,6 +2345,23 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], return (vap); } +void +linuxkpi_ieee80211_unregister_hw(struct ieee80211_hw *hw) +{ + + wiphy_unregister(hw->wiphy); + linuxkpi_ieee80211_ifdetach(hw); + + IMPROVE(); +} + +void +linuxkpi_ieee80211_restart_hw(struct ieee80211_hw *hw) +{ + + TODO(); +} + static void lkpi_ic_vap_delete(struct ieee80211vap *vap) {