acpi-mcp

v0.1.0
io.github.0xmortuex/acpi-mcp Checked 2 days ago Published 1 month ago

Read ACPI tables from a live QEMU guest or files and explain them for OS developers.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

acpi_load

Load a set of ACPI tables and register it under `name`. Pass exactly one source: - port: a live VM's gdbstub (QEMU -s is port 1234). Tables are read from guest PHYSICAL memory, so this works even after the guest enables paging. QEMU allows one debugger at a time - disconnect gdbstub-mcp first. QEMU pauses the guest while attached; resume=True detaches afterwards (the guest runs on, even one started with -S), resume=False leaves it paused. If QEMU was started with -S the firmware hasn't built the tables yet: set boot_wait_s=5: it runs the guest until…

ParameterTypeDescription
name *string
boot_wait_snumber
hoststring
path
port
resumeboolean

acpi_tables

List every table: signature, address, length, checksum, OEM, and what it's for.

ParameterTypeDescription
name *string

acpi_table

Decode one table and explain what it means for an OS. signature: FACP/FADT, APIC/MADT, HPET, MCFG, DSDT, SSDT, FACS, RSDT, XSDT, WAET, RSDP. index picks among duplicates (e.g. several SSDTs).

ParameterTypeDescription
name *string
signature *string
indexinteger

acpi_interrupt_routing

Map every legacy ISA IRQ (0-15) to its GSI and I/O APIC pin, with polarity and trigger mode, from the MADT's interrupt source overrides. This is the table to program I/O APIC redirection entries from.

ParameterTypeDescription
name *string

acpi_find

Answer an OS-developer question from the tables, with the exact ports, addresses and values to use. Understands: shutdown / power off, reset / reboot, hpet, pci config / ecam, cpus / smp, irq routing / ioapic, pm timer, keyboard / ps2, serial, rtc century, sci.

ParameterTypeDescription
name *string
question *string

acpi_dump

Hexdump a table's raw bytes (offset/length within the table, max 4096 bytes).

ParameterTypeDescription
name *string
signature *string
indexinteger
lengthinteger
offsetinteger

acpi_disassemble

Disassemble a DSDT/SSDT's AML to ASL source with ACPICA's `iasl -d`. Needs iasl on PATH (Debian/Ubuntu: apt install acpica-tools; macOS: brew install acpica; Windows: the ACPICA release from intel.com/acpi). acpi_table already lists devices and \_S5_ without iasl.

ParameterTypeDescription
name *string
indexinteger
max_charsinteger
signaturestring

acpi_sets

List loaded table sets.