Messages in this thread |  | | From | Mikael Pettersson <> | Date | Tue, 21 May 2002 14:35:24 +0200 | Subject | Re: [RFC] possible fix for broken floppy driver since 2.5.13 |
| |
Christoph Hellwig writes: > On Mon, May 20, 2002 at 07:01:52PM +0200, Mikael Pettersson wrote: > > Since 2.5.13 I've been unable to use drivers/block/floppy.c. > > There were two symptoms: /dev/fd0 was read-only until after > > the first read, and writes wrote currupt data to the media. > > > > The patch below against 2.5.16 fixes these problems for me: > > > > - The read-only problem was caused by a getblk() call in > > floppy_revalidate() which had been commented out (2.5.13 > > did away with getblk() altogether.) This call is necessary, > > so the patch reintroduces a private getblk() in floppy.c. > > Please don't use getblk(), but go directly through the bio interface. > In 2.5 the buffer_heads are just a legacy interface for filesystems and > are not supposed to be used by lowlevel drivers.
I haven't got a clue on how to program Linux' block I/O interfaces. Show me how to do a modern equivalent of getblk(dev,0,1024) + waiting for the operation to complete and I'll update the patch ASAP.
/Mikael - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
|  |