diff mbox

[for-2.7] atapi: fix halted DMA reset

Message ID 1470164128-28158-1-git-send-email-jsnow@redhat.com
State New
Headers show

Commit Message

John Snow Aug. 2, 2016, 6:55 p.m. UTC
Followup to 87ac25fd, this time for ATAPI DMA.

Reported-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: John Snow <jsnow@redhat.com>
---
 hw/ide/atapi.c | 1 +
 1 file changed, 1 insertion(+)

Comments

John Snow Aug. 4, 2016, 6:29 p.m. UTC | #1
On 08/02/2016 02:55 PM, John Snow wrote:
> Followup to 87ac25fd, this time for ATAPI DMA.
>
> Reported-by: Paolo Bonzini <pbonzini@redhat.com>
> Signed-off-by: John Snow <jsnow@redhat.com>
> ---
>  hw/ide/atapi.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/hw/ide/atapi.c b/hw/ide/atapi.c
> index 95056d9..6189675 100644
> --- a/hw/ide/atapi.c
> +++ b/hw/ide/atapi.c
> @@ -386,6 +386,7 @@ static void ide_atapi_cmd_read_dma_cb(void *opaque, int ret)
>      if (ret < 0) {
>          if (ide_handle_rw_error(s, -ret, ide_dma_cmd_to_retry(s->dma_cmd))) {
>              if (s->bus->error_status) {
> +                s->bus->dma->aiocb = NULL;
>                  return;
>              }
>              goto eot;
>

I extracted an ACK out of Paolo offline, so I have staged this patch.

Thanks, applied to my IDE tree:

https://github.com/jnsnow/qemu/commits/ide
https://github.com/jnsnow/qemu.git

--js
diff mbox

Patch

diff --git a/hw/ide/atapi.c b/hw/ide/atapi.c
index 95056d9..6189675 100644
--- a/hw/ide/atapi.c
+++ b/hw/ide/atapi.c
@@ -386,6 +386,7 @@  static void ide_atapi_cmd_read_dma_cb(void *opaque, int ret)
     if (ret < 0) {
         if (ide_handle_rw_error(s, -ret, ide_dma_cmd_to_retry(s->dma_cmd))) {
             if (s->bus->error_status) {
+                s->bus->dma->aiocb = NULL;
                 return;
             }
             goto eot;