From: Eric Dumazet Date: Thu, 3 Mar 2022 23:19:33 +0000 (-0800) Subject: md: use msleep() in md_notify_reboot() X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=7d959f6e978cbbca90e26a192cc39480e977182f;p=linux.git md: use msleep() in md_notify_reboot() Calling mdelay(1000) from process context, even while a reboot is in progress, does not make sense. Using msleep() allows other threads to make progress. Signed-off-by: Eric Dumazet Cc: linux-raid@vger.kernel.org Signed-off-by: Song Liu --- diff --git a/drivers/md/md.c b/drivers/md/md.c index f88a9e948f3eb..d059e21f3c356 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -9582,7 +9582,7 @@ static int md_notify_reboot(struct notifier_block *this, * driver, we do want to have a safe RAID driver ... */ if (need_delay) - mdelay(1000*1); + msleep(1000); return NOTIFY_DONE; }