aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/cfg80211.h
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2013-04-22 10:29:30 -0400
committerJohannes Berg <johannes.berg@intel.com>2013-05-16 16:39:37 -0400
commit119363c7dc2bcc0c33c255a7b4979c8c0fdc1896 (patch)
tree85c7eb2b9104968d017eee14065a2d93ce0150a7 /include/net/cfg80211.h
parentf722406faae2d073cc1d01063d1123c35425939e (diff)
cfg80211: add support for per-chain signal strength reporting
Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'include/net/cfg80211.h')
-rw-r--r--include/net/cfg80211.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index 26b5b692c22b..87f7e1d060ab 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -753,6 +753,8 @@ int cfg80211_check_station_change(struct wiphy *wiphy,
753 * @STATION_INFO_LOCAL_PM: @local_pm filled 753 * @STATION_INFO_LOCAL_PM: @local_pm filled
754 * @STATION_INFO_PEER_PM: @peer_pm filled 754 * @STATION_INFO_PEER_PM: @peer_pm filled
755 * @STATION_INFO_NONPEER_PM: @nonpeer_pm filled 755 * @STATION_INFO_NONPEER_PM: @nonpeer_pm filled
756 * @STATION_INFO_CHAIN_SIGNAL: @chain_signal filled
757 * @STATION_INFO_CHAIN_SIGNAL_AVG: @chain_signal_avg filled
756 */ 758 */
757enum station_info_flags { 759enum station_info_flags {
758 STATION_INFO_INACTIVE_TIME = 1<<0, 760 STATION_INFO_INACTIVE_TIME = 1<<0,
@@ -781,6 +783,8 @@ enum station_info_flags {
781 STATION_INFO_NONPEER_PM = 1<<23, 783 STATION_INFO_NONPEER_PM = 1<<23,
782 STATION_INFO_RX_BYTES64 = 1<<24, 784 STATION_INFO_RX_BYTES64 = 1<<24,
783 STATION_INFO_TX_BYTES64 = 1<<25, 785 STATION_INFO_TX_BYTES64 = 1<<25,
786 STATION_INFO_CHAIN_SIGNAL = 1<<26,
787 STATION_INFO_CHAIN_SIGNAL_AVG = 1<<27,
784}; 788};
785 789
786/** 790/**
@@ -857,6 +861,8 @@ struct sta_bss_parameters {
857 u16 beacon_interval; 861 u16 beacon_interval;
858}; 862};
859 863
864#define IEEE80211_MAX_CHAINS 4
865
860/** 866/**
861 * struct station_info - station information 867 * struct station_info - station information
862 * 868 *
@@ -874,6 +880,9 @@ struct sta_bss_parameters {
874 * For CFG80211_SIGNAL_TYPE_MBM, value is expressed in _dBm_. 880 * For CFG80211_SIGNAL_TYPE_MBM, value is expressed in _dBm_.
875 * @signal_avg: Average signal strength, type depends on the wiphy's signal_type. 881 * @signal_avg: Average signal strength, type depends on the wiphy's signal_type.
876 * For CFG80211_SIGNAL_TYPE_MBM, value is expressed in _dBm_. 882 * For CFG80211_SIGNAL_TYPE_MBM, value is expressed in _dBm_.
883 * @chains: bitmask for filled values in @chain_signal, @chain_signal_avg
884 * @chain_signal: per-chain signal strength of last received packet in dBm
885 * @chain_signal_avg: per-chain signal strength average in dBm
877 * @txrate: current unicast bitrate from this station 886 * @txrate: current unicast bitrate from this station
878 * @rxrate: current unicast bitrate to this station 887 * @rxrate: current unicast bitrate to this station
879 * @rx_packets: packets received from this station 888 * @rx_packets: packets received from this station
@@ -909,6 +918,11 @@ struct station_info {
909 u8 plink_state; 918 u8 plink_state;
910 s8 signal; 919 s8 signal;
911 s8 signal_avg; 920 s8 signal_avg;
921
922 u8 chains;
923 s8 chain_signal[IEEE80211_MAX_CHAINS];
924 s8 chain_signal_avg[IEEE80211_MAX_CHAINS];
925
912 struct rate_info txrate; 926 struct rate_info txrate;
913 struct rate_info rxrate; 927 struct rate_info rxrate;
914 u32 rx_packets; 928 u32 rx_packets;