Linux 5.15 To Fix Regression In Its Floppy Disk Driver

Since the changes to the floppy disk driver earlier in the year, the driver has continued to function but it silently and unintentionally altered some of the floppy disk handling code -- previously the kernel with the O_NDELAY flag would allow opening a floppy device even without a disk being inserted. The updated Linux kernel would yield an error if opening a floppy device without the media/disk inserted. Additionally, it broke opening up of floppy disks that are write-protected.
While the Linux 5.15 merge window is likely opening tonight if the release of Linux 5.14 goes through, queued today as a late addition to block-next is the floppy disk driver fix. The fix though for these regressions is just reverting the earlier patch around O_NDELAY in the floppy code. This revert and handling is of the same nature as a regression to the Linux floppy disk driver back in 2016 that also lasted for several months until being noticed and addressed.
The floppy patch earlier this year was originally merged for Linux 5.12 but also back-ported to prior stable series, including Linux 5.10 LTS, so this new patch for 5.15 will also likely end up being back-ported to stable/LTS kernels as well.
The floppy pull for Linux 5.15 to the block subsystem can be found via this PR. Given actual floppy disk usage among kernel developers is incredibly rare these days, developer Denis Efremov is also working on adding self-tests to the floppy driver to prevent this user-space breakage from happening again in the future.
17 Comments