Linux 6.2 fixes memory leaks on floppy drives

A memory leak can make part of the main memory unusable on Linux systems with kernel 5.11 or later – namely when the call to floppy_alloc_disk() fails with floppy disk drives. Next February, two years after this bug was introduced, it will be fixed with Linux kernel 6.2.

To this glad tidings Phoronix alert. Linux 5.17 this year corrected a bug that would cause the software to crash if the user removed a broken floppy disk while the computer was still trying to read it.

With kernel 5.18, however, the end of a function was heralded: since then, direct access (raw access) to diskettes has been deactivated by default. The reason is an associated security problem (use-after-free). Instead of eliminating it, access was simply denied. That doesn’t matter for 3.5-inch floppy disks in the most commonly used “high density” format of 1440 kilobytes. As a rule, they are not addressed via raw access anyway, but through the mediation of a controller.

Direct access is only required if the controller does not know a diskette format. This is the case, for example, with floppy disks not formatted according to any public standard, or when dealing with old formats, think Mac or Amiga disks with double density. Anyone who still has data treasures to be found there should hurry: The Raw Access can still be reactivated manually, but it is officially considered deprecated (obsolete). It should disappear from current Linux kernels in the foreseeable future.

Floppy disks have been around for over 50 years. Officially, IBM launched the first floppy disk in 1971 to reduce the need to send magnetic tapes around the world. The company developed the first 8-inch floppy disks, which initially could store 80 Kbytes. Over time, the magnetic memories became smaller (5.25 and 3.5 inches) and could store more data (up to 2880 KB, for Sinclair QL even up to 3200 KB).

They are still used today, especially in the 3.5-inch format with 1440 KB formatting. In Japan, more than 1,000 legal norms prescribe floppy disks for administrative procedures and internal administrative file runs. This floppy disk compulsion annoys Japan’s Digital Minister Taro Kono. “Where do you even buy floppy disks these days?” Kono asked in August. Kono-san and anyone else who is looking for disk supplies may find the hot price comparison tool useful as a guide.


(ds)

To home page

source site