[PATCH -mm 3/6] cpu_relax(): floppy.c wait_til_ready()
From: Andreas Mohr
Date: Wed Jun 21 2006 - 16:59:29 EST
Add cpu_relax() to drivers/block/floppy.c/wait_til_ready()
Should be very useful, methinks.
Tested on 2.6.17-mm1 (load-time only, no floppy media here right now ;).
Signed-off-by: Andreas Mohr <andi@xxxxxxxx>
diff -urN linux-2.6.17-mm1.orig/drivers/block/floppy.c linux-2.6.17-mm1.my/drivers/block/floppy.c
--- linux-2.6.17-mm1.orig/drivers/block/floppy.c 2006-06-21 14:28:16.000000000 +0200
+++ linux-2.6.17-mm1.my/drivers/block/floppy.c 2006-06-21 18:50:37.000000000 +0200
@@ -1155,6 +1155,7 @@
status = fd_inb(FD_STATUS);
if (status & STATUS_READY)
return status;
+ cpu_relax();
}
if (!initialising) {
DPRINT("Getstatus times out (%x) on fdc %d\n", status, fdc);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/