aboutsummaryrefslogtreecommitdiff
path: root/include/hw/scsi
diff options
context:
space:
mode:
authorMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>2021-03-04 22:10:54 +0000
committerMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>2021-03-07 10:39:05 +0000
commit4e78f3bf357e0ef2f67e372097f2be8fe0521814 (patch)
tree6da0b82ffb14348e67f566bc6d8fc993789e7142 /include/hw/scsi
parentcf47a41e055f6f90a2cecdb9eb3c4cebfde23f2a (diff)
esp: defer command completion interrupt on incoming data transfers
The MacOS toolbox ROM issues a command to the ESP controller as part of its "FAST" SCSI routines and then proceeds to read the incoming data soon after receiving the command completion interrupt. Unfortunately due to SCSI block transfers being asynchronous the incoming data may not yet be present causing an underflow error. Resolve this by waiting for the SCSI subsystem transfer_data callback before raising the command completion interrupt. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Reviewed-by: Laurent Vivier <laurent@vivier.eu> Message-Id: <20210304221103.6369-34-mark.cave-ayland@ilande.co.uk>
Diffstat (limited to 'include/hw/scsi')
-rw-r--r--include/hw/scsi/esp.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/hw/scsi/esp.h b/include/hw/scsi/esp.h
index 91f8ffd6c8..61bc317a4c 100644
--- a/include/hw/scsi/esp.h
+++ b/include/hw/scsi/esp.h
@@ -41,6 +41,7 @@ struct ESPState {
uint32_t cmdlen;
uint32_t do_cmd;
+ bool data_in_ready;
int dma_enabled;
uint32_t async_len;