diff options
author | Ian Moffett <ian@osmora.org> | 2025-09-21 16:53:03 -0400 |
---|---|---|
committer | Ian Moffett <ian@osmora.org> | 2025-09-21 16:53:24 -0400 |
commit | e6e0bb0d435b3410d520baea60652af05cae8232 (patch) | |
tree | bd36cc276a02bf951e6663fb3c8b403ef7e1b5df /src/sys/io/ic | |
parent | d88c40fc062f28c63ae7bc3836407df3470287a3 (diff) |
kern: ahci: Only support 64-bit HBAs for now
Abort if the host controller does not support 64-bit addressing
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'src/sys/io/ic')
-rw-r--r-- | src/sys/io/ic/ahci.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/sys/io/ic/ahci.c b/src/sys/io/ic/ahci.c index 3a6f0c3..5cc675f 100644 --- a/src/sys/io/ic/ahci.c +++ b/src/sys/io/ic/ahci.c @@ -286,6 +286,13 @@ ahci_hba_init(struct ahci_hba *hba) hba->pi = mmio_read32(&io->pi); hba->nport = AHCI_CAP_NP(cap) + 1; + /* Only support 64-bit addressing as of now */ + if (AHCI_CAP_S64A(cap) == 0) { + pr_trace("HBA does not support 64-bit addressing\n"); + pr_trace("aborting..\n"); + return -ENOTSUP; + } + /* * We cannot be so certain what state the BIOS or whatever * firmware left the host controller in, therefore the HBA |