mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Priit Laes <plaes@plaes.org>
Cc: Priit Laes <plaes@plaes.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Michael Straube <straube.linux@gmail.com>,
	linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: [PATCH 09/11] staging: rtl8273bs: Reduce useless function wrapping in regulator code
Date: Fri, 20 Feb 2026 18:15:20 +0200	[thread overview]
Message-ID: <20260220161611.2398915-10-plaes@plaes.org> (raw)
In-Reply-To: <20260220161611.2398915-1-plaes@plaes.org>

Signed-off-by: Priit Laes <plaes@plaes.org>
---
 drivers/staging/rtl8723bs/os_dep/wifi_regd.c | 27 +++-----------------
 1 file changed, 4 insertions(+), 23 deletions(-)

diff --git a/drivers/staging/rtl8723bs/os_dep/wifi_regd.c b/drivers/staging/rtl8723bs/os_dep/wifi_regd.c
index f9c4d487badf..878a2ee08d25 100644
--- a/drivers/staging/rtl8723bs/os_dep/wifi_regd.c
+++ b/drivers/staging/rtl8723bs/os_dep/wifi_regd.c
@@ -91,40 +91,21 @@ static int _rtw_reg_notifier_apply(struct wiphy *wiphy,
 	return 0;
 }
 
-static const struct ieee80211_regdomain *_rtw_regdomain_select(struct
-							       rtw_regulatory
-							       *reg)
-{
-	return &rtw_regdom_rd;
-}
-
-static void _rtw_regd_init_wiphy(struct rtw_regulatory *reg,
-				 struct wiphy *wiphy,
-				 void (*reg_notifier)(struct wiphy *wiphy,
-						      struct
-						      regulatory_request *
-						      request))
+void rtw_regd_init(struct wiphy *wiphy,
+		   void (*reg_notifier)(struct wiphy *wiphy,
+					struct regulatory_request *request))
 {
-	const struct ieee80211_regdomain *regd;
-
 	wiphy->reg_notifier = reg_notifier;
 
 	wiphy->regulatory_flags |= REGULATORY_CUSTOM_REG;
 	wiphy->regulatory_flags &= ~REGULATORY_STRICT_REG;
 	wiphy->regulatory_flags &= ~REGULATORY_DISABLE_BEACON_HINTS;
 
-	regd = _rtw_regdomain_select(reg);
-	wiphy_apply_custom_regulatory(wiphy, regd);
+	wiphy_apply_custom_regulatory(wiphy, &rtw_regdom_rd);
 
 	/* Hard code flags */
 	_rtw_reg_apply_flags(wiphy);
-}
 
-void rtw_regd_init(struct wiphy *wiphy,
-		   void (*reg_notifier)(struct wiphy *wiphy,
-					struct regulatory_request *request))
-{
-	_rtw_regd_init_wiphy(NULL, wiphy, reg_notifier);
 }
 
 void rtw_reg_notifier(struct wiphy *wiphy, struct regulatory_request *request)
-- 
2.53.0


  parent reply	other threads:[~2026-02-20 16:17 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20260220161611.2398915-1-plaes@plaes.org>
2026-02-20 16:15 ` [PATCH 01/11] staging: stl8723bs: Use common round_up macro Priit Laes
2026-02-20 16:15 ` [PATCH 02/11] staging: rtl8723bs: Remove unused BIT32..BIT36 definitions Priit Laes
2026-02-20 16:15 ` [PATCH 03/11] staging: rtl8723bs: Drop empty rtw_bug_check function Priit Laes
2026-02-20 16:15 ` [PATCH 04/11] staging: rtl8723bs: Remove unused rtw_sprintf macro Priit Laes
2026-02-20 16:15 ` [PATCH 05/11] staging: rtl8723bs: Drop unused _kfree(...) declaration Priit Laes
2026-02-20 16:15 ` [PATCH 06/11] staging: rtl8723bs: Get rid of unused _rtw_init_queue Priit Laes
2026-02-20 16:15 ` [PATCH 07/11] staging: rtl8723bs: Drop unused NDEV-related formatting macros Priit Laes
2026-02-20 16:15 ` [PATCH 08/11] staging: rtl8723bs: Drop workqueue wrapper functions Priit Laes
2026-02-20 16:15 ` Priit Laes [this message]
2026-02-20 16:15 ` [PATCH 10/11] staging: rtl8723bs: Remove useless wrapper functions in rtw_cmd.c Priit Laes
2026-02-20 18:42   ` Ethan Tidmore
2026-02-20 17:29 ` [PATCH 11/11] staging: rtl8723bs: rtw_ieee80211: Reduce global symbols Priit Laes
2026-02-20 23:50   ` kernel test robot
2026-02-21  1:25   ` kernel test robot
2026-02-21  9:47   ` Dan Carpenter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260220161611.2398915-10-plaes@plaes.org \
    --to=plaes@plaes.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-staging@lists.linux.dev \
    --cc=straube.linux@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®