Message ID | 20190809063835.6717-3-ppandit@redhat.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | scsi: lsi: break infinite loop after 10k instructions | expand |
diff --git a/hw/scsi/lsi53c895a.c b/hw/scsi/lsi53c895a.c index e703ef4c9d..f6786607f8 100644 --- a/hw/scsi/lsi53c895a.c +++ b/hw/scsi/lsi53c895a.c @@ -1578,7 +1578,7 @@ again: } } } - if (insn_processed > 10000 && s->waiting == LSI_NOWAIT) { + if (insn_processed > LSI_MAX_INSN && s->waiting == LSI_NOWAIT) { /* Some windows drivers make the device spin waiting for a memory location to change. If we have been executed a lot of code then assume this is the case and force an unexpected device disconnect.