[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 69/88] esp.c: consolidate end of command sequence after ICCS comma
From: |
Mark Cave-Ayland |
Subject: |
[PULL 69/88] esp.c: consolidate end of command sequence after ICCS command |
Date: |
Tue, 13 Feb 2024 19:40:33 +0000 |
The end of command sequences for the ICCS command are currently different
between the DMA and non-DMA versions, and also different from the description
in the datasheet.
Update the sequence so that only INTR_FC is asserted in both cases, and keep
all the logic in esp_do_dma() and esp_do_nodma() rather than having some of
it within esp_run_cmd().
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Tested-by: Helge Deller <deller@gmx.de>
Tested-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20240112125420.514425-70-mark.cave-ayland@ilande.co.uk>
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
---
hw/scsi/esp.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/hw/scsi/esp.c b/hw/scsi/esp.c
index 824ebe9ff0..6c62417985 100644
--- a/hw/scsi/esp.c
+++ b/hw/scsi/esp.c
@@ -650,8 +650,7 @@ static void esp_do_dma(ESPState *s)
}
/* Raise end of command interrupt */
- s->rregs[ESP_RINTR] |= INTR_BS | INTR_FC;
- s->rregs[ESP_RSEQ] = SEQ_CD;
+ s->rregs[ESP_RINTR] |= INTR_FC;
esp_raise_irq(s);
}
break;
@@ -825,6 +824,8 @@ static void esp_do_nodma(ESPState *s)
case CMD_ICCS:
fifo8_push(&s->fifo, 0);
+ /* Raise end of command interrupt */
+ s->rregs[ESP_RINTR] |= INTR_FC;
esp_raise_irq(s);
break;
}
@@ -1056,8 +1057,6 @@ static void esp_run_cmd(ESPState *s)
case CMD_ICCS:
trace_esp_mem_writeb_cmd_iccs(cmd);
write_response(s);
- s->rregs[ESP_RINTR] |= INTR_FC;
- esp_set_phase(s, STAT_MI);
break;
case CMD_MSGACC:
trace_esp_mem_writeb_cmd_msgacc(cmd);
--
2.39.2
- [PULL 37/88] esp.c: introduce esp_get_phase() function, (continued)
- [PULL 37/88] esp.c: introduce esp_get_phase() function, Mark Cave-Ayland, 2024/02/13
- [PULL 41/88] esp.c: convert esp_do_dma() do_cmd path to check for SCSI phase instead, Mark Cave-Ayland, 2024/02/13
- [PULL 43/88] esp.c: convert esp_do_nodma() do_cmd path to check for SCSI phase instead, Mark Cave-Ayland, 2024/02/13
- [PULL 44/88] esp.c: convert esp_reg_write() do_cmd path to check for SCSI phase instead, Mark Cave-Ayland, 2024/02/13
- [PULL 48/88] esp.c: untangle MESSAGE OUT and COMMAND phase logic in esp_do_nodma(), Mark Cave-Ayland, 2024/02/13
- [PULL 45/88] esp.c: remove do_cmd from ESPState, Mark Cave-Ayland, 2024/02/13
- [PULL 42/88] esp.c: convert do_dma_pdma_cb() do_cmd path to check for SCSI phase instead, Mark Cave-Ayland, 2024/02/13
- [PULL 49/88] esp.c: move CMD_SELATN end of message phase detection to esp_do_dma() and do_dma_pdma_cb(), Mark Cave-Ayland, 2024/02/13
- [PULL 46/88] esp.c: untangle MESSAGE OUT and COMMAND phase logic in esp_do_dma(), Mark Cave-Ayland, 2024/02/13
- [PULL 47/88] esp.c: untangle MESSAGE OUT and COMMAND phase logic in do_dma_pdma_cb(), Mark Cave-Ayland, 2024/02/13
- [PULL 69/88] esp.c: consolidate end of command sequence after ICCS command,
Mark Cave-Ayland <=
- [PULL 70/88] esp.c: ensure that STAT_INT is cleared when reading ESP_RINTR, Mark Cave-Ayland, 2024/02/13
- [PULL 81/88] esp.c: remove redundant n variable in PDMA COMMAND phase, Mark Cave-Ayland, 2024/02/13
- [PULL 78/88] esp.c: consolidate DMA and PDMA logic in DATA OUT phase, Mark Cave-Ayland, 2024/02/13
- [PULL 64/88] esp.c: don't raise INTR_BS interrupt in DATA IN phase until TI command issued, Mark Cave-Ayland, 2024/02/13
- [PULL 51/88] esp.c: don't use get_cmd() for CMD_SEL DMA commands, Mark Cave-Ayland, 2024/02/13
- [PULL 57/88] esp.c: rename data_in_ready to to data_ready, Mark Cave-Ayland, 2024/02/13
- [PULL 79/88] esp.c: consolidate DMA and PDMA logic in DATA IN phase, Mark Cave-Ayland, 2024/02/13
- [PULL 71/88] esp.c: don't clear the SCSI phase when reading ESP_RINTR, Mark Cave-Ayland, 2024/02/13
- [PULL 65/88] esp.c: move non-DMA TI logic to separate esp_nodma_ti_dataout() function, Mark Cave-Ayland, 2024/02/13
- [PULL 73/88] esp.c: remove restriction on FIFO read access when DMA memory routines defined, Mark Cave-Ayland, 2024/02/13