ACPI device initialization order

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
Gigasoft
Member
Member
Posts: 856
Joined: Sat Nov 21, 2009 5:11 pm

ACPI device initialization order

Post by Gigasoft »

The ACPI specification states that a device's _STA method is executed before executing the _INI method, which is in turn executed before _ADR, _CID, _HID, _UID and _SUN.

In Bochs, the _STA method of \_SB.PCI0.ISA.LPT accesses a PCI_Config operation region belonging to \_SB.PCI0.PX13, which is defined later. Also, the _STA method of \_SB.LNKA accesses a PCI_Config operation region belonging to \_SB.PCI0.ISA.P40C. Therefore, the devices containing those operation regions would have to have already had their _ADR object evaluated, right? So there is a specific order in which the devices have to be examined, but how does one know this? Is it just another Bochs bug? The specification specifically warns you not to access operation regions until the OS indicates they are ready.
isaacwoods
Member
Member
Posts: 47
Joined: Sun Sep 06, 2015 5:40 am

Re: ACPI device initialization order

Post by isaacwoods »

Without seeing the tables, I think it's probably likely that Bochs is just being lazy as it knows all those things will be hardcoded (most emulators don't do anything in their `_INI`s, from what I've seen). I'd bet that the `_ADR`s are just defined as constants?
Post Reply