]> Projects (at) Tadryanom (dot) Me - AdrOS.git/commit
fix: wrap pci.c in #if x86 guard with stubs for other architectures
authorTulio A M Mendes <[email protected]>
Tue, 10 Feb 2026 04:05:52 +0000 (01:05 -0300)
committerTulio A M Mendes <[email protected]>
Tue, 10 Feb 2026 04:05:52 +0000 (01:05 -0300)
commit80c94db552f8b07b3bdc9839ca52449fcdc12f78
treeb06203ef2c3eeac42175c21d2f28cda2e1e8b62e
parent8300757e23b49af40aa2b01616f412d5220cb5f2
fix: wrap pci.c in #if x86 guard with stubs for other architectures

PCI config space I/O port access (0xCF8/0xCFC) using outl/inl is
x86-only. The driver had no architecture guard, so it would fail
to compile on ARM, RISC-V, and MIPS.

Wrap the full implementation in #if defined(__i386__) and provide
no-op stubs for non-x86 targets.

Passes: make, cppcheck, QEMU smoke test.
src/drivers/pci.c