staging: r8188eu: always cancel blink_work when WPS failed

Cancel blink_work if WPS fails. Another worker will be scheduled after
the state variables are updated.

Tested-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220905200146.82259-6-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Martin Kaiser 2022-09-05 22:01:44 +02:00 committed by Greg Kroah-Hartman
parent de9c3e9ea9
commit 9b34e23b1f

View File

@ -357,8 +357,8 @@ void rtw_led_control(struct adapter *padapter, enum LED_CTL_MODE LedAction)
}
break;
case LED_CTL_STOP_WPS_FAIL:
cancel_delayed_work(&pLed->blink_work);
if (pLed->bLedWPSBlinkInProgress) {
cancel_delayed_work(&pLed->blink_work);
pLed->bLedWPSBlinkInProgress = false;
}
pLed->bLedNoLinkBlinkInProgress = true;