|
@@ -558,8 +558,6 @@ struct mac80211_hwsim_data {
|
|
|
/* wmediumd portid responsible for netgroup of this radio */
|
|
|
u32 wmediumd;
|
|
|
|
|
|
- int power_level;
|
|
|
-
|
|
|
/* difference between this hw's clock and the real clock, in usecs */
|
|
|
s64 tsf_offset;
|
|
|
s64 bcn_delta;
|
|
@@ -1207,7 +1205,9 @@ static bool mac80211_hwsim_tx_frame_no_nl(struct ieee80211_hw *hw,
|
|
|
if (info->control.rates[0].flags & IEEE80211_TX_RC_SHORT_GI)
|
|
|
rx_status.flag |= RX_FLAG_SHORT_GI;
|
|
|
/* TODO: simulate real signal strength (and optional packet loss) */
|
|
|
- rx_status.signal = data->power_level - 50;
|
|
|
+ rx_status.signal = -50;
|
|
|
+ if (info->control.vif)
|
|
|
+ rx_status.signal += info->control.vif->bss_conf.txpower;
|
|
|
|
|
|
if (data->ps != PS_DISABLED)
|
|
|
hdr->frame_control |= cpu_to_le16(IEEE80211_FCTL_PM);
|
|
@@ -1633,7 +1633,6 @@ static int mac80211_hwsim_config(struct ieee80211_hw *hw, u32 changed)
|
|
|
}
|
|
|
mutex_unlock(&data->mutex);
|
|
|
|
|
|
- data->power_level = conf->power_level;
|
|
|
if (!data->started || !data->beacon_int)
|
|
|
tasklet_hrtimer_cancel(&data->beacon_timer);
|
|
|
else if (!hrtimer_is_queued(&data->beacon_timer.timer)) {
|
|
@@ -2253,7 +2252,6 @@ static const char mac80211_hwsim_gstrings_stats[][ETH_GSTRING_LEN] = {
|
|
|
"d_tx_failed",
|
|
|
"d_ps_mode",
|
|
|
"d_group",
|
|
|
- "d_tx_power",
|
|
|
};
|
|
|
|
|
|
#define MAC80211_HWSIM_SSTATS_LEN ARRAY_SIZE(mac80211_hwsim_gstrings_stats)
|
|
@@ -2290,7 +2288,6 @@ static void mac80211_hwsim_get_et_stats(struct ieee80211_hw *hw,
|
|
|
data[i++] = ar->tx_failed;
|
|
|
data[i++] = ar->ps;
|
|
|
data[i++] = ar->group;
|
|
|
- data[i++] = ar->power_level;
|
|
|
|
|
|
WARN_ON(i != MAC80211_HWSIM_SSTATS_LEN);
|
|
|
}
|