From e8f0413e3961c2477821854171224050a603a270 Mon Sep 17 00:00:00 2001 From: Travis Geiselbrecht Date: Mon, 24 Jan 2022 00:25:11 -0800 Subject: [PATCH] WIP ahci --- dev/block/ahci/ahci.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dev/block/ahci/ahci.cpp b/dev/block/ahci/ahci.cpp index d0bb0e49..ae92c41b 100644 --- a/dev/block/ahci/ahci.cpp +++ b/dev/block/ahci/ahci.cpp @@ -45,7 +45,7 @@ status_t ahci::init_device(pci_location_t loc) { LTRACEF("ahci BARS:\n"); if (LOCAL_TRACE) pci_dump_bars(bars, 6); - if (!bars[5].valid) { + if (!bars[5].valid || !bars[5].addr) { return ERR_NOT_FOUND; } @@ -82,7 +82,7 @@ status_t ahci::init_device(pci_location_t loc) { // fall back to regular IRQs err = pci_bus_mgr_allocate_irq(loc_, &irq_base); if (err != NO_ERROR) { - printf("e1000: unable to allocate IRQ\n"); + printf("ahci: unable to allocate IRQ\n"); return err; } register_int_handler(irq_base, irq_handler_wrapper, this);