Commit ffa3183a1c for qemu.org

commit ffa3183a1c8af8dad0d1c4260762bfdd9aa5e8e9
Author: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
Date:   Fri Nov 20 18:12:33 2026 +0100

    hw/scsi/ncr53c710: Document the SIGP latch deviation

    Comment only, no functional change.  The data manual describes SIGP
    (ISTAT bit 5) as a read/write flag that stays set until reset by the
    CPU, either through ISTAT or by reading CTEST2.  The emulation drops
    the bit at once when it is set while the engine is halted and
    remembers the kick in sigp_pending_resume instead.  Note the
    deviation at the code.  The reason is not documented in the history.

    AI-used-for: Patch series decomposition (commit splitting and ordering)
    Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
    Signed-off-by: Helge Deller <deller@gmx.de>

diff --git a/hw/scsi/ncr53c710.c b/hw/scsi/ncr53c710.c
index 4b1853a391..a161912727 100644
--- a/hw/scsi/ncr53c710.c
+++ b/hw/scsi/ncr53c710.c
@@ -1533,6 +1533,14 @@ static void lsi_reg_writeb(NCR710State *s, int offset, uint8_t val)
              * Reselect consumption would, without disturbing the pending
              * completion.  Remember the kick so the next command is selected
              * once the engine parks again at Wait Reselect.
+             *
+             * This deviates from the data manual, which describes SIGP as a
+             * read/write flag that stays set until the CPU resets it, either
+             * via ISTAT or by reading CTEST2: here a halted engine drops the
+             * bit at once, so a read of ISTAT or CTEST2 no longer sees it.
+             * The reason is not documented beyond the commit that added
+             * sigp_pending_resume (6bf09c62fa), which only says that a kick
+             * on a stopped engine is held and replayed once the engine parks.
              */
             s->istat &= ~LSI_ISTAT0_SIGP;
             s->sigp_pending_resume = true;