Bug 5189 - ACPI - AML Alias command is broken
ACPI - AML Alias command is broken
Status: CLOSED CODE_FIX
Product: ACPI
Classification: Unclassified
Component: ACPICA-Core
i386 Linux
: P2 high
Assigned To: Robert Moore
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-09-05 09:02 UTC by Thomas Renninger
Modified: 2006-09-28 13:16 UTC (History)
1 user (show)

See Also:
Kernel Version: 2.6.13
Tree: Mainline
Regression: ---


Attachments
sorry for the delay ... thanks for help ... here it is. (96.64 KB, text/plain)
2005-09-09 10:45 UTC, Thomas Renninger
Details

Description Thomas Renninger 2005-09-05 09:02:06 UTC
The affected dsdt can be found at:  
http://www.renninger.de/acpi/dsdt.dsl  
  
Affected seems to be the compiler as well as the interpreter.  
Trying to compile the DSDT breaks with following message:  
___________________________________  
dsdt.dsl.alias_debug  2198:                                 Store (NVGA, \GDGS)  
Error    1031 -                                      Internal compiler error ^   
(Missing alias link)  
  
dsdt.dsl.alias_debug  2211:                             If (LEqual (\GDGS,  
0x00))  
Error    1031 -                                 Internal compiler error ^   
(Missing alias link)  
  
dsdt.dsl.alias_debug  2215:                                 Store (NVGA, \GDGS)  
Error    1031 -                                      Internal compiler error ^   
(Missing alias link)dsdt.dsl.alias_debug  2198:                                  
Store (NVGA, \GDGS)  
Error    1031 -                                      Internal compiler error ^   
(Missing alias link)  
  
dsdt.dsl.alias_debug  2211:                             If (LEqual (\GDGS,  
0x00))  
Error    1031 -                                 Internal compiler error ^   
(Missing alias link)  
  
dsdt.dsl.alias_debug  2215:                                 Store (NVGA, \GDGS)  
Error    1031 -                                      Internal compiler error ^   
(Missing alias link)  
________________________________________  
  
The interpreter is affected as well, the kernel reports (/var/log/messages):  
  
exstoren-0142: *** Error: Store into Alias - should never happen  
 psparse-1172: *** Error: Method execution failed [\_TZ_.RTMP] (Node df7ae528),  
AE_AML_INTERNAL  
 psparse-1172: *** Error: Method execution failed [\_TZ_.THRM._TMP] (Node  
df7ae2e8), AE_AML_INTERNAL  
  
I could workaround the problem by replacing some aliases with the whole path.  
Not sure whether this is true, however the errors seem to vanish:  
When replacing the Alias definitions to the very beginning of the DSDT, no  
errors any more. 
Symptoms are: entire /proc/acpi/thermal_zone tree is missing and probably more. 
I could get the thermal_zone running by replacing the aliases in thermal zone 
code... 
  
It seems as if at the creation of the ALIAS_TYPE_LOCAL node the node that  
points to the real path is not created correctly? 
At least in asllookup.c, line 826 (compiler) in 
if (NextOp->Asl.Node) 
is NULL. The error probably is somewhere when the link is created?
Comment 1 Len Brown 2005-09-07 18:44:54 UTC
As this is against 2.6.13, I assume this refers
to ACPICA 20050408.  Same in latest release contained
in the ACPI patch?

Has this always been broken or is this a regression?
Comment 2 Robert Moore 2005-09-08 15:58:11 UTC
Investigating.  Please post the acpidump of the machine also.
Comment 3 Robert Moore 2005-09-09 09:58:24 UTC
Investigating.  Please post the acpidump of the machine also.
Comment 4 Thomas Renninger 2005-09-09 10:45:41 UTC
Created attachment 5957 [details]
sorry for the delay ... thanks for help ... here it is.

You need to replace IO declarations with e.g. XIO (or test the patch I sent
recently). The missing CMD0, DAT0 declarations are follow-up errors...
Comment 5 Robert Moore 2005-09-09 11:09:05 UTC
Looks like the issue is not Alias() per se, it is resolving forward references 
to an alias object - of which there are 4 in this DSDT. This affects both the 
iASL compiler and the AML interpreter since they share common code.

As a workaround, move this statement to the beginning of the DSDT code block:
Alias (\_SB.PCI0.IGFX.GDGS, \GDGS)

Comment 6 Len Brown 2005-09-14 19:54:51 UTC
So this is not a regression, but has always been broken, yes?
Comment 7 Thomas Renninger 2005-09-15 00:33:03 UTC
I think so, yes. But it should be considered as fairly sever as whole parts of 
the ACPI subsystem could break away (for this guy the thermal_zone does not 
come up). 
 
Is something wrong in the parser? Maybe the Alias does not exist yet, when it's 
tried to be used? 
 
I have not much time currently ... there are some other issues -> will write a 
mail maybe some things have already been solved. 
Tell me how I can help here best (testing should be no problem, if you could 
describe the problem I also can have a look at possibly affected code and try 
to fix it...). 
Comment 8 Robert Moore 2005-09-15 13:47:27 UTC
Yes, this problem looks very old. Multiple passes are required to parse AML 
tables, and proper resolution of forward references is of course one reason. 
It appears that alias objects are not completely setup during the initial 
pass, and the forward reference causes a failure on a subsequent pass.

We don't see too much of this, as it seems that ASL writers tend to generally 
avoid forward references in the code.

I believe that the workaround is to move the alias statement in question to 
the beginning of the DSDT. This fixed the problem here.
Comment 9 Robert Moore 2006-01-25 13:36:21 UTC
Problem is similar to #5674, is is a superset. The interpreter part (same as 
5674) is fixed for the next release, investigating the compiler issue.
Comment 10 Robert Moore 2006-01-27 14:17:13 UTC
Both problems should be fixed in version 20060127
Comment 11 Len Brown 2006-02-02 14:42:17 UTC
ACPICA 20050127 shipped in Linux-2.6.16-rc1-git6 -- closing.
Comment 12 Len Brown 2006-02-02 15:02:58 UTC
20060127 that is

Note You need to log in before you can comment on or make changes to this bug.