* Second patch to turn off floppy motor(s)
@ 2003-10-07 13:33 Richard B. Johnson
0 siblings, 0 replies; only message in thread
From: Richard B. Johnson @ 2003-10-07 13:33 UTC (permalink / raw)
To: Linux kernel
For anyone interested.. This has already been discussed-to-death.
--- linux-2.4.22/arch/i386/boot/bootsect.S.orig Tue Oct 7 08:47:06 2003
+++ linux-2.4.22/arch/i386/boot/bootsect.S Tue Oct 7 09:23:35 2003
@@ -396,15 +396,10 @@
# NOTE: Doesn't save %ax or %dx; do it yourself if you need to.
kill_motor:
-#if 1
- xorw %ax, %ax # reset FDC
- xorb %dl, %dl
- int $0x13
-#else
movw $0x3f2, %dx
- xorb %al, %al
- outb %al, %dx
-#endif
+ inb %dx, %al # Get R/W bits
+ andb $0x0f, %al # Save all but motor-on bits
+ outb %al, %dx # Shut off motor
ret
sectors: .word 0
Cheers,
Dick Johnson
Penguin : Linux version 2.4.22 on an i686 machine (797.90 BogoMips).
Note 96.31% of all statistics are fiction.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2003-10-07 13:34 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-10-07 13:33 Second patch to turn off floppy motor(s) Richard B. Johnson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®