)]}'
{
  "commit": "f93d9a49f7f1e6a90d1831fc415424d38681ea4e",
  "tree": "83bcf61de0add6eb1e5f8ad46dab6afe58869e15",
  "parents": [
    "23fe62fb97450725094e60b54a023c2fdb0d40e0"
  ],
  "author": {
    "name": "Christian Quante",
    "email": "christian@quante.one",
    "time": "Tue Jul 14 18:41:51 2026 +0200"
  },
  "committer": {
    "name": "Kevin O\u0027Connor",
    "email": "kevin@koconnor.net",
    "time": "Wed Jul 22 13:17:11 2026 -0400"
  },
  "message": "floppy: report an empty drive as not ready\n\nAn empty drive and an unreadable diskette are different failures, and\nuntil the previous patch SeaBIOS could not tell them apart: both ended up\nin floppy_media_sense() exhausting the data rates and returning\nDISK_RET_EMEDIA (0xC0).  Now that the disk change line identifies an absent\nmedium, report it as DISK_RET_ETIMEOUT (0x80), which the INT 13h tables\ngive as \"time out, drive not ready\".  floppy_media_sense() keeps\nDISK_RET_EMEDIA for a medium it cannot read.\n\nKevin O\u0027Connor traced where 0xC0 came from: Bochs BIOS answers 0x0C here,\n\"media type not found\", and the value was transposed when the code was\nbrought over at the initial checkin f076a3ee.  Ralf Brown\u0027s interrupt list\ngives 0x0C as \"unsupported track or invalid media\" -- so 0xC0 has never\nbeen an INT 13h status code at all.  It does not appear in the classic\ntables, and guests treat it accordingly.\n\nMeasured on an empty drive, with SeaBIOS patched to return each code in\nturn.  The guests here are German-language, so their messages are quoted as\nthey appear, with the English sense in brackets:\n\n  PC-DOS 7, \"dir a:\"\n    0x80  \"Nicht bereit beim Lesen von Laufwerk A\"\n          [not ready reading drive A]\n    0xC0  \"Allgemeiner Fehler beim Lesen von Laufwerk A\"\n          [general failure reading drive A]\n    0xAA  same message as 0xC0\n    0x99  same message as 0xC0                 \u003c- invented, not a real code\n    0x06  no message at all; DOS retries forever\n\n  Windows for Workgroups 3.11, File Manager, drive A:\n    0x80  \"In Laufwerk A ist kein Datenträger eingelegt.  Legen Sie einen\n           Datenträger ein, und versuchen Sie es erneut.\"  [Wiederholen]\n          [there is no disk in drive A; insert one and try again]\n    0xC0  \"Der Datenträger in Laufwerk A ist nicht formatiert.  Möchten\n           Sie, daß der Datenträger jetzt formatiert wird?\"  [Ja] [Nein]\n          [the disk in drive A is not formatted; format it now?]\n\nDOS gives 0xC0 the same message as the invented code 0x99, which is to say\nit does not recognise it.  Windows does recognise it, and offers to format\na diskette that is not there.  Both are correct with 0x80.\n\nOS/2 2.11 and Linux are unaffected: both drive the controller through their\nown drivers rather than INT 13h.\n\nNot verified against real hardware -- I have none with a floppy drive.\n\nSigned-off-by: Christian Quante \u003cchristian@quante.one\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "0469a791695204fcd031a706726a37c92c0ebcf6",
      "old_mode": 33188,
      "old_path": "src/hw/floppy.c",
      "new_id": "ebed54f10400b4d16aa22e0c634c329543ae2d88",
      "new_mode": 33188,
      "new_path": "src/hw/floppy.c"
    }
  ]
}
