From 4c74f4792c8714f0ed2bb30c2ff19dfe412da71f Mon Sep 17 00:00:00 2001 From: Christian Prochaska Date: Sun, 24 Nov 2019 04:06:31 +0100 Subject: [PATCH] ahci_drv: set 'Cmd::St' to 1 before writing 'Sact' register Issue #3058 --- repos/os/src/drivers/ahci/ata_driver.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/repos/os/src/drivers/ahci/ata_driver.h b/repos/os/src/drivers/ahci/ata_driver.h index b65a77a97..538ee9e4b 100644 --- a/repos/os/src/drivers/ahci/ata_driver.h +++ b/repos/os/src/drivers/ahci/ata_driver.h @@ -138,6 +138,8 @@ struct Ncq_command : Io_command unsigned slot) override { table.fis.fpdma(read, block_number, count, slot); + /* ensure that 'Cmd::St' is 1 before writing 'Sact' */ + port.start(); /* set pending */ port.write(1U << slot); }