Firmware Test Suite - method test

This test loads the ACPI tables into the ACPICA execution engine and evaluates many of the core methods and objects in the DSDT and in the SSDTs. The aim of these tests is to sanity check the return types from methods and objects, and where possible do some light checking of return values where this is possible. Note however some methods and objects may communicate with I/O ports, the embedded controller and even try to generate SMIs which are NOT possible in the emulation, so we try to avoid sanity checking these returned data values.

The main focus of this test is to ensure the correct data types are being returned and also that the arguments to methods match those as defined in the ACPI specification.

The test also checks to see if Mutex acquires get freed on each method or object being evaluated and tested.

The default mode of this test is to try and use the host machine's ACPI tables which requires root permissions to be able to load this data from firmware. However, one can load in ACPI tables from other machines using the --dumpfile option. The ACPI tables can be loaded in from the output from acpidump or from using "sudo fwts --dump".


sudo fwts method - 

..runs the test on your machine and dumps the output to stdout.

fwts method --dumpfile=apcidump.dat -

..runs the test using ACPI tables in the dump file acpidump.dat as the input and dumps the test results to stdout.

sudo acpidump > acpidump.dat
fwts method --dumpfile=acpidump.dat

..dumps the tables using acpidump and loads them in and runs the method test with results appended to results.log

sudo fwts --dump
fwts method --dumpfile=acpidump.log -

..dumps the tables using fwts and loads them in and runs the method test with results going to stdout.

Currently just over 90 methods and objects are sanity checked. Each test will display the name of the ACPI method or object (e.g. _BCL) and the associated human readable name (e.g. "Query List of Brightness Control Levels Supported") followed by the test results. The test traverses the entire object tree and will test each instance that matches the method and object name. If a package is returned, then the contents is dumped. All return types are checked against expected return types and some fixed returned values are sanity checked too.

Errors found in this test are reported and advice for each error is generally reported to explain the reason for the failure and any action that needs to be taken to fix it. However, more often than not, fixing errors found in this test require a fix in the firmware.

FirmwareTestSuite/Reference/method (last edited 2016-01-11 07:23:25 by anthonywong)