mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Omer El Idrissi <omer.e.idrissi@gmail.com>
To: johannes@sipsolutions.net
Cc: linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org,
	Omer El Idrissi <omer.e.idrissi@gmail.com>
Subject: [PATCH 1/2] mac80211: move static function from header to referenced file
Date: Sat, 17 Oct 2026 17:55:08 +0200	[thread overview]
Message-ID: <20261017155509.128114-2-omer.e.idrissi@gmail.com> (raw)
In-Reply-To: <20261017155509.128114-1-omer.e.idrissi@gmail.com>

Move static function from header file to only c file it's used in.

Signed-off-by: Omer El Idrissi <omer.e.idrissi@gmail.com>
---
 net/mac80211/debugfs.c    | 15 +++++++++++++++
 net/mac80211/driver-ops.h | 15 ---------------
 2 files changed, 15 insertions(+), 15 deletions(-)

diff --git a/net/mac80211/debugfs.c b/net/mac80211/debugfs.c
index e38631d7cfb4..cce8aab1dfa6 100644
--- a/net/mac80211/debugfs.c
+++ b/net/mac80211/debugfs.c
@@ -589,6 +589,21 @@ DEBUGFS_READONLY_FILE_OPS(misc);
 
 /* statistics stuff */
 
+static inline int drv_get_stats(struct ieee80211_local *local,
+				struct ieee80211_low_level_stats *stats)
+{
+	int ret = -EOPNOTSUPP;
+
+	might_sleep();
+	lockdep_assert_wiphy(local->hw.wiphy);
+
+	if (local->ops->get_stats)
+		ret = local->ops->get_stats(&local->hw, stats);
+	trace_drv_get_stats(local, stats, ret);
+
+	return ret;
+}
+
 static ssize_t format_devstat_counter(struct ieee80211_local *local,
 	char __user *userbuf,
 	size_t count, loff_t *ppos,
diff --git a/net/mac80211/driver-ops.h b/net/mac80211/driver-ops.h
index f1c0b87fddd5..49654958531d 100644
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -364,21 +364,6 @@ static inline void drv_sw_scan_complete(struct ieee80211_local *local,
 	trace_drv_return_void(local);
 }
 
-static inline int drv_get_stats(struct ieee80211_local *local,
-				struct ieee80211_low_level_stats *stats)
-{
-	int ret = -EOPNOTSUPP;
-
-	might_sleep();
-	lockdep_assert_wiphy(local->hw.wiphy);
-
-	if (local->ops->get_stats)
-		ret = local->ops->get_stats(&local->hw, stats);
-	trace_drv_get_stats(local, stats, ret);
-
-	return ret;
-}
-
 static inline void drv_get_key_seq(struct ieee80211_local *local,
 				   struct ieee80211_key *key,
 				   struct ieee80211_key_seq *seq)
-- 
2.53.0


  reply	other threads:[~2026-10-17 15:55 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-17 15:55 [PATCH 0/2] mac80211: hide tracepoint definition Omer El Idrissi
2026-10-17 15:55 ` Omer El Idrissi [this message]
2026-10-17 15:55 ` [PATCH 2/2] mac80211: hide drv_get_stats tracepoint with ifdef guard Omer El Idrissi
2026-10-24 14:31 ` [PATCH 0/2] mac80211: hide tracepoint definition Omer El Idrissi

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=20261017155509.128114-2-omer.e.idrissi@gmail.com \
    --to=omer.e.idrissi@gmail.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    /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®