mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2024-11-25 08:48:31 -05:00
drivers: Document struct wpa_signal_info
Add documentation to the wpa_signal_info structure. Add a define for an invalid noise value. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
This commit is contained in:
parent
381523ecae
commit
941807f6b6
@ -1913,8 +1913,21 @@ enum chan_width {
|
|||||||
CHAN_WIDTH_UNKNOWN
|
CHAN_WIDTH_UNKNOWN
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#define WPA_INVALID_NOISE 9999
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* struct wpa_signal_info - Information about channel signal quality
|
* struct wpa_signal_info - Information about channel signal quality
|
||||||
|
* @frequency: control frequency
|
||||||
|
* @above_threshold: true if the above threshold was crossed
|
||||||
|
* (relevant for a CQM event)
|
||||||
|
* @current_signal: in dBm
|
||||||
|
* @avg_signal: in dBm
|
||||||
|
* @avg_beacon_signal: in dBm
|
||||||
|
* @current_noise: %WPA_INVALID_NOISE if not supported
|
||||||
|
* @current_txrate: current TX rate
|
||||||
|
* @chanwidth: channel width
|
||||||
|
* @center_frq1: center frequency for the first segment
|
||||||
|
* @center_frq2: center frequency for the second segment (if relevant)
|
||||||
*/
|
*/
|
||||||
struct wpa_signal_info {
|
struct wpa_signal_info {
|
||||||
u32 frequency;
|
u32 frequency;
|
||||||
|
@ -1469,7 +1469,7 @@ int nl80211_get_link_signal(struct wpa_driver_nl80211_data *drv,
|
|||||||
{
|
{
|
||||||
struct nl_msg *msg;
|
struct nl_msg *msg;
|
||||||
|
|
||||||
sig->current_signal = -9999;
|
sig->current_signal = -WPA_INVALID_NOISE;
|
||||||
sig->current_txrate = 0;
|
sig->current_txrate = 0;
|
||||||
|
|
||||||
if (!(msg = nl80211_drv_msg(drv, 0, NL80211_CMD_GET_STATION)) ||
|
if (!(msg = nl80211_drv_msg(drv, 0, NL80211_CMD_GET_STATION)) ||
|
||||||
@ -1531,7 +1531,7 @@ int nl80211_get_link_noise(struct wpa_driver_nl80211_data *drv,
|
|||||||
{
|
{
|
||||||
struct nl_msg *msg;
|
struct nl_msg *msg;
|
||||||
|
|
||||||
sig_change->current_noise = 9999;
|
sig_change->current_noise = WPA_INVALID_NOISE;
|
||||||
sig_change->frequency = drv->assoc_freq;
|
sig_change->frequency = drv->assoc_freq;
|
||||||
|
|
||||||
msg = nl80211_drv_msg(drv, NLM_F_DUMP, NL80211_CMD_GET_SURVEY);
|
msg = nl80211_drv_msg(drv, NLM_F_DUMP, NL80211_CMD_GET_SURVEY);
|
||||||
|
@ -2428,8 +2428,8 @@ static int wpa_driver_wext_signal_poll(void *priv, struct wpa_signal_info *si)
|
|||||||
struct iwreq iwr;
|
struct iwreq iwr;
|
||||||
|
|
||||||
os_memset(si, 0, sizeof(*si));
|
os_memset(si, 0, sizeof(*si));
|
||||||
si->current_signal = -9999;
|
si->current_signal = -WPA_INVALID_NOISE;
|
||||||
si->current_noise = 9999;
|
si->current_noise = WPA_INVALID_NOISE;
|
||||||
si->chanwidth = CHAN_WIDTH_UNKNOWN;
|
si->chanwidth = CHAN_WIDTH_UNKNOWN;
|
||||||
|
|
||||||
os_memset(&iwr, 0, sizeof(iwr));
|
os_memset(&iwr, 0, sizeof(iwr));
|
||||||
|
Loading…
Reference in New Issue
Block a user