Changeset View
Changeset View
Standalone View
Standalone View
contrib/wpa/src/drivers/driver_bsd.c
Show First 20 Lines • Show All 581 Lines • ▼ Show 20 Lines | #endif /* SIOCS80211CHANNEL */ | ||||
if (channel < 14) { | if (channel < 14) { | ||||
mode = | mode = | ||||
freq->ht_enabled ? IFM_IEEE80211_11NG : | freq->ht_enabled ? IFM_IEEE80211_11NG : | ||||
IFM_IEEE80211_11G; | IFM_IEEE80211_11G; | ||||
} else if (channel == 14) { | } else if (channel == 14) { | ||||
mode = IFM_IEEE80211_11B; | mode = IFM_IEEE80211_11B; | ||||
} else { | } else { | ||||
mode = | mode = | ||||
freq->vht_enabled ? IFM_IEEE80211_VHT5G : | |||||
freq->ht_enabled ? IFM_IEEE80211_11NA : | freq->ht_enabled ? IFM_IEEE80211_11NA : | ||||
IFM_IEEE80211_11A; | IFM_IEEE80211_11A; | ||||
} | } | ||||
if (bsd_set_mediaopt(drv, IFM_MMASK, mode) < 0) { | if (bsd_set_mediaopt(drv, IFM_MMASK, mode) < 0) { | ||||
wpa_printf(MSG_ERROR, "%s: failed to set modulation mode", | wpa_printf(MSG_ERROR, "%s: failed to set modulation mode", | ||||
__func__); | __func__); | ||||
return -1; | return -1; | ||||
} | } | ||||
▲ Show 20 Lines • Show All 1,229 Lines • Show Last 20 Lines |