diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index c10295138eb5c64fca5c6321ada8e0e1195b3530..13997c954249b73c61354bf1c6679a15da604b23 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -3815,7 +3815,8 @@ int cfg80211_check_station_change(struct wiphy *wiphy, { if (params->listen_interval != -1) return -EINVAL; - if (params->aid) + if (params->aid && + !(params->sta_flags_set & BIT(NL80211_STA_FLAG_TDLS_PEER))) return -EINVAL; /* When you run into this, adjust the code below for the new flag */