Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 90738683 authored by Tejun Heo's avatar Tejun Heo Committed by Jeff Garzik
Browse files

libata: wrap schedule_timeout_uninterruptible() in loop



Tasks in uninterruptible sleep might be woken up by unrelated events
and should check whether the condition it was waiting for has actually
triggered.  Wrap schedule_timeout_uninterruptible() in loop to achieve
it.

Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
Signed-off-by: default avatarJeff Garzik <jeff@garzik.org>
parent 94ff3d54
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -2183,7 +2183,8 @@ int ata_eh_reset(struct ata_link *link, int classify,
				"(errno=%d), retrying in %u secs\n",
				rc, (jiffies_to_msecs(delta) + 999) / 1000);

			schedule_timeout_uninterruptible(delta);
			while (delta)
				delta = schedule_timeout_uninterruptible(delta);
		}

		if (rc == -EPIPE ||