I have noticed a problem within many of the Linux ACPI-related drivers. When ACPI_FUNCTION_TRACE() is used, all return() statements within the function should use the ACPI return macros (return_ACPI_STATUS, etc.) instead of just a raw return. These return macros maintain the function nesting count (nesting count is incremented by ACPI_FUNCTION_TRACE, and decremented by the return macros.) The nesting depth is very useful when analyzing execution traces of ACPI code.
Created attachment 3930 [details] patch against 2.6.8.1 ACPI tree
Shipped in Linux 2.6.10-rc2 - closed.