fixed mametesters 05318 [smf]

This commit is contained in:
smf- 2013-10-02 00:17:45 +00:00
parent 8a686cebfe
commit e6b70f4373
2 changed files with 14 additions and 1 deletions

View File

@ -52,6 +52,7 @@ ata_hle_device::ata_hle_device(const machine_config &mconfig, device_type type,
m_status(0),
m_command(0),
m_device_control(0),
m_revert_to_defaults(true),
m_csel(0),
m_daspin(0),
m_daspout(0),
@ -87,6 +88,7 @@ void ata_hle_device::device_start()
save_item(NAME(m_status));
save_item(NAME(m_command));
save_item(NAME(m_device_control));
save_item(NAME(m_revert_to_defaults));
save_item(NAME(m_single_device));
save_item(NAME(m_resetting));
@ -285,6 +287,14 @@ bool ata_hle_device::set_features()
return set_dma_mode(88);
}
break;
case IDE_SET_FEATURES_DISABLE_REVERTING_TO_POWER_ON_DEFAULTS:
m_revert_to_defaults = false;
return true;
case IDE_SET_FEATURES_ENABLE_REVERTING_TO_POWER_ON_DEFAULTS:
m_revert_to_defaults = true;
return true;
}
return false;

View File

@ -131,7 +131,9 @@ protected:
enum
{
IDE_SET_FEATURES_TRANSFER_MODE = 0x03
IDE_SET_FEATURES_TRANSFER_MODE = 0x03,
IDE_SET_FEATURES_DISABLE_REVERTING_TO_POWER_ON_DEFAULTS = 0x66,
IDE_SET_FEATURES_ENABLE_REVERTING_TO_POWER_ON_DEFAULTS = 0xcc
};
enum ide_transfer_type_t
@ -183,6 +185,7 @@ protected:
UINT8 m_device_control;
UINT16 m_identify_buffer[256];
bool m_revert_to_defaults;
private:
void update_irq();