[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 1/1] hw/ide/core.c: fix handling of unsupported commands
From: |
Mateusz Albecki |
Subject: |
[PATCH 1/1] hw/ide/core.c: fix handling of unsupported commands |
Date: |
Mon, 17 Apr 2023 00:28:38 +0200 |
From: Mateusz Albecki <mateusz.albecki@outlook.com>
Current code will not call ide_cmd_done when aborting the unsupported
command which will lead to the command timeout on the driver side instead
of getting a D2H FIS with ABRT indication. This can lead to problems on the
driver side as the spec mandates that device should return a D2H FIS with
ABRT bit set in ERR register(from SATA 3.1 section 16.3.3.8.6)
Signed-off-by: Mateusz Albecki <mateusz.p.albecki@gmail.com>
---
hw/ide/core.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/ide/core.c b/hw/ide/core.c
index 45d14a25e9..d7027bbd4d 100644
--- a/hw/ide/core.c
+++ b/hw/ide/core.c
@@ -2146,6 +2146,7 @@ void ide_bus_exec_cmd(IDEBus *bus, uint32_t val)
if (!ide_cmd_permitted(s, val)) {
ide_abort_command(s);
+ ide_cmd_done(s);
ide_bus_set_irq(s->bus);
return;
}
--
2.40.0