diff options
author | Jesse Buhagiar <jesse.buhagiar@student.rmit.edu.au> | 2019-11-01 14:30:10 +1100 |
---|---|---|
committer | Andreas Kling <awesomekling@gmail.com> | 2019-11-04 15:15:48 +0100 |
commit | 6c1a549057d56b1771efc6aa89e264e9b8c41976 (patch) | |
tree | 5ae8fc0f5b9b5d1da7110ee7a6bab6d29d3a4ce7 | |
parent | 1b2ef8582cfa33eb3f0d605dc5cf67bf6a05a017 (diff) | |
download | serenity-6c1a549057d56b1771efc6aa89e264e9b8c41976.zip |
PATAChannel: Alert user when no PCI device is found
This helps aid debugging of issues such as #695, where the bridge chip
that controls IDE is NOT a PIIX3/4 compatible controller. Instead of
just hanging when the DMA registers can't be accessed, the system will
inform the user that no valid IDE controller has been found. In this
case, the system will not attempt to initialise the DMA registers and
instead use PIO mode.
-rw-r--r-- | Kernel/Devices/PATAChannel.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Kernel/Devices/PATAChannel.cpp b/Kernel/Devices/PATAChannel.cpp index 4d78562a8d..8ba881d02f 100644 --- a/Kernel/Devices/PATAChannel.cpp +++ b/Kernel/Devices/PATAChannel.cpp @@ -124,6 +124,8 @@ void PATAChannel::initialize() m_bus_master_base = PCI::get_BAR4(m_pci_address) & 0xfffc; m_dma_buffer_page = MM.allocate_supervisor_physical_page(); kprintf("PATAChannel: PIIX Bus master IDE: I/O @ %x\n", m_bus_master_base); + } else { + kprintf("PATAChannel: Unable to find valid PATAChannel controller! Falling back to PIO mode!\n"); } } |