AML, forward references?
Posted: Sun Nov 08, 2020 9:42 am
The Bochs emulator provides a DSDT where a name (LNKD) is referenced by a package before it is defined. There is no way to know in advance what the name will refer to, so what am I to make of this? Is this even legal AML?
To illustrate the problem, suppose you have the following definition block. If it is legal, what does it do and what will be stored in \AAAA\DDDD? If not, where is the error?
To illustrate the problem, suppose you have the following definition block. If it is legal, what does it do and what will be stored in \AAAA\DDDD? If not, where is the error?
Code: Select all
Device (AAAA) {
Name (BBBB, Package(1) {CCCC})
If (LEqual(ObjectType(Index(BBBB, 0)), 1)) {
Device(CCCC) {
}
Name(DDDD, 0)
} Else {
Name(DDDD, 1)
}
}
Name (CCCC, 1234)