2.5.33-bk testing
Quoted 10 lines · Linus Torvalds
Quoted 8 lines · Mikael Pettersson
The patch below is an update of the floppy workarounds patch I've been maintaining since the problems began in 2.5.13. With this patch I'm able to reliably read and write to the raw
/dev/fd0device. I'm not suggesting that my hack tobdev->bd_block_sizeis the correct fix, but maybe someone who understands the block I/O system can see what's going on and do a proper fix.
Quoted 4 lines
It looks like what your fix does is to force a 512-byte blocksize on the floppy.
Which implies to me that the floppy driver is broken for other blocksizes.
I did not test other block sizes. I just tested with the hardsect size and noticed that that combo worked.
Quoted 4 lines
Does your patch still leave the floppy driver broken for something like a mounted minix or ext2 filesystem? Those have 1kB blocksizes, and will set it to that. If the non-512B blocksize in the floppy driver is broken, then such mounted filesystems should not work reliably either.
In kernels 2.5.13--2.5.32, it was always the case that with my hack, a mounted ext2 would seem to work for a while and then break down, e.g. when unmounted and fsck:d. I haven't checked 2.5.33.
Also, attempts to put lilo on ext2 on /dev/fd0 would throw the kernel into an infinite stream of "buffer layer error!" from buffer.c:__find_get_block_slow().
/Mikael
Quoted 4 lines · Mikael Pettersson
In kernels 2.5.13--2.5.32, it was always the case that with my hack, a mounted ext2 would seem to work for a while and then break down, e.g. when unmounted and fsck:d. I haven't checked 2.5.33.
Ok, that seems to clinch it - that definitely means that the floppy driver is confused by non-512-byte buffers. And that in turn is almost certainly due to some subtle bug in the bio rework.
The only bug I really fixed in 2.5.33 was completely unrelated, and had to do with the setup for the block open() routine not setting up the request queue - which caused problems for the media change logic.
Linus