lsi: Purge message queue on reset
authorJan Kiszka <jan.kiszka@siemens.com>
Tue, 4 May 2010 12:21:01 +0000 (14:21 +0200)
committerAnthony Liguori <aliguori@us.ibm.com>
Mon, 10 May 2010 16:36:03 +0000 (11:36 -0500)
Declare the input message queue empty and initialize the related state
machine properly on controller reset. This fixes unrecoverable errors
when the controller was reset during ongoing requests.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
hw/lsi53c895a.c

index 85eea150c84e8673d0208c9c877d3bb7b92c1b69..61de23ea7e06e57c9b810a0c005f2f58cf4b6d26 100644 (file)
@@ -288,6 +288,8 @@ static void lsi_soft_reset(LSIState *s)
     DPRINTF("Reset\n");
     s->carry = 0;
 
+    s->msg_action = 0;
+    s->msg_len = 0;
     s->waiting = 0;
     s->dsa = 0;
     s->dnad = 0;