mirror of
https://github.com/holub/mame
synced 2025-06-16 17:29:27 +03:00
Merge pull request #6604 from davide125/eject
nscsi/cd: handle eject command for SGI drives
This commit is contained in:
commit
b25fdfbe46
@ -604,13 +604,23 @@ enum sgi_scsi_command_e : uint8_t {
|
|||||||
* in the kernel runs, if there are SCSI problems.
|
* in the kernel runs, if there are SCSI problems.
|
||||||
*/
|
*/
|
||||||
SGI_HD2CDROM = 0xc9,
|
SGI_HD2CDROM = 0xc9,
|
||||||
|
/*
|
||||||
|
* IRIX 5.3 sends this command when it wants to eject the drive
|
||||||
|
*/
|
||||||
|
SGI_EJECT = 0xc4,
|
||||||
};
|
};
|
||||||
|
|
||||||
void nscsi_cdrom_sgi_device::scsi_command()
|
void nscsi_cdrom_sgi_device::scsi_command()
|
||||||
{
|
{
|
||||||
switch (scsi_cmdbuf[0]) {
|
switch (scsi_cmdbuf[0]) {
|
||||||
case SGI_HD2CDROM:
|
case SGI_HD2CDROM:
|
||||||
LOG("command SGI_HD2CDROM");
|
LOG("command SGI_HD2CDROM\n");
|
||||||
|
// No need to do anything (yet). Just acknowledge the command.
|
||||||
|
scsi_status_complete(SS_GOOD);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case SGI_EJECT:
|
||||||
|
LOG("command SGI_EJECT\n");
|
||||||
// No need to do anything (yet). Just acknowledge the command.
|
// No need to do anything (yet). Just acknowledge the command.
|
||||||
scsi_status_complete(SS_GOOD);
|
scsi_status_complete(SS_GOOD);
|
||||||
break;
|
break;
|
||||||
@ -627,6 +637,9 @@ bool nscsi_cdrom_sgi_device::scsi_command_done(uint8_t command, uint8_t length)
|
|||||||
case SGI_HD2CDROM:
|
case SGI_HD2CDROM:
|
||||||
return length == 10;
|
return length == 10;
|
||||||
|
|
||||||
|
case SGI_EJECT:
|
||||||
|
return length == 10;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return nscsi_full_device::scsi_command_done(command, length);
|
return nscsi_full_device::scsi_command_done(command, length);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user