• Sergey Matyukevich's avatar
    qtnfmac: fix invalid STA state on EAPOL failure · 480daa9c
    Sergey Matyukevich authored
    Driver switches vif sta_state into QTNF_STA_CONNECTING when cfg80211
    core initiates connect procedure. Further this state is changed either
    to QTNF_STA_CONNECTED or to QTNF_STA_DISCONNECTED by BSS_JOIN and
    BSS_LEAVE events from firmware. However it is possible that no such
    events will be sent by firmware, e.g. if EAPOL timed out.
    
    In this case vif sta_mode will remain in QTNF_STA_CONNECTING state and
    all subsequent connection attempts will fail with -EBUSY error code.
    Fix this by perfroming STA state transition from QTNF_STA_CONNECTING
    to QTNF_STA_DISCONNECTED in cfg80211 disconnect callback.
    No need to rely upon firmware events in this case.
    Signed-off-by: default avatarSergey Matyukevich <sergey.matyukevich.os@quantenna.com>
    Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
    480daa9c
cfg80211.c 27.9 KB