VirtualBox

Changeset 95389 in vbox for trunk/src/VBox/Devices/Storage


Ignore:
Timestamp:
Jun 27, 2022 11:55:57 AM (3 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
151984
Message:

DevFDC: Logging (make more readable) and made fd_formats const.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Storage/DevFdc.cpp

    r95058 r95389  
    243243
    244244    if (!drv->last_sect) {
    245         FLOPPY_DPRINTF("no disk in drive (max=%d %d %02x %02x)\n",
    246                        1, (drv->flags & FDISK_DBL_SIDES) == 0 ? 0 : 1,
    247                        drv->max_track, drv->last_sect);
     245        FLOPPY_DPRINTF("no disk in drive (max=%d h=%d c=%02x =s%02x) -> 5\n",
     246                       1, NUM_SIDES(drv) - 1, drv->max_track, drv->last_sect);
    248247        return 5;
    249248    }
    250249    if (track > drv->max_track ||
    251250        (head != 0 && (drv->flags & FDISK_DBL_SIDES) == 0)) {
    252         FLOPPY_DPRINTF("try to read %d %02x %02x (max=%d %d %02x %02x)\n",
    253                        head, track, sect, 1,
    254                        (drv->flags & FDISK_DBL_SIDES) == 0 ? 0 : 1,
    255                        drv->max_track, drv->last_sect);
     251        FLOPPY_DPRINTF("try to read h=%d c=%02x s=%02x (max=%d h=%d c=%02x s=%02x) -> 2\n",
     252                       head, track, sect,
     253                       1, NUM_SIDES(drv) - 1, drv->max_track, drv->last_sect);
    256254        return 2;
    257255    }
    258256    if (sect > drv->last_sect || sect < 1) {
    259         FLOPPY_DPRINTF("try to read %d %02x %02x (max=%d %d %02x %02x)\n",
    260                        head, track, sect, 1,
    261                        (drv->flags & FDISK_DBL_SIDES) == 0 ? 0 : 1,
    262                        drv->max_track, drv->last_sect);
     257        FLOPPY_DPRINTF("try to read h=%d c=%02x s=%02x (max=%d h=%d c=%02x s=%02x) -> 3\n",
     258                       head, track, sect,
     259                       1, NUM_SIDES(drv) - 1, drv->max_track, drv->last_sect);
    263260        return 3;
    264261    }
     
    309306 * in 40-track drives, but 300 Kbps in high-capacity 80-track drives.
    310307 */
    311 static fd_format_t fd_formats[] = {
     308static fd_format_t const fd_formats[] = {
    312309    /* First entry is default format */
    313310    /* 1.44 MB 3"1/2 floppy disks */
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette