staging: rtl8723bs: Remove yield call, replace with cond_resched()
authorThomas Avery <tavery321@gmail.com>
Wed, 28 Mar 2018 22:26:34 +0000 (18:26 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 Mar 2018 10:00:15 +0000 (12:00 +0200)
Remove yield() call. Yield does not guarantee progress, cond_resched()
is a safer alternative

Signed-off-by: Thomas Avery <tavery321@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8723bs/core/rtw_pwrctrl.c

index 4a6af72013faad5c6fa3a1f99b88e300af8444f9..85f7769ecc2dfeee1e243ed01f3efec3162dadec 100644 (file)
@@ -701,7 +701,7 @@ void LPS_Leave_check(
        bReady = false;
        start_time = jiffies;
 
-       yield();
+       cond_resched();
 
        while (1) {
                down(&pwrpriv->lock);