Who framed the floppy driver?

Marco Mariani (m.mariani@imola.nettuno.it)
Wed, 10 Sep 1997 17:54:26 +0000


Hi all!

I'm having troubles mounting /dev/fd0 from C.

Is this meant to happen?

(running the program as root)

floppy_mount (title=0x804e50a "mount") at sc_floppy.c:117
117 if (mount ("/dev/fd0","/mnt","vfat",0,NULL) == -1) {
(gdb) s
121 retval = 1;
(gdb) p errno
$1 = 22 '\026'
(gdb)

(22 = EINVAL)
>From this point, until I reboot, the floppy driver is quite useless:

shalott:~# mdir
Can't open /dev/fd0: Device or resource busy
Cannot initialize 'A:'
shalott:~# lsmod
Module: #pages: Used by:
floppy 11 1 (autoclean)
shalott:~# rmmod floppy
floppy: Device or resource busy
shalott:~# fuser /dev/fd0*
shalott:~#

Who is using floppy.o ?
Why is the mount call invalid ?
Why is the driver dead?

This happens on both 2.0.30 and 2.0.31-9.