]> git.ipfire.org Git - thirdparty/qemu.git/commit
hw/scsi/lsi53c895a: stop script on phase mismatch
authorSven Schnelle <svens@stackframe.org>
Sat, 2 Mar 2024 21:44:53 +0000 (22:44 +0100)
committerMichael Tokarev <mjt@tls.msk.ru>
Sun, 10 Mar 2024 09:29:44 +0000 (12:29 +0300)
commit37a8b9205f1a6fef0893d5b5c62178ea2a6bfde3
tree821d5142db86ccbbaa4f0c13a08dbd6d4bb52cb1
parent5dc46b3ff8d178a3498b6ad8b42ee8f93681e0e8
hw/scsi/lsi53c895a: stop script on phase mismatch

Netbsd isn't happy with qemu lsi53c895a emulation:

cd0(esiop0:0:2:0): command with tag id 0 reset
esiop0: autoconfiguration error: phase mismatch without command
esiop0: autoconfiguration error: unhandled scsi interrupt, sist=0x80 sstat1=0x0 DSA=0x23a64b1 DSP=0x50

This is because lsi_bad_phase() triggers a phase mismatch, which
stops SCRIPT processing. However, after returning to
lsi_command_complete(), SCRIPT is restarted with lsi_resume_script().
Fix this by adding a return value to lsi_bad_phase(), and only resume
script processing when lsi_bad_phase() didn't trigger a host interrupt.

Signed-off-by: Sven Schnelle <svens@stackframe.org>
Tested-by: Helge Deller <deller@gmx.de>
Message-ID: <20240302214453.2071388-1-svens@stackframe.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
(cherry picked from commit a9198b3132d81a6bfc9fdbf6f3d3a514c2864674)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
hw/scsi/lsi53c895a.c