* Bug in "implicit return" code
@ 2005-01-03 4:08 Nate Lawson
0 siblings, 0 replies; only message in thread
From: Nate Lawson @ 2005-01-03 4:08 UTC (permalink / raw)
To: acpi; +Cc: acpi-devel
I have identified a problem in the implicit return code in dsutils.c.
Various Toshiba laptops have a _STA method that is similar to this:
DefinitionBlock ("DSDT.aml", "DSDT", 1, "TOSHIB", "8100 ", 536872468)
{
Device (LNKA)
{
Name (_HID, EisaId ("PNP0C0F"))
Method (_STA, 0, NotSerialized)
{
STAL (0x60)
}
}
Method (STAL, 1, NotSerialized)
{
/* Various link accesses removed for clarity. */
Return (0x0B)
}
}
If you compile and run this snippet in the debugger, you'll see that
_STA doesn't return anything even with EnableInterpreterSlack set to
TRUE. This means the implicit return code doesn't work properly.
I examined the AcpiDsIsResultUsed() function and found that the check
that was failing was this one:
/*
* If there is no parent, we are executing at the method level.
* An executing method typically has no parent, since each method
* is parsed separately.
*/
if (!Op->Common.Parent)
So it appears that there _is_ a parent and the implicit return code
below is never executed for this method. I'm not sure the proper way to
change this check for the above AML case but hopefully the Intel people
will know.
--
Nate
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-01-03 4:08 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-01-03 4:08 Bug in "implicit return" code Nate Lawson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox