All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hannes Reinecke <hare@suse.de>
To: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>,
	Paolo Bonzini <pbonzini@redhat.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] esp-pci: fixup deadlock with linux
Date: Mon, 10 Nov 2014 08:02:03 +0100	[thread overview]
Message-ID: <546062EB.5080409@suse.de> (raw)
In-Reply-To: <545F3794.2010200@ilande.co.uk>

On 11/09/2014 10:44 AM, Mark Cave-Ayland wrote:
> On 07/11/14 12:22, Hannes Reinecke wrote:
> 
>> A linux guest will be issuing messages:
>>
>> [   32.124042] DC390: Deadlock in DataIn_0: DMA aborted unfinished: 000000 bytes remain!!
>> [   32.126348] DC390: DataIn_0: DMA State: 0
>>
>> and the HBA will fail to work properly.
>> Reason is the emulation is not setting the 'DMA transfer done'
>> status correctly.
>>
>> Signed-off-by: Hannes Reinecke <hare@suse.de>
>> ---
>>  hw/scsi/esp-pci.c | 2 ++
>>  1 file changed, 2 insertions(+)
>>
>> diff --git a/hw/scsi/esp-pci.c b/hw/scsi/esp-pci.c
>> index 82795e6..77b8647 100644
>> --- a/hw/scsi/esp-pci.c
>> +++ b/hw/scsi/esp-pci.c
>> @@ -268,6 +268,8 @@ static void esp_pci_dma_memory_rw(PCIESPState *pci, uint8_t *buf, int len,
>>      /* update status registers */
>>      pci->dma_regs[DMA_WBC] -= len;
>>      pci->dma_regs[DMA_WAC] += len;
>> +    if (pci->dma_regs[DMA_WBC] == 0)
>> +        pci->dma_regs[DMA_STAT] |= DMA_STAT_DONE;
>>  }
> 
> Missing braces on the if statement here?
> 
Sigh.

If you insist ...

Cheers,

Hannes
-- 
Dr. Hannes Reinecke		      zSeries & Storage
hare@suse.de			      +49 911 74053 688
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: J. Hawn, J. Guild, F. Imendörffer, HRB 21284 (AG Nürnberg)

  reply	other threads:[~2014-11-10  7:02 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-07 12:22 [Qemu-devel] [PATCH] esp-pci: fixup deadlock with linux Hannes Reinecke
2014-11-07 12:32 ` Paolo Bonzini
2014-11-09  9:44 ` Mark Cave-Ayland
2014-11-10  7:02   ` Hannes Reinecke [this message]
2014-11-10  7:39     ` Gonglei
2014-11-10  7:50       ` Hannes Reinecke
2014-11-10  7:55         ` Gonglei
2014-11-10 10:31     ` Paolo Bonzini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=546062EB.5080409@suse.de \
    --to=hare@suse.de \
    --cc=mark.cave-ayland@ilande.co.uk \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.