ide-cd: start DMA before sending the actual packet command
as it is done for all other IDE ATAPI devices.
There should be no functionality change resulting from this patch.
Signed-off-by: Borislav Petkov <petkovbb@gmail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c
index 1c1ba43..2cb301d 100644
--- a/drivers/ide/ide-cd.c
+++ b/drivers/ide/ide-cd.c
@@ -593,13 +593,13 @@
if (cmd_len < ATAPI_MIN_CDB_BYTES)
cmd_len = ATAPI_MIN_CDB_BYTES;
- /* send the command to the device */
- hwif->tp_ops->output_data(drive, NULL, rq->cmd, cmd_len);
-
/* start the DMA if need be */
if (drive->dma)
hwif->dma_ops->dma_start(drive);
+ /* send the command to the device */
+ hwif->tp_ops->output_data(drive, NULL, rq->cmd, cmd_len);
+
return ide_started;
}