- Applied patch from Greg Alexander, 12/22/2000.

Implement aborts on a few SET FEATURE commands for ATA.
This commit is contained in:
Bryce Denney 2001-04-10 02:09:09 +00:00
parent 1f545e43d8
commit b05159c112
1 changed files with 15 additions and 0 deletions

View File

@ -1413,6 +1413,21 @@ bx_hard_drive_c::write(Bit32u address, Bit32u value, unsigned io_len)
} }
break; break;
case 0xef: // set features
switch(BX_SELECTED_CONTROLLER.features) {
case 0x02: // Enable and
case 0x82: // Disable write cache.
case 0xAA: // Enable and
case 0x55: // Disable look-ahead cache.
bx_printf("disk: SET FEATURES subcommand not supported by disk.\n");
command_aborted(value);
break;
default:
bx_panic("disk: SET FEATURES with unknown subcommand: 0x%02x\n", (unsigned) BX_SELECTED_CONTROLLER.features );
}
break;
case 0x40: // case 0x40: //
if (bx_options.newHardDriveSupport) { if (bx_options.newHardDriveSupport) {
if (BX_SELECTED_HD.device_type != IDE_DISK) if (BX_SELECTED_HD.device_type != IDE_DISK)