mac80211: mlme: find auth challenge directly

commit 49a765d6785e99157ff5091cc37485732496864e upstream.

There's no need to parse all elements etc. just to find the
authentication challenge - use cfg80211_find_elem() instead.
This also allows us to remove WLAN_EID_CHALLENGE handling
from the element parsing entirely.

Signed-off-by: Johannes Berg <>
Cc: Felix Fietkau <>
Signed-off-by: Greg Kroah-Hartman <>
3 files changed