urtwn(4): add DBM_ANTNOISE radiotap field
Reviewed by: kevlo Approved by: adrian (mentor) Differential Revision: https://reviews.freebsd.org/D3839
This commit is contained in:
parent
6ce548a105
commit
74ee6e03d0
@ -666,6 +666,7 @@ urtwn_rx_frame(struct urtwn_softc *sc, uint8_t *buf, int pktlen, int *rssi_p)
|
||||
tap->wr_rate = 0x80 | (rate - 12);
|
||||
}
|
||||
tap->wr_dbm_antsignal = rssi;
|
||||
tap->wr_dbm_antnoise = URTWN_NOISE_FLOOR;
|
||||
tap->wr_chan_freq = htole16(ic->ic_curchan->ic_freq);
|
||||
tap->wr_chan_flags = htole16(ic->ic_curchan->ic_flags);
|
||||
}
|
||||
|
@ -37,14 +37,16 @@ struct urtwn_rx_radiotap_header {
|
||||
uint8_t wr_rate;
|
||||
uint16_t wr_chan_freq;
|
||||
uint16_t wr_chan_flags;
|
||||
uint8_t wr_dbm_antsignal;
|
||||
int8_t wr_dbm_antsignal;
|
||||
int8_t wr_dbm_antnoise;
|
||||
} __packed __aligned(8);
|
||||
|
||||
#define URTWN_RX_RADIOTAP_PRESENT \
|
||||
(1 << IEEE80211_RADIOTAP_FLAGS | \
|
||||
1 << IEEE80211_RADIOTAP_RATE | \
|
||||
1 << IEEE80211_RADIOTAP_CHANNEL | \
|
||||
1 << IEEE80211_RADIOTAP_DBM_ANTSIGNAL)
|
||||
1 << IEEE80211_RADIOTAP_DBM_ANTSIGNAL | \
|
||||
1 << IEEE80211_RADIOTAP_DBM_ANTNOISE)
|
||||
|
||||
struct urtwn_tx_radiotap_header {
|
||||
struct ieee80211_radiotap_header wt_ihdr;
|
||||
|
Loading…
Reference in New Issue
Block a user