On 26/9/26 09:44, Mark Cave-Ayland wrote:
Since its original implementation the disk DMA callback pmac_ide_transfer_cb()
accidentally made use of the CDROM DMA read callback 
pmac_ide_atapi_transfer_cb()
for disk DMA reads instead of itself.

Fixes: be1e343995e ("macio: switch over to new byte-aligned DMA helpers")
Signed-off-by: Mark Cave-Ayland <[email protected]>
---
  hw/ide/macio.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/ide/macio.c b/hw/ide/macio.c
index 40fb4f3b4f3..a95e68083f4 100644
--- a/hw/ide/macio.c
+++ b/hw/ide/macio.c
@@ -180,7 +180,7 @@ static void pmac_ide_transfer_cb(void *opaque, int ret)
      switch (s->dma_cmd) {
      case IDE_DMA_READ:
          s->bus->dma->aiocb = dma_blk_read(s->blk, &s->sg, offset, 0x1,
-                                          pmac_ide_atapi_transfer_cb, io);
+                                          pmac_ide_transfer_cb, io);

Copy/paste error?

Reviewed-by: Philippe Mathieu-Daudé <[email protected]>


Reply via email to