mirror of
https://github.com/86Box/86Box.git
synced 2025-01-23 09:42:47 -05:00
WIN_WRITE_MULTIPLE now correctly fails with command aborted if ide->blocksize = 0, instead of a fatal().
This commit is contained in:
parent
42cb69fd66
commit
a064918133
1 changed files with 8 additions and 3 deletions
|
@ -1682,8 +1682,7 @@ ide_writeb(uint16_t addr, uint8_t val, void *priv)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
case WIN_WRITE_MULTIPLE:
|
case WIN_WRITE_MULTIPLE:
|
||||||
if (!ide->blocksize && (ide->type != IDE_ATAPI))
|
/* Fatal removed for the same reason as for WIN_READ_MULTIPLE. */
|
||||||
fatal("Write_MULTIPLE - blocksize = 0\n");
|
|
||||||
ide->blockcount = 0;
|
ide->blockcount = 0;
|
||||||
/* Turn on the activity indicator *here* so that it gets turned on
|
/* Turn on the activity indicator *here* so that it gets turned on
|
||||||
less times. */
|
less times. */
|
||||||
|
@ -2410,7 +2409,13 @@ ide_callback(void *priv)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
case WIN_WRITE_MULTIPLE:
|
case WIN_WRITE_MULTIPLE:
|
||||||
if (ide->type == IDE_ATAPI)
|
/* According to the official ATA reference:
|
||||||
|
|
||||||
|
If the Read Multiple command is attempted before the Set Multiple Mode
|
||||||
|
command has been executed or when Read Multiple commands are
|
||||||
|
disabled, the Read Multiple operation is rejected with an Aborted Com-
|
||||||
|
mand error. */
|
||||||
|
if ((ide->type == IDE_ATAPI) || !ide->blocksize)
|
||||||
goto abort_cmd;
|
goto abort_cmd;
|
||||||
if (!ide->lba && (ide->cfg_spt == 0))
|
if (!ide->lba && (ide->cfg_spt == 0))
|
||||||
goto id_not_found;
|
goto id_not_found;
|
||||||
|
|
Loading…
Add table
Reference in a new issue