aboutsummaryrefslogtreecommitdiff
path: root/net/mac80211/driver-trace.h
diff options
context:
space:
mode:
authorVictor Goldenshtein <victorg@ti.com>2012-06-21 10:56:46 +0300
committerJohannes Berg <johannes.berg@intel.com>2012-06-21 16:42:17 +0200
commit66572cfc30a4b764150c83ee5d842a3ce17991c9 (patch)
tree3b344b9c986b55f77b4652fd46ce2dad9138ea31 /net/mac80211/driver-trace.h
parent0f6b3f597daab2254614e2773e322e73fb1b6f4b (diff)
mac80211: add command to get current rssi
Get current rssi (in dBm) from the driver/FW. Instead of reporting the signal received in the last rx packet, which might be inaccurate if rx traffic is low and beacon filtering is enabled, get the signal from the driver/FW. Signed-off-by: Victor Goldenshtein <victorg@ti.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/driver-trace.h')
-rw-r--r--net/mac80211/driver-trace.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/net/mac80211/driver-trace.h b/net/mac80211/driver-trace.h
index 6de00b2c268..a0f7d357884 100644
--- a/net/mac80211/driver-trace.h
+++ b/net/mac80211/driver-trace.h
@@ -1218,6 +1218,32 @@ DEFINE_EVENT(release_evt, drv_allow_buffered_frames,
TP_ARGS(local, sta, tids, num_frames, reason, more_data)
);
+TRACE_EVENT(drv_get_rssi,
+ TP_PROTO(struct ieee80211_local *local, struct ieee80211_sta *sta,
+ s8 rssi, int ret),
+
+ TP_ARGS(local, sta, rssi, ret),
+
+ TP_STRUCT__entry(
+ LOCAL_ENTRY
+ STA_ENTRY
+ __field(s8, rssi)
+ __field(int, ret)
+ ),
+
+ TP_fast_assign(
+ LOCAL_ASSIGN;
+ STA_ASSIGN;
+ __entry->rssi = rssi;
+ __entry->ret = ret;
+ ),
+
+ TP_printk(
+ LOCAL_PR_FMT STA_PR_FMT " rssi:%d ret:%d",
+ LOCAL_PR_ARG, STA_PR_ARG, __entry->rssi, __entry->ret
+ )
+);
+
/*
* Tracing for API calls that drivers call.
*/