[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCHv2] macio: handle non-block ATAPI DMA transfers t
From: |
Aurelien Jarno |
Subject: |
Re: [Qemu-devel] [PATCHv2] macio: handle non-block ATAPI DMA transfers the same as block DMA transfers |
Date: |
Mon, 17 Aug 2015 22:39:05 +0200 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
On 2015-08-13 23:03, Mark Cave-Ayland wrote:
> On 01/08/15 19:33, Aurelien Jarno wrote:
>
> > On 2015-08-01 17:54, Mark Cave-Ayland wrote:
> >> The existing code incorrectly changes the dma_active flag when a non-block
> >> transfer has completed leading to a hang on newer versions of Linux
> >> because the
> >> IDE and DMA engines deadlock waiting for each other.
> >>
> >> Instead copy the buffer directly to RAM, set the remaining transfer size
> >> to 0 and
> >> then invoke the ATAPI callback manually once again to correctly finish the
> >> transfer in an identical manner to a block transfer.
> >>
> >> Signed-off-by: Mark Cave-Ayland <address@hidden>
> >> ---
[snip]
> For some reason pmac_ide_dma_end() was being called without an active
> DMA request and so the RUN bit was clear on entry which was causing the
> error flag to be set. Given that this doesn't occur on lenny and wheezy,
> I'm inclined to believe that this is a bug in the squeeze kernel.
>
> Anyhow if this survives your testing then I'll repost as 2 separate
> patches with a CC to qemu-stable so that this also gets picked up in the
> next 2.4 release.
Thanks for working on that. I don't feel I have enough knowledge of this
part of QEMU to review the patch, that said, I have been able to test
it and I confirm it fixes the issue.
Reviewed-by: Aurelien Jarno <address@hidden>
--
Aurelien Jarno GPG: 4096R/1DDD8C9B
address@hidden http://www.aurel32.net