From 511db105a98de550d1e3482577fb7bc90c112bac Mon Sep 17 00:00:00 2001 From: Abdur-Rahman Mansoor Date: Mon, 5 Aug 2024 17:22:53 -0400 Subject: [PATCH] fix: reduce timeout value and initialize ACQ and ASQ addresses properly --- drivers/nvme/nvme.asm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/nvme/nvme.asm b/drivers/nvme/nvme.asm index ec84093..2a5412a 100644 --- a/drivers/nvme/nvme.asm +++ b/drivers/nvme/nvme.asm @@ -784,6 +784,7 @@ proc nvme_init stdcall, pci:dword mov eax, dword [edi + NVM_QUEUE_ENTRY.cq_ptr] invoke GetPhysAddr mov dword [esi + NVME_MMIO.ACQ], eax + mov dword [esi + NVME_MMIO.ACQ + 4], 0 if __DEBUG__ push esi mov esi, [pci] @@ -795,6 +796,7 @@ proc nvme_init stdcall, pci:dword mov eax, dword [edi + NVM_QUEUE_ENTRY.sq_ptr] invoke GetPhysAddr mov dword [esi + NVME_MMIO.ASQ], eax + mov dword [esi + NVME_MMIO.ASQ + 4], 0 if __DEBUG__ push esi mov esi, [pci] @@ -1049,7 +1051,7 @@ proc nvme_poll stdcall, pci:dword @@: inc ecx - cmp ecx, 0xffffffff + cmp ecx, 0x10000000 je @f xor eax, eax inc eax