Jeff Garzik wrote:
Tejun Heo wrote:
+static int ata_boot_probe_wait(void *dummy)
+{
+ schedule();
schedule_timeout(1) is preferred
Can you elaborate? AFAICS, the function is entered in
TASK_UNINTERRUPTIBLE state. No busy looping there. It's called from
wait_on_bit() which takes care of sleep/wakeup conditions.
+ spin_unlock_irqrestore(&ap->host_set->lock, flags);
+
+ wait_on_bit(&ap->flags, bit, ata_boot_probe_wait,
+ TASK_UNINTERRUPTIBLE);
+
+ while (scsi_host_in_recovery(ap->host))
+ msleep(10);
Is this seemingly infinite loop _guaranteed_ to stop eventually?
Yeap. Main thread is woken up after EH completes and EH is guaranteed
to complete.
--
tejun
-
: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html