diff --git a/src/drivers/driver.h b/src/drivers/driver.h index a3602ed78..78dcc2503 100644 --- a/src/drivers/driver.h +++ b/src/drivers/driver.h @@ -910,6 +910,8 @@ struct wpa_driver_capa { #define WPA_DRIVER_FLAGS_RADAR 0x10000000 /* Driver supports a dedicated interface for P2P Device */ #define WPA_DRIVER_FLAGS_DEDICATED_P2P_DEVICE 0x20000000 +/* Driver supports QoS Mapping */ +#define WPA_DRIVER_FLAGS_QOS_MAPPING 0x40000000 unsigned int flags; int max_scan_ssids; diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c index 67f7366e7..12f688a8b 100644 --- a/src/drivers/driver_nl80211.c +++ b/src/drivers/driver_nl80211.c @@ -3105,6 +3105,7 @@ struct wiphy_info_data { unsigned int p2p_client_supported:1; unsigned int p2p_concurrent:1; unsigned int channel_switch_supported:1; + unsigned int set_qos_map_supported:1; }; @@ -3265,6 +3266,9 @@ static void wiphy_info_supp_cmds(struct wiphy_info_data *info, case NL80211_CMD_CHANNEL_SWITCH: info->channel_switch_supported = 1; break; + case NL80211_CMD_SET_QOS_MAP: + info->set_qos_map_supported = 1; + break; } } } @@ -3527,6 +3531,8 @@ static int wpa_driver_nl80211_capa(struct wpa_driver_nl80211_data *drv) drv->poll_command_supported = info.poll_command_supported; drv->data_tx_status = info.data_tx_status; drv->channel_switch_supported = info.channel_switch_supported; + if (info.set_qos_map_supported) + drv->capa.flags |= WPA_DRIVER_FLAGS_QOS_MAPPING; /* * If poll command and tx status are supported, mac80211 is new enough diff --git a/wpa_supplicant/wpa_supplicant.c b/wpa_supplicant/wpa_supplicant.c index 2d6272b1c..6f1137a8f 100644 --- a/wpa_supplicant/wpa_supplicant.c +++ b/wpa_supplicant/wpa_supplicant.c @@ -1229,7 +1229,8 @@ static void wpas_ext_capab_byte(struct wpa_supplicant *wpa_s, u8 *pos, int idx) break; case 4: /* Bits 32-39 */ #ifdef CONFIG_INTERWORKING - *pos |= 0x01; /* Bit 32 - QoS Map */ + if (wpa_s->drv_flags / WPA_DRIVER_FLAGS_QOS_MAPPING) + *pos |= 0x01; /* Bit 32 - QoS Map */ #endif /* CONFIG_INTERWORKING */ break; case 5: /* Bits 40-47 */