]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
staging: lustre: Remove yield() call
authorThomas Avery <tavery321@gmail.com>
Mon, 5 Mar 2018 19:33:49 +0000 (14:33 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 6 Mar 2018 12:22:17 +0000 (04:22 -0800)
Remove yield() call. In this case it's use is considered broken, since
it is being assumed that yield() will let another process run that will
make the event true.

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

index 997c0f9aafb5505c5ae6699448844b4c70292c2f..277576b586dbc3abb1f1f4456954de54598ec00f 100644 (file)
@@ -455,7 +455,7 @@ static int class_cleanup(struct obd_device *obd, struct lustre_cfg *lcfg)
        spin_unlock(&obd->obd_dev_lock);
 
        while (obd->obd_conn_inprogress > 0)
-               yield();
+               cond_resched();
        smp_rmb();
 
        if (lcfg->lcfg_bufcount >= 2 && LUSTRE_CFG_BUFLEN(lcfg, 1) > 0) {