Интерфейс управления для acpi microsoft windows что это

From Wikipedia, the free encyclopedia

From Wikipedia, the free encyclopedia

Example of ACPI tables of a Lenovo laptop.

Advanced Configuration and Power Interface (ACPI) is an open standard that operating systems can use to discover and configure computer hardware components, to perform power management (e.g. putting unused hardware components to sleep), auto configuration (e.g. Plug and Play and hot swapping), and status monitoring. First released in December 1996, ACPI aims to replace Advanced Power Management (APM), the MultiProcessor Specification, and the Plug and Play BIOS (PnP) Specification.[1] ACPI brings power management under the control of the operating system, as opposed to the previous BIOS-centric system that relied on platform-specific firmware to determine power management and configuration policies.[2] The specification is central to the Operating System-directed configuration and Power Management (OSPM) system. ACPI defines hardware abstraction interfaces between the device’s firmware (e.g. BIOS, UEFI), the computer hardware components, and the operating systems.[3][4]

Internally, ACPI advertises the available components and their functions to the operating system kernel using instruction lists («methods») provided through the system firmware (UEFI or BIOS), which the kernel parses. ACPI then executes the desired operations written in ACPI Machine Language (such as the initialization of hardware components) using an embedded minimal virtual machine.

Intel, Microsoft and Toshiba originally developed the standard, while HP, Huawei and Phoenix also participated later. In October 2013, ACPI Special Interest Group (ACPI SIG), the original developers of the ACPI standard, agreed to transfer all assets to the UEFI Forum, in which all future development will take place.[5]

The UEFI Forum published the latest version of the standard, «Release 6.5» in August 2022.[6]

Architecture[edit]

The firmware-level ACPI has three main components: the ACPI tables, the ACPI BIOS, and the ACPI registers. The ACPI BIOS generates ACPI tables and loads ACPI tables into main memory. Much of the firmware ACPI functionality is provided in bytecode of ACPI Machine Language (AML), a Turing-complete, domain-specific low-level language, stored in the ACPI tables.[7] To make use of the ACPI tables, the operating system must have an interpreter for the AML bytecode. A reference AML interpreter implementation is provided by the ACPI Component Architecture (ACPICA). At the BIOS development time, AML bytecode is compiled from the ASL (ACPI Source Language) code.[8][9]

Overall design decision was not without criticism. In November 2003, Linus Torvalds—author of the Linux kernel—described ACPI as «a complete design disaster in every way».[10][11] In 2001, other senior Linux software developers like Alan Cox expressed concerns about the requirements that bytecode from an external source must be run by the kernel with full privileges, as well as the overall complexity of the ACPI specification.[12] In 2014, Mark Shuttleworth, founder of the Ubuntu Linux distribution, compared ACPI with Trojan horses.[13]

ACPI Component Architecture (ACPICA)[edit]

The ACPI Component Architecture (ACPICA), mainly written by Intel’s engineers, provides an open-source platform-independent reference implementation of the operating system–related ACPI code.[14] The ACPICA code is used by Linux, Haiku, ArcaOS[15] and FreeBSD,[8] which supplement it with their operating-system specific code.

History[edit]

The first revision of the ACPI specification was released in December 1996, supporting 16, 24 and 32-bit addressing spaces. It was not until August 2000 that ACPI received 64-bit address support as well as support for multiprocessor workstations and servers with revision 2.0.

In 1999, then Microsoft CEO Bill Gates stated in an e-mail that Linux would benefit from ACPI without them having to do work and suggested to make it Windows-only.[16][17][18]

In September 2004, revision 3.0 was released, bringing to the ACPI specification support for SATA interfaces, PCI Express bus, multiprocessor support for more than 256 processors, ambient light sensors and user-presence devices, as well as extending the thermal model beyond the previous processor-centric support.

Released in June 2009, revision 4.0 of the ACPI specification added various new features to the design; most notable are the USB 3.0 support, logical processor idling support, and x2APIC support.

Revision 5.0 of the ACPI specification was released in December 2011,[19] which added the ARM architecture support. The revision 5.1 was released in July 2014.[20]

The latest specification revision is 6.5, which was released in August 2022.[6]

Operating systems[edit]

The «It’s now safe to turn off your computer» screen in Windows 9x. Most of the computer peripherals are offline, and the only ways to exit this screen is to power off or reset the computer.

The «It’s now safe to turn off your computer» screen in Windows NT 4.0. Unlike Windows 9x and later NT releases, most of the essential computer peripherals are working normally, so the user can opt to restart instead of powering off their computer.

Microsoft’s Windows 98 was the first operating system to implement ACPI,[21][22] but its implementation was somewhat buggy or incomplete,[23][24] although some of the problems associated with it were caused by the first-generation ACPI hardware.[25] Other operating systems, including later versions of Windows, macOS, eComStation, ArcaOS,[26] FreeBSD (since FreeBSD 5.0[27]), NetBSD (since NetBSD 1.6[28]), OpenBSD (since OpenBSD 3.8[29]), HP-UX, OpenVMS, Linux, GNU Hurd and PC versions of Solaris, have at least some support for ACPI.[30] Some newer operating systems, like Windows Vista, require the computer to have an ACPI-compliant BIOS, and since Windows 8, the S0ix/Modern Standby state was implemented.[31]

Windows operating systems use acpi.sys[32] to access ACPI events.

The 2.4 series of the Linux kernel had only minimal support for ACPI, with better support implemented (and enabled by default) from kernel version 2.6.0 onwards.[33] Old ACPI BIOS implementations tend to be quite buggy, and consequently are not supported by later operating systems. For example, Windows 2000, Windows XP, and Windows Server 2003 only use ACPI if the BIOS date is after January 1, 1999.[34] Similarly, Linux kernel 2.6 blacklisted any ACPI BIOS from before January 1, 2001.[33]

Linux-based operating systems can provide handling of ACPI events via acpid.[35]

OSPM responsibilities[edit]

Once an OSPM-compatible operating system activates ACPI, it takes exclusive control of all aspects of power management and device configuration. The OSPM implementation must expose an ACPI-compatible environment to device drivers, which exposes certain system, device and processor states.

Power states[edit]

Global states[edit]

The ACPI Specification defines the following four global «Gx» states and six sleep «Sx» states for an ACPI-compliant computer system:[36][37]

Gx Name Sx Description
G0 Working S0 The computer is running and the CPU executes instructions. «Awaymode» is a subset of S0, where monitor is off but background tasks are running
G1 Sleeping S0ix Modern Standby,[38] or «Low Power S0 Idle». Partial processor SoC sleep.[39][40] Known to ARM and x86 devices.
S1 Power on Suspend (POS): Processor caches are flushed, and the CPU(s) stops executing instructions. The power to the CPU(s) and RAM is maintained. Devices that do not indicate they must remain on may be powered off.
S2 CPU powered off. Dirty cache is flushed to RAM.
S3 commonly referred to as Standby, Sleep, or Suspend to RAM (STR): RAM remains powered.
S4 Hibernation or Suspend to Disk: All content of the main memory is saved to non-volatile memory such as a hard drive, and the system is powered down.
G2 Soft Off S5 G2/S5 is almost the same as G3 Mechanical Off, except that the power supply unit (PSU) still supplies power, at a minimum, to the power button to allow return to S0. A full reboot is required. No previous content is retained. Other components may remain powered so the computer can «wake» on input from the keyboard, clock, modem, LAN, or USB device.
G3 Mechanical Off The computer’s power has been totally removed via a mechanical switch (as on the rear of a PSU). The power cord can be removed and the system is safe for disassembly (typically, only the real-time clock continues to run using its own small battery).

The specification also defines a Legacy state: the state of an operating system which does not support ACPI. In this state, the hardware and power are not managed via ACPI, effectively disabling ACPI.

Device states[edit]

The device states D0D3 are device dependent:

  • D0 or Fully On is the operating state.
    • As with S0ix, Intel has D0ix states for intermediate levels on the SoC.[41]
  • D1 and D2 are intermediate power-states whose definition varies by device.
  • D3: The D3 state is further divided into D3 Hot (has auxiliary power), and D3 Cold (no power provided):
    • Hot: A device can assert power management requests to transition to higher power states.
    • Cold or Off has the device powered off and unresponsive to its bus.

Processor states[edit]

The CPU power states C0C3 are defined as follows:

  • C0 is the operating state.
  • C1 (often known as Halt) is a state where the processor is not executing instructions, but can return to an executing state essentially instantaneously. All ACPI-conformant processors must support this power state. Some processors, such as the Pentium 4 and AMD Athlon, also support an Enhanced C1 state (C1E or Enhanced Halt State) for lower power consumption, however this proved to be buggy on some systems.[42][43]
  • C2 (often known as Stop-Clock) is a state where the processor maintains all software-visible state, but may take longer to wake up. This processor state is optional.
  • C3 (often known as Sleep) is a state where the processor does not need to keep its cache coherent, but maintains other state. Some processors have variations on the C3 state (Deep Sleep, Deeper Sleep, etc.) that differ in how long it takes to wake the processor. This processor state is optional.
  • Additional states are defined by manufacturers for some processors. For example, Intel’s Haswell platform has states up to C10, where it distinguishes core states and package states.[44]

Performance state[edit]

While a device or processor operates (D0 and C0, respectively), it can be in one of several power-performance states. These states are implementation-dependent. P0 is always the highest-performance state, with P1 to Pn being successively lower-performance states, up to an implementation-specific limit of n no greater than 16.[45]

P-states have become known as SpeedStep in Intel processors, as PowerNow! or Cool’n’Quiet in AMD processors, and as PowerSaver in VIA processors.

  • P0 maximum power and frequency
  • P1 less than P0, voltage and frequency scaled
  • P2 less than P1, voltage and frequency scaled
  • Pn less than P(n–1), voltage and frequency scaled

Interfaces[edit]

Hardware[edit]

ACPI-compliant systems interact with hardware through either a «Function Fixed Hardware (FFH) Interface», or a platform-independent hardware programming model which relies on platform-specific ACPI Machine Language (AML) provided by the original equipment manufacturer (OEM).

Function Fixed Hardware interfaces are platform-specific features, provided by platform manufacturers for the purposes of performance and failure recovery. Standard Intel-based PCs have a fixed function interface defined by Intel,[46] which provides a set of core functionality that reduces an ACPI-compliant system’s need for full driver stacks for providing basic functionality during boot time or in the case of major system failure.

ACPI Platform Error Interface (APEI) is a specification for reporting of hardware errors, e.g. chipset, RAM to the operating system.

Firmware[edit]

ACPI defines many tables that provide the interface between an ACPI-compliant operating system and system firmware (BIOS or UEFI). This includes RSDP, RSDT, XSDT, FADT, FACS, DSDT, SSDT, MADT, and MCFG, for example.[47][48]

The tables allow description of system hardware in a platform-independent manner, and are presented as either fixed-formatted data structures or in AML. The main AML table is the DSDT (differentiated system description table). The AML can be decompiled by tools like Intel’s iASL (open-source, part of ACPICA) for purposes like patching the tables for expanding OS compatibility.[49][50]

The Root System Description Pointer (RSDP) is located in a platform-dependent manner, and describes the rest of the tables.

Security risks[edit]

A custom ACPI table called the Windows Platform Binary Table (WPBT) is used by Microsoft to allow vendors to add software into the Windows OS automatically. Some vendors, such as Lenovo, have been caught using this feature to install harmful software such as Superfish.[51] Samsung shipped PCs with Windows Update disabled.[51] Windows versions older than Windows 7 do not support this feature, but alternative techniques can be used. This behavior has been compared to rootkits.[52][53]

See also[edit]

  • Active State Power Management
  • Coreboot
  • Green computing
  • Power management keys
  • Unified Extensible Firmware Interface
  • Wake-on-LAN
  • SBSA

References[edit]

  1. ^ «ACPI Overview» (PDF). www.acpi.info. Archived from the original (slide show in PDF) on May 25, 2019.
  2. ^ «APM BIOS Specification». Intel Corporation, Microsoft Corporation. February 1996. Archived from the original (RTF) on February 6, 2012. Retrieved July 2, 2010.
  3. ^ «What is ACPI (Advanced Configuration and Power Interface)? — Definition from WhatIs.com». SearchWindowsServer. Retrieved September 18, 2020.
  4. ^ «ACPI Device Tree — Representation of ACPI Namespace — The Linux Kernel documentation». www.kernel.org. Retrieved September 18, 2020.
  5. ^
    «The Advanced Configuration & Power Interface web page has a prominent note that links to the Preexisting ACPI Specifications page on the UEFI web site». acpi.org. July 23, 2014. Retrieved January 25, 2016.
  6. ^ a b
    «Advanced Configuration and Power Interface Specification, Release 6.5» (PDF). UEFI.org/specifications. August 2022. Retrieved October 4, 2022.
  7. ^
    Bernhard Kauer (August 2009). «ATARE: ACPI Tables and Regular Expressions» (PDF). Retrieved February 18, 2019.
  8. ^ a b ACPI implementation on FreeBSD — Usenix
  9. ^ ACPI in Linux, 2005
  10. ^ Linux Magazine issue 162, May 2014, page 9
  11. ^ Searls, Doc (November 25, 2003). «Linus & the Lunatics, Part II». Linux Journal. Retrieved January 13, 2010.
  12. ^ Corbet, Jonathan (July 4, 2001). «Kernel Development». LWN.net weekly edition. LWN.net. Retrieved July 2, 2010.
  13. ^ Linux Format n°184, June 2014, page 7.
  14. ^ ACPICA: ACPI Component Architecture
  15. ^ «Readme for the ACPI Driver Package». arcanoae.com. Retrieved September 6, 2020.
  16. ^ «Microsoft wollte ACPI nur für Windows». Der Standard (in Austrian German). Retrieved November 6, 2022.
  17. ^ «Microsoft: ACPI sollte nur unter Windows funktionieren». Golem.de. Retrieved November 6, 2022.
  18. ^ Gates, Bill (January 24, 1999). «ACPI extensions» (PDF). Archived from the original (PDF) on February 2, 2007.
  19. ^ Hewlett-Packard; Intel Corporation; Microsoft; Phoenix Technologies; Toshiba (December 6, 2011). «Advanced Configuration and Power Interface Specification (Revision 5.0)» (PDF). acpi.info. Retrieved November 17, 2013.
  20. ^ «Advanced Configuration and Power Interface Specification (Revision 5.1)» (PDF). uefi.org. July 23, 2014. Retrieved May 24, 2015.
  21. ^ «Limitations When Using Microsoft Windows 98 on Compaq Armada Portables» (PDF). physik.hu-berlin.de. October 1998. p. 3. Retrieved January 27, 2014.[permanent dead link]
  22. ^ «Windows 98 on ThinkPad systems — ThinkPad General». Support.lenovo.com. Archived from the original on February 3, 2014. Retrieved January 27, 2014.
  23. ^ Robert Cowart; Brian Knittel (2000). Using Microsoft Windows 2000 Professional. Que Publishing. p. 30. ISBN 978-0-7897-2125-9.
  24. ^ Windows 98 Does Not Support ACPI Passive Cooling Mode
  25. ^ «Cover Story: Win98 Bugs & Fixes — December 1998». winmag.com. Archived from the original on October 13, 1999.
  26. ^ «ArcaOS Changelog». Retrieved August 24, 2020.
  27. ^ «FreeBSD 5.0-RELEASE Announcement». www.freebsd.org. Retrieved December 3, 2020.
  28. ^ «acpi(4) — NetBSD Manual Pages». man.netbsd.org. Retrieved December 3, 2020.
  29. ^ «acpi(4) — OpenBSD manual pages». man.openbsd.org. Retrieved December 3, 2020.
  30. ^
    Therien, Guy (January 6, 2000). «ACPI 2.0 Specification Technical Review, Intel Developer Forum» (PPT). Intel Corporation. Archived from the original on July 21, 2011. Retrieved August 21, 2011.
  31. ^ Marshall, Allen. «ACPI in Windows Vista» (PPT). Microsoft Corporation. Retrieved July 2, 2010.
  32. ^ «Acpi.sys: The Windows ACPI Driver». Microsoft Corporation. June 15, 2017. Retrieved September 20, 2019.
  33. ^ a b The State of ACPI in the Linux Kernel
  34. ^ ACPI BIOS. msdn.microsoft.com.
  35. ^ Linux in a nutshell. Ellen Siever, Ellen Siever (5th ed.). Beijing: O’Reilly. 2005. p. 36. ISBN 978-0-596-52949-9. OCLC 773210086.{{cite book}}: CS1 maint: others (link)
  36. ^ ACPI Spec Rev 5.0 — dated December 6, 2011
  37. ^ Anand Lal Shimpi (October 5, 2012). «Intel’s Haswell Architecture Analyzed». AnandTech. Retrieved October 20, 2013.
  38. ^ windows-driver-content. «Modern Standby». docs.microsoft.com. Retrieved March 20, 2020.
  39. ^ «S0ix States». software.intel.com. March 9, 2020.
  40. ^ Wang, Wendy (October 17, 2018). «How to achieve S0ix states in Linux*». 01.org.
  41. ^ «D0ix States». software.intel.com. March 9, 2020.
  42. ^ «Athlon II X2: Hardware C1E and Return of the CnQ Bug». AnandTech. Retrieved October 26, 2020.
  43. ^ Wasson, Scott (February 21, 2005). «Intel’s Pentium 4 600 series processors». The Tech Report. p. 2.
  44. ^ «Processor Package and Core C-States». AnandTech. June 9, 2013. Retrieved October 20, 2013.
  45. ^ «Advanced Configuration and Power Interface Specification, Revision 3.0, Section 2.6 Device and Processor Performance State Definitions» (PDF). ACPI.info. September 2, 2004. p. 23. Retrieved August 19, 2015.
  46. ^ Intel Corporation (September 2006). «Intel Processor Vendor-Specific ACPI» (PDF). Archived from the original (PDF) on December 25, 2012. Retrieved October 5, 2014.
  47. ^
    Brown, Len (July 20, 2005). «ACPI in Linux». Ottawa Linux Symposium: 3. CiteSeerX 10.1.1.173.2206.
  48. ^ «ACPI Tables — The Linux Kernel documentation». www.kernel.org. Retrieved November 8, 2020.
  49. ^ «DSDT». ArchWiki.
  50. ^ «Getting Started With ACPI». GitBook.
  51. ^ a b Hoffman, Chris (August 19, 2015). «Zombie Crapware: How the Windows Platform Binary Table Works». How-To Geek.
  52. ^ «Vendors ‘rootkit’: ‘Windows Platform Binary Table’ (WPBT)». Born’s Tech and Windows World. December 6, 2017.
  53. ^ Mayank Sharma (September 27, 2021). «Millions of Windows 10 PCs exposed by nasty security vulnerability». TechRadar. Retrieved November 10, 2022.

External links[edit]

  • Official website (UEFI and ACPI specifications)
  • Everything You Need to Know About the CPU C-States Power Saving Modes
  • Sample EFI ASL code used by VirtualBox; EFI/ASL code itself is from the open source Intel EFI Development Kit II (TianoCore)
  • ACPICA

From Wikipedia, the free encyclopedia

Example of ACPI tables of a Lenovo laptop.

Advanced Configuration and Power Interface (ACPI) is an open standard that operating systems can use to discover and configure computer hardware components, to perform power management (e.g. putting unused hardware components to sleep), auto configuration (e.g. Plug and Play and hot swapping), and status monitoring. First released in December 1996, ACPI aims to replace Advanced Power Management (APM), the MultiProcessor Specification, and the Plug and Play BIOS (PnP) Specification.[1] ACPI brings power management under the control of the operating system, as opposed to the previous BIOS-centric system that relied on platform-specific firmware to determine power management and configuration policies.[2] The specification is central to the Operating System-directed configuration and Power Management (OSPM) system. ACPI defines hardware abstraction interfaces between the device’s firmware (e.g. BIOS, UEFI), the computer hardware components, and the operating systems.[3][4]

Internally, ACPI advertises the available components and their functions to the operating system kernel using instruction lists («methods») provided through the system firmware (UEFI or BIOS), which the kernel parses. ACPI then executes the desired operations written in ACPI Machine Language (such as the initialization of hardware components) using an embedded minimal virtual machine.

Intel, Microsoft and Toshiba originally developed the standard, while HP, Huawei and Phoenix also participated later. In October 2013, ACPI Special Interest Group (ACPI SIG), the original developers of the ACPI standard, agreed to transfer all assets to the UEFI Forum, in which all future development will take place.[5]

The UEFI Forum published the latest version of the standard, «Release 6.5» in August 2022.[6]

Architecture[edit]

The firmware-level ACPI has three main components: the ACPI tables, the ACPI BIOS, and the ACPI registers. The ACPI BIOS generates ACPI tables and loads ACPI tables into main memory. Much of the firmware ACPI functionality is provided in bytecode of ACPI Machine Language (AML), a Turing-complete, domain-specific low-level language, stored in the ACPI tables.[7] To make use of the ACPI tables, the operating system must have an interpreter for the AML bytecode. A reference AML interpreter implementation is provided by the ACPI Component Architecture (ACPICA). At the BIOS development time, AML bytecode is compiled from the ASL (ACPI Source Language) code.[8][9]

Overall design decision was not without criticism. In November 2003, Linus Torvalds—author of the Linux kernel—described ACPI as «a complete design disaster in every way».[10][11] In 2001, other senior Linux software developers like Alan Cox expressed concerns about the requirements that bytecode from an external source must be run by the kernel with full privileges, as well as the overall complexity of the ACPI specification.[12] In 2014, Mark Shuttleworth, founder of the Ubuntu Linux distribution, compared ACPI with Trojan horses.[13]

ACPI Component Architecture (ACPICA)[edit]

The ACPI Component Architecture (ACPICA), mainly written by Intel’s engineers, provides an open-source platform-independent reference implementation of the operating system–related ACPI code.[14] The ACPICA code is used by Linux, Haiku, ArcaOS[15] and FreeBSD,[8] which supplement it with their operating-system specific code.

History[edit]

The first revision of the ACPI specification was released in December 1996, supporting 16, 24 and 32-bit addressing spaces. It was not until August 2000 that ACPI received 64-bit address support as well as support for multiprocessor workstations and servers with revision 2.0.

In 1999, then Microsoft CEO Bill Gates stated in an e-mail that Linux would benefit from ACPI without them having to do work and suggested to make it Windows-only.[16][17][18]

In September 2004, revision 3.0 was released, bringing to the ACPI specification support for SATA interfaces, PCI Express bus, multiprocessor support for more than 256 processors, ambient light sensors and user-presence devices, as well as extending the thermal model beyond the previous processor-centric support.

Released in June 2009, revision 4.0 of the ACPI specification added various new features to the design; most notable are the USB 3.0 support, logical processor idling support, and x2APIC support.

Revision 5.0 of the ACPI specification was released in December 2011,[19] which added the ARM architecture support. The revision 5.1 was released in July 2014.[20]

The latest specification revision is 6.5, which was released in August 2022.[6]

Operating systems[edit]

The «It’s now safe to turn off your computer» screen in Windows 9x. Most of the computer peripherals are offline, and the only ways to exit this screen is to power off or reset the computer.

The «It’s now safe to turn off your computer» screen in Windows NT 4.0. Unlike Windows 9x and later NT releases, most of the essential computer peripherals are working normally, so the user can opt to restart instead of powering off their computer.

Microsoft’s Windows 98 was the first operating system to implement ACPI,[21][22] but its implementation was somewhat buggy or incomplete,[23][24] although some of the problems associated with it were caused by the first-generation ACPI hardware.[25] Other operating systems, including later versions of Windows, macOS, eComStation, ArcaOS,[26] FreeBSD (since FreeBSD 5.0[27]), NetBSD (since NetBSD 1.6[28]), OpenBSD (since OpenBSD 3.8[29]), HP-UX, OpenVMS, Linux, GNU Hurd and PC versions of Solaris, have at least some support for ACPI.[30] Some newer operating systems, like Windows Vista, require the computer to have an ACPI-compliant BIOS, and since Windows 8, the S0ix/Modern Standby state was implemented.[31]

Windows operating systems use acpi.sys[32] to access ACPI events.

The 2.4 series of the Linux kernel had only minimal support for ACPI, with better support implemented (and enabled by default) from kernel version 2.6.0 onwards.[33] Old ACPI BIOS implementations tend to be quite buggy, and consequently are not supported by later operating systems. For example, Windows 2000, Windows XP, and Windows Server 2003 only use ACPI if the BIOS date is after January 1, 1999.[34] Similarly, Linux kernel 2.6 blacklisted any ACPI BIOS from before January 1, 2001.[33]

Linux-based operating systems can provide handling of ACPI events via acpid.[35]

OSPM responsibilities[edit]

Once an OSPM-compatible operating system activates ACPI, it takes exclusive control of all aspects of power management and device configuration. The OSPM implementation must expose an ACPI-compatible environment to device drivers, which exposes certain system, device and processor states.

Power states[edit]

Global states[edit]

The ACPI Specification defines the following four global «Gx» states and six sleep «Sx» states for an ACPI-compliant computer system:[36][37]

Gx Name Sx Description
G0 Working S0 The computer is running and the CPU executes instructions. «Awaymode» is a subset of S0, where monitor is off but background tasks are running
G1 Sleeping S0ix Modern Standby,[38] or «Low Power S0 Idle». Partial processor SoC sleep.[39][40] Known to ARM and x86 devices.
S1 Power on Suspend (POS): Processor caches are flushed, and the CPU(s) stops executing instructions. The power to the CPU(s) and RAM is maintained. Devices that do not indicate they must remain on may be powered off.
S2 CPU powered off. Dirty cache is flushed to RAM.
S3 commonly referred to as Standby, Sleep, or Suspend to RAM (STR): RAM remains powered.
S4 Hibernation or Suspend to Disk: All content of the main memory is saved to non-volatile memory such as a hard drive, and the system is powered down.
G2 Soft Off S5 G2/S5 is almost the same as G3 Mechanical Off, except that the power supply unit (PSU) still supplies power, at a minimum, to the power button to allow return to S0. A full reboot is required. No previous content is retained. Other components may remain powered so the computer can «wake» on input from the keyboard, clock, modem, LAN, or USB device.
G3 Mechanical Off The computer’s power has been totally removed via a mechanical switch (as on the rear of a PSU). The power cord can be removed and the system is safe for disassembly (typically, only the real-time clock continues to run using its own small battery).

The specification also defines a Legacy state: the state of an operating system which does not support ACPI. In this state, the hardware and power are not managed via ACPI, effectively disabling ACPI.

Device states[edit]

The device states D0D3 are device dependent:

  • D0 or Fully On is the operating state.
    • As with S0ix, Intel has D0ix states for intermediate levels on the SoC.[41]
  • D1 and D2 are intermediate power-states whose definition varies by device.
  • D3: The D3 state is further divided into D3 Hot (has auxiliary power), and D3 Cold (no power provided):
    • Hot: A device can assert power management requests to transition to higher power states.
    • Cold or Off has the device powered off and unresponsive to its bus.

Processor states[edit]

The CPU power states C0C3 are defined as follows:

  • C0 is the operating state.
  • C1 (often known as Halt) is a state where the processor is not executing instructions, but can return to an executing state essentially instantaneously. All ACPI-conformant processors must support this power state. Some processors, such as the Pentium 4 and AMD Athlon, also support an Enhanced C1 state (C1E or Enhanced Halt State) for lower power consumption, however this proved to be buggy on some systems.[42][43]
  • C2 (often known as Stop-Clock) is a state where the processor maintains all software-visible state, but may take longer to wake up. This processor state is optional.
  • C3 (often known as Sleep) is a state where the processor does not need to keep its cache coherent, but maintains other state. Some processors have variations on the C3 state (Deep Sleep, Deeper Sleep, etc.) that differ in how long it takes to wake the processor. This processor state is optional.
  • Additional states are defined by manufacturers for some processors. For example, Intel’s Haswell platform has states up to C10, where it distinguishes core states and package states.[44]

Performance state[edit]

While a device or processor operates (D0 and C0, respectively), it can be in one of several power-performance states. These states are implementation-dependent. P0 is always the highest-performance state, with P1 to Pn being successively lower-performance states, up to an implementation-specific limit of n no greater than 16.[45]

P-states have become known as SpeedStep in Intel processors, as PowerNow! or Cool’n’Quiet in AMD processors, and as PowerSaver in VIA processors.

  • P0 maximum power and frequency
  • P1 less than P0, voltage and frequency scaled
  • P2 less than P1, voltage and frequency scaled
  • Pn less than P(n–1), voltage and frequency scaled

Interfaces[edit]

Hardware[edit]

ACPI-compliant systems interact with hardware through either a «Function Fixed Hardware (FFH) Interface», or a platform-independent hardware programming model which relies on platform-specific ACPI Machine Language (AML) provided by the original equipment manufacturer (OEM).

Function Fixed Hardware interfaces are platform-specific features, provided by platform manufacturers for the purposes of performance and failure recovery. Standard Intel-based PCs have a fixed function interface defined by Intel,[46] which provides a set of core functionality that reduces an ACPI-compliant system’s need for full driver stacks for providing basic functionality during boot time or in the case of major system failure.

ACPI Platform Error Interface (APEI) is a specification for reporting of hardware errors, e.g. chipset, RAM to the operating system.

Firmware[edit]

ACPI defines many tables that provide the interface between an ACPI-compliant operating system and system firmware (BIOS or UEFI). This includes RSDP, RSDT, XSDT, FADT, FACS, DSDT, SSDT, MADT, and MCFG, for example.[47][48]

The tables allow description of system hardware in a platform-independent manner, and are presented as either fixed-formatted data structures or in AML. The main AML table is the DSDT (differentiated system description table). The AML can be decompiled by tools like Intel’s iASL (open-source, part of ACPICA) for purposes like patching the tables for expanding OS compatibility.[49][50]

The Root System Description Pointer (RSDP) is located in a platform-dependent manner, and describes the rest of the tables.

Security risks[edit]

A custom ACPI table called the Windows Platform Binary Table (WPBT) is used by Microsoft to allow vendors to add software into the Windows OS automatically. Some vendors, such as Lenovo, have been caught using this feature to install harmful software such as Superfish.[51] Samsung shipped PCs with Windows Update disabled.[51] Windows versions older than Windows 7 do not support this feature, but alternative techniques can be used. This behavior has been compared to rootkits.[52][53]

See also[edit]

  • Active State Power Management
  • Coreboot
  • Green computing
  • Power management keys
  • Unified Extensible Firmware Interface
  • Wake-on-LAN
  • SBSA

References[edit]

  1. ^ «ACPI Overview» (PDF). www.acpi.info. Archived from the original (slide show in PDF) on May 25, 2019.
  2. ^ «APM BIOS Specification». Intel Corporation, Microsoft Corporation. February 1996. Archived from the original (RTF) on February 6, 2012. Retrieved July 2, 2010.
  3. ^ «What is ACPI (Advanced Configuration and Power Interface)? — Definition from WhatIs.com». SearchWindowsServer. Retrieved September 18, 2020.
  4. ^ «ACPI Device Tree — Representation of ACPI Namespace — The Linux Kernel documentation». www.kernel.org. Retrieved September 18, 2020.
  5. ^
    «The Advanced Configuration & Power Interface web page has a prominent note that links to the Preexisting ACPI Specifications page on the UEFI web site». acpi.org. July 23, 2014. Retrieved January 25, 2016.
  6. ^ a b
    «Advanced Configuration and Power Interface Specification, Release 6.5» (PDF). UEFI.org/specifications. August 2022. Retrieved October 4, 2022.
  7. ^
    Bernhard Kauer (August 2009). «ATARE: ACPI Tables and Regular Expressions» (PDF). Retrieved February 18, 2019.
  8. ^ a b ACPI implementation on FreeBSD — Usenix
  9. ^ ACPI in Linux, 2005
  10. ^ Linux Magazine issue 162, May 2014, page 9
  11. ^ Searls, Doc (November 25, 2003). «Linus & the Lunatics, Part II». Linux Journal. Retrieved January 13, 2010.
  12. ^ Corbet, Jonathan (July 4, 2001). «Kernel Development». LWN.net weekly edition. LWN.net. Retrieved July 2, 2010.
  13. ^ Linux Format n°184, June 2014, page 7.
  14. ^ ACPICA: ACPI Component Architecture
  15. ^ «Readme for the ACPI Driver Package». arcanoae.com. Retrieved September 6, 2020.
  16. ^ «Microsoft wollte ACPI nur für Windows». Der Standard (in Austrian German). Retrieved November 6, 2022.
  17. ^ «Microsoft: ACPI sollte nur unter Windows funktionieren». Golem.de. Retrieved November 6, 2022.
  18. ^ Gates, Bill (January 24, 1999). «ACPI extensions» (PDF). Archived from the original (PDF) on February 2, 2007.
  19. ^ Hewlett-Packard; Intel Corporation; Microsoft; Phoenix Technologies; Toshiba (December 6, 2011). «Advanced Configuration and Power Interface Specification (Revision 5.0)» (PDF). acpi.info. Retrieved November 17, 2013.
  20. ^ «Advanced Configuration and Power Interface Specification (Revision 5.1)» (PDF). uefi.org. July 23, 2014. Retrieved May 24, 2015.
  21. ^ «Limitations When Using Microsoft Windows 98 on Compaq Armada Portables» (PDF). physik.hu-berlin.de. October 1998. p. 3. Retrieved January 27, 2014.[permanent dead link]
  22. ^ «Windows 98 on ThinkPad systems — ThinkPad General». Support.lenovo.com. Archived from the original on February 3, 2014. Retrieved January 27, 2014.
  23. ^ Robert Cowart; Brian Knittel (2000). Using Microsoft Windows 2000 Professional. Que Publishing. p. 30. ISBN 978-0-7897-2125-9.
  24. ^ Windows 98 Does Not Support ACPI Passive Cooling Mode
  25. ^ «Cover Story: Win98 Bugs & Fixes — December 1998». winmag.com. Archived from the original on October 13, 1999.
  26. ^ «ArcaOS Changelog». Retrieved August 24, 2020.
  27. ^ «FreeBSD 5.0-RELEASE Announcement». www.freebsd.org. Retrieved December 3, 2020.
  28. ^ «acpi(4) — NetBSD Manual Pages». man.netbsd.org. Retrieved December 3, 2020.
  29. ^ «acpi(4) — OpenBSD manual pages». man.openbsd.org. Retrieved December 3, 2020.
  30. ^
    Therien, Guy (January 6, 2000). «ACPI 2.0 Specification Technical Review, Intel Developer Forum» (PPT). Intel Corporation. Archived from the original on July 21, 2011. Retrieved August 21, 2011.
  31. ^ Marshall, Allen. «ACPI in Windows Vista» (PPT). Microsoft Corporation. Retrieved July 2, 2010.
  32. ^ «Acpi.sys: The Windows ACPI Driver». Microsoft Corporation. June 15, 2017. Retrieved September 20, 2019.
  33. ^ a b The State of ACPI in the Linux Kernel
  34. ^ ACPI BIOS. msdn.microsoft.com.
  35. ^ Linux in a nutshell. Ellen Siever, Ellen Siever (5th ed.). Beijing: O’Reilly. 2005. p. 36. ISBN 978-0-596-52949-9. OCLC 773210086.{{cite book}}: CS1 maint: others (link)
  36. ^ ACPI Spec Rev 5.0 — dated December 6, 2011
  37. ^ Anand Lal Shimpi (October 5, 2012). «Intel’s Haswell Architecture Analyzed». AnandTech. Retrieved October 20, 2013.
  38. ^ windows-driver-content. «Modern Standby». docs.microsoft.com. Retrieved March 20, 2020.
  39. ^ «S0ix States». software.intel.com. March 9, 2020.
  40. ^ Wang, Wendy (October 17, 2018). «How to achieve S0ix states in Linux*». 01.org.
  41. ^ «D0ix States». software.intel.com. March 9, 2020.
  42. ^ «Athlon II X2: Hardware C1E and Return of the CnQ Bug». AnandTech. Retrieved October 26, 2020.
  43. ^ Wasson, Scott (February 21, 2005). «Intel’s Pentium 4 600 series processors». The Tech Report. p. 2.
  44. ^ «Processor Package and Core C-States». AnandTech. June 9, 2013. Retrieved October 20, 2013.
  45. ^ «Advanced Configuration and Power Interface Specification, Revision 3.0, Section 2.6 Device and Processor Performance State Definitions» (PDF). ACPI.info. September 2, 2004. p. 23. Retrieved August 19, 2015.
  46. ^ Intel Corporation (September 2006). «Intel Processor Vendor-Specific ACPI» (PDF). Archived from the original (PDF) on December 25, 2012. Retrieved October 5, 2014.
  47. ^
    Brown, Len (July 20, 2005). «ACPI in Linux». Ottawa Linux Symposium: 3. CiteSeerX 10.1.1.173.2206.
  48. ^ «ACPI Tables — The Linux Kernel documentation». www.kernel.org. Retrieved November 8, 2020.
  49. ^ «DSDT». ArchWiki.
  50. ^ «Getting Started With ACPI». GitBook.
  51. ^ a b Hoffman, Chris (August 19, 2015). «Zombie Crapware: How the Windows Platform Binary Table Works». How-To Geek.
  52. ^ «Vendors ‘rootkit’: ‘Windows Platform Binary Table’ (WPBT)». Born’s Tech and Windows World. December 6, 2017.
  53. ^ Mayank Sharma (September 27, 2021). «Millions of Windows 10 PCs exposed by nasty security vulnerability». TechRadar. Retrieved November 10, 2022.

External links[edit]

  • Official website (UEFI and ACPI specifications)
  • Everything You Need to Know About the CPU C-States Power Saving Modes
  • Sample EFI ASL code used by VirtualBox; EFI/ASL code itself is from the open source Intel EFI Development Kit II (TianoCore)
  • ACPICA

From Wikipedia, the free encyclopedia

Example of ACPI tables of a Lenovo laptop.

Advanced Configuration and Power Interface (ACPI) is an open standard that operating systems can use to discover and configure computer hardware components, to perform power management (e.g. putting unused hardware components to sleep), auto configuration (e.g. Plug and Play and hot swapping), and status monitoring. First released in December 1996, ACPI aims to replace Advanced Power Management (APM), the MultiProcessor Specification, and the Plug and Play BIOS (PnP) Specification.[1] ACPI brings power management under the control of the operating system, as opposed to the previous BIOS-centric system that relied on platform-specific firmware to determine power management and configuration policies.[2] The specification is central to the Operating System-directed configuration and Power Management (OSPM) system. ACPI defines hardware abstraction interfaces between the device’s firmware (e.g. BIOS, UEFI), the computer hardware components, and the operating systems.[3][4]

Internally, ACPI advertises the available components and their functions to the operating system kernel using instruction lists («methods») provided through the system firmware (UEFI or BIOS), which the kernel parses. ACPI then executes the desired operations written in ACPI Machine Language (such as the initialization of hardware components) using an embedded minimal virtual machine.

Intel, Microsoft and Toshiba originally developed the standard, while HP, Huawei and Phoenix also participated later. In October 2013, ACPI Special Interest Group (ACPI SIG), the original developers of the ACPI standard, agreed to transfer all assets to the UEFI Forum, in which all future development will take place.[5]

The UEFI Forum published the latest version of the standard, «Release 6.5» in August 2022.[6]

Architecture[edit]

The firmware-level ACPI has three main components: the ACPI tables, the ACPI BIOS, and the ACPI registers. The ACPI BIOS generates ACPI tables and loads ACPI tables into main memory. Much of the firmware ACPI functionality is provided in bytecode of ACPI Machine Language (AML), a Turing-complete, domain-specific low-level language, stored in the ACPI tables.[7] To make use of the ACPI tables, the operating system must have an interpreter for the AML bytecode. A reference AML interpreter implementation is provided by the ACPI Component Architecture (ACPICA). At the BIOS development time, AML bytecode is compiled from the ASL (ACPI Source Language) code.[8][9]

Overall design decision was not without criticism. In November 2003, Linus Torvalds—author of the Linux kernel—described ACPI as «a complete design disaster in every way».[10][11] In 2001, other senior Linux software developers like Alan Cox expressed concerns about the requirements that bytecode from an external source must be run by the kernel with full privileges, as well as the overall complexity of the ACPI specification.[12] In 2014, Mark Shuttleworth, founder of the Ubuntu Linux distribution, compared ACPI with Trojan horses.[13]

ACPI Component Architecture (ACPICA)[edit]

The ACPI Component Architecture (ACPICA), mainly written by Intel’s engineers, provides an open-source platform-independent reference implementation of the operating system–related ACPI code.[14] The ACPICA code is used by Linux, Haiku, ArcaOS[15] and FreeBSD,[8] which supplement it with their operating-system specific code.

History[edit]

The first revision of the ACPI specification was released in December 1996, supporting 16, 24 and 32-bit addressing spaces. It was not until August 2000 that ACPI received 64-bit address support as well as support for multiprocessor workstations and servers with revision 2.0.

In 1999, then Microsoft CEO Bill Gates stated in an e-mail that Linux would benefit from ACPI without them having to do work and suggested to make it Windows-only.[16][17][18]

In September 2004, revision 3.0 was released, bringing to the ACPI specification support for SATA interfaces, PCI Express bus, multiprocessor support for more than 256 processors, ambient light sensors and user-presence devices, as well as extending the thermal model beyond the previous processor-centric support.

Released in June 2009, revision 4.0 of the ACPI specification added various new features to the design; most notable are the USB 3.0 support, logical processor idling support, and x2APIC support.

Revision 5.0 of the ACPI specification was released in December 2011,[19] which added the ARM architecture support. The revision 5.1 was released in July 2014.[20]

The latest specification revision is 6.5, which was released in August 2022.[6]

Operating systems[edit]

The «It’s now safe to turn off your computer» screen in Windows 9x. Most of the computer peripherals are offline, and the only ways to exit this screen is to power off or reset the computer.

The «It’s now safe to turn off your computer» screen in Windows NT 4.0. Unlike Windows 9x and later NT releases, most of the essential computer peripherals are working normally, so the user can opt to restart instead of powering off their computer.

Microsoft’s Windows 98 was the first operating system to implement ACPI,[21][22] but its implementation was somewhat buggy or incomplete,[23][24] although some of the problems associated with it were caused by the first-generation ACPI hardware.[25] Other operating systems, including later versions of Windows, macOS, eComStation, ArcaOS,[26] FreeBSD (since FreeBSD 5.0[27]), NetBSD (since NetBSD 1.6[28]), OpenBSD (since OpenBSD 3.8[29]), HP-UX, OpenVMS, Linux, GNU Hurd and PC versions of Solaris, have at least some support for ACPI.[30] Some newer operating systems, like Windows Vista, require the computer to have an ACPI-compliant BIOS, and since Windows 8, the S0ix/Modern Standby state was implemented.[31]

Windows operating systems use acpi.sys[32] to access ACPI events.

The 2.4 series of the Linux kernel had only minimal support for ACPI, with better support implemented (and enabled by default) from kernel version 2.6.0 onwards.[33] Old ACPI BIOS implementations tend to be quite buggy, and consequently are not supported by later operating systems. For example, Windows 2000, Windows XP, and Windows Server 2003 only use ACPI if the BIOS date is after January 1, 1999.[34] Similarly, Linux kernel 2.6 blacklisted any ACPI BIOS from before January 1, 2001.[33]

Linux-based operating systems can provide handling of ACPI events via acpid.[35]

OSPM responsibilities[edit]

Once an OSPM-compatible operating system activates ACPI, it takes exclusive control of all aspects of power management and device configuration. The OSPM implementation must expose an ACPI-compatible environment to device drivers, which exposes certain system, device and processor states.

Power states[edit]

Global states[edit]

The ACPI Specification defines the following four global «Gx» states and six sleep «Sx» states for an ACPI-compliant computer system:[36][37]

Gx Name Sx Description
G0 Working S0 The computer is running and the CPU executes instructions. «Awaymode» is a subset of S0, where monitor is off but background tasks are running
G1 Sleeping S0ix Modern Standby,[38] or «Low Power S0 Idle». Partial processor SoC sleep.[39][40] Known to ARM and x86 devices.
S1 Power on Suspend (POS): Processor caches are flushed, and the CPU(s) stops executing instructions. The power to the CPU(s) and RAM is maintained. Devices that do not indicate they must remain on may be powered off.
S2 CPU powered off. Dirty cache is flushed to RAM.
S3 commonly referred to as Standby, Sleep, or Suspend to RAM (STR): RAM remains powered.
S4 Hibernation or Suspend to Disk: All content of the main memory is saved to non-volatile memory such as a hard drive, and the system is powered down.
G2 Soft Off S5 G2/S5 is almost the same as G3 Mechanical Off, except that the power supply unit (PSU) still supplies power, at a minimum, to the power button to allow return to S0. A full reboot is required. No previous content is retained. Other components may remain powered so the computer can «wake» on input from the keyboard, clock, modem, LAN, or USB device.
G3 Mechanical Off The computer’s power has been totally removed via a mechanical switch (as on the rear of a PSU). The power cord can be removed and the system is safe for disassembly (typically, only the real-time clock continues to run using its own small battery).

The specification also defines a Legacy state: the state of an operating system which does not support ACPI. In this state, the hardware and power are not managed via ACPI, effectively disabling ACPI.

Device states[edit]

The device states D0D3 are device dependent:

  • D0 or Fully On is the operating state.
    • As with S0ix, Intel has D0ix states for intermediate levels on the SoC.[41]
  • D1 and D2 are intermediate power-states whose definition varies by device.
  • D3: The D3 state is further divided into D3 Hot (has auxiliary power), and D3 Cold (no power provided):
    • Hot: A device can assert power management requests to transition to higher power states.
    • Cold or Off has the device powered off and unresponsive to its bus.

Processor states[edit]

The CPU power states C0C3 are defined as follows:

  • C0 is the operating state.
  • C1 (often known as Halt) is a state where the processor is not executing instructions, but can return to an executing state essentially instantaneously. All ACPI-conformant processors must support this power state. Some processors, such as the Pentium 4 and AMD Athlon, also support an Enhanced C1 state (C1E or Enhanced Halt State) for lower power consumption, however this proved to be buggy on some systems.[42][43]
  • C2 (often known as Stop-Clock) is a state where the processor maintains all software-visible state, but may take longer to wake up. This processor state is optional.
  • C3 (often known as Sleep) is a state where the processor does not need to keep its cache coherent, but maintains other state. Some processors have variations on the C3 state (Deep Sleep, Deeper Sleep, etc.) that differ in how long it takes to wake the processor. This processor state is optional.
  • Additional states are defined by manufacturers for some processors. For example, Intel’s Haswell platform has states up to C10, where it distinguishes core states and package states.[44]

Performance state[edit]

While a device or processor operates (D0 and C0, respectively), it can be in one of several power-performance states. These states are implementation-dependent. P0 is always the highest-performance state, with P1 to Pn being successively lower-performance states, up to an implementation-specific limit of n no greater than 16.[45]

P-states have become known as SpeedStep in Intel processors, as PowerNow! or Cool’n’Quiet in AMD processors, and as PowerSaver in VIA processors.

  • P0 maximum power and frequency
  • P1 less than P0, voltage and frequency scaled
  • P2 less than P1, voltage and frequency scaled
  • Pn less than P(n–1), voltage and frequency scaled

Interfaces[edit]

Hardware[edit]

ACPI-compliant systems interact with hardware through either a «Function Fixed Hardware (FFH) Interface», or a platform-independent hardware programming model which relies on platform-specific ACPI Machine Language (AML) provided by the original equipment manufacturer (OEM).

Function Fixed Hardware interfaces are platform-specific features, provided by platform manufacturers for the purposes of performance and failure recovery. Standard Intel-based PCs have a fixed function interface defined by Intel,[46] which provides a set of core functionality that reduces an ACPI-compliant system’s need for full driver stacks for providing basic functionality during boot time or in the case of major system failure.

ACPI Platform Error Interface (APEI) is a specification for reporting of hardware errors, e.g. chipset, RAM to the operating system.

Firmware[edit]

ACPI defines many tables that provide the interface between an ACPI-compliant operating system and system firmware (BIOS or UEFI). This includes RSDP, RSDT, XSDT, FADT, FACS, DSDT, SSDT, MADT, and MCFG, for example.[47][48]

The tables allow description of system hardware in a platform-independent manner, and are presented as either fixed-formatted data structures or in AML. The main AML table is the DSDT (differentiated system description table). The AML can be decompiled by tools like Intel’s iASL (open-source, part of ACPICA) for purposes like patching the tables for expanding OS compatibility.[49][50]

The Root System Description Pointer (RSDP) is located in a platform-dependent manner, and describes the rest of the tables.

Security risks[edit]

A custom ACPI table called the Windows Platform Binary Table (WPBT) is used by Microsoft to allow vendors to add software into the Windows OS automatically. Some vendors, such as Lenovo, have been caught using this feature to install harmful software such as Superfish.[51] Samsung shipped PCs with Windows Update disabled.[51] Windows versions older than Windows 7 do not support this feature, but alternative techniques can be used. This behavior has been compared to rootkits.[52][53]

See also[edit]

  • Active State Power Management
  • Coreboot
  • Green computing
  • Power management keys
  • Unified Extensible Firmware Interface
  • Wake-on-LAN
  • SBSA

References[edit]

  1. ^ «ACPI Overview» (PDF). www.acpi.info. Archived from the original (slide show in PDF) on May 25, 2019.
  2. ^ «APM BIOS Specification». Intel Corporation, Microsoft Corporation. February 1996. Archived from the original (RTF) on February 6, 2012. Retrieved July 2, 2010.
  3. ^ «What is ACPI (Advanced Configuration and Power Interface)? — Definition from WhatIs.com». SearchWindowsServer. Retrieved September 18, 2020.
  4. ^ «ACPI Device Tree — Representation of ACPI Namespace — The Linux Kernel documentation». www.kernel.org. Retrieved September 18, 2020.
  5. ^
    «The Advanced Configuration & Power Interface web page has a prominent note that links to the Preexisting ACPI Specifications page on the UEFI web site». acpi.org. July 23, 2014. Retrieved January 25, 2016.
  6. ^ a b
    «Advanced Configuration and Power Interface Specification, Release 6.5» (PDF). UEFI.org/specifications. August 2022. Retrieved October 4, 2022.
  7. ^
    Bernhard Kauer (August 2009). «ATARE: ACPI Tables and Regular Expressions» (PDF). Retrieved February 18, 2019.
  8. ^ a b ACPI implementation on FreeBSD — Usenix
  9. ^ ACPI in Linux, 2005
  10. ^ Linux Magazine issue 162, May 2014, page 9
  11. ^ Searls, Doc (November 25, 2003). «Linus & the Lunatics, Part II». Linux Journal. Retrieved January 13, 2010.
  12. ^ Corbet, Jonathan (July 4, 2001). «Kernel Development». LWN.net weekly edition. LWN.net. Retrieved July 2, 2010.
  13. ^ Linux Format n°184, June 2014, page 7.
  14. ^ ACPICA: ACPI Component Architecture
  15. ^ «Readme for the ACPI Driver Package». arcanoae.com. Retrieved September 6, 2020.
  16. ^ «Microsoft wollte ACPI nur für Windows». Der Standard (in Austrian German). Retrieved November 6, 2022.
  17. ^ «Microsoft: ACPI sollte nur unter Windows funktionieren». Golem.de. Retrieved November 6, 2022.
  18. ^ Gates, Bill (January 24, 1999). «ACPI extensions» (PDF). Archived from the original (PDF) on February 2, 2007.
  19. ^ Hewlett-Packard; Intel Corporation; Microsoft; Phoenix Technologies; Toshiba (December 6, 2011). «Advanced Configuration and Power Interface Specification (Revision 5.0)» (PDF). acpi.info. Retrieved November 17, 2013.
  20. ^ «Advanced Configuration and Power Interface Specification (Revision 5.1)» (PDF). uefi.org. July 23, 2014. Retrieved May 24, 2015.
  21. ^ «Limitations When Using Microsoft Windows 98 on Compaq Armada Portables» (PDF). physik.hu-berlin.de. October 1998. p. 3. Retrieved January 27, 2014.[permanent dead link]
  22. ^ «Windows 98 on ThinkPad systems — ThinkPad General». Support.lenovo.com. Archived from the original on February 3, 2014. Retrieved January 27, 2014.
  23. ^ Robert Cowart; Brian Knittel (2000). Using Microsoft Windows 2000 Professional. Que Publishing. p. 30. ISBN 978-0-7897-2125-9.
  24. ^ Windows 98 Does Not Support ACPI Passive Cooling Mode
  25. ^ «Cover Story: Win98 Bugs & Fixes — December 1998». winmag.com. Archived from the original on October 13, 1999.
  26. ^ «ArcaOS Changelog». Retrieved August 24, 2020.
  27. ^ «FreeBSD 5.0-RELEASE Announcement». www.freebsd.org. Retrieved December 3, 2020.
  28. ^ «acpi(4) — NetBSD Manual Pages». man.netbsd.org. Retrieved December 3, 2020.
  29. ^ «acpi(4) — OpenBSD manual pages». man.openbsd.org. Retrieved December 3, 2020.
  30. ^
    Therien, Guy (January 6, 2000). «ACPI 2.0 Specification Technical Review, Intel Developer Forum» (PPT). Intel Corporation. Archived from the original on July 21, 2011. Retrieved August 21, 2011.
  31. ^ Marshall, Allen. «ACPI in Windows Vista» (PPT). Microsoft Corporation. Retrieved July 2, 2010.
  32. ^ «Acpi.sys: The Windows ACPI Driver». Microsoft Corporation. June 15, 2017. Retrieved September 20, 2019.
  33. ^ a b The State of ACPI in the Linux Kernel
  34. ^ ACPI BIOS. msdn.microsoft.com.
  35. ^ Linux in a nutshell. Ellen Siever, Ellen Siever (5th ed.). Beijing: O’Reilly. 2005. p. 36. ISBN 978-0-596-52949-9. OCLC 773210086.{{cite book}}: CS1 maint: others (link)
  36. ^ ACPI Spec Rev 5.0 — dated December 6, 2011
  37. ^ Anand Lal Shimpi (October 5, 2012). «Intel’s Haswell Architecture Analyzed». AnandTech. Retrieved October 20, 2013.
  38. ^ windows-driver-content. «Modern Standby». docs.microsoft.com. Retrieved March 20, 2020.
  39. ^ «S0ix States». software.intel.com. March 9, 2020.
  40. ^ Wang, Wendy (October 17, 2018). «How to achieve S0ix states in Linux*». 01.org.
  41. ^ «D0ix States». software.intel.com. March 9, 2020.
  42. ^ «Athlon II X2: Hardware C1E and Return of the CnQ Bug». AnandTech. Retrieved October 26, 2020.
  43. ^ Wasson, Scott (February 21, 2005). «Intel’s Pentium 4 600 series processors». The Tech Report. p. 2.
  44. ^ «Processor Package and Core C-States». AnandTech. June 9, 2013. Retrieved October 20, 2013.
  45. ^ «Advanced Configuration and Power Interface Specification, Revision 3.0, Section 2.6 Device and Processor Performance State Definitions» (PDF). ACPI.info. September 2, 2004. p. 23. Retrieved August 19, 2015.
  46. ^ Intel Corporation (September 2006). «Intel Processor Vendor-Specific ACPI» (PDF). Archived from the original (PDF) on December 25, 2012. Retrieved October 5, 2014.
  47. ^
    Brown, Len (July 20, 2005). «ACPI in Linux». Ottawa Linux Symposium: 3. CiteSeerX 10.1.1.173.2206.
  48. ^ «ACPI Tables — The Linux Kernel documentation». www.kernel.org. Retrieved November 8, 2020.
  49. ^ «DSDT». ArchWiki.
  50. ^ «Getting Started With ACPI». GitBook.
  51. ^ a b Hoffman, Chris (August 19, 2015). «Zombie Crapware: How the Windows Platform Binary Table Works». How-To Geek.
  52. ^ «Vendors ‘rootkit’: ‘Windows Platform Binary Table’ (WPBT)». Born’s Tech and Windows World. December 6, 2017.
  53. ^ Mayank Sharma (September 27, 2021). «Millions of Windows 10 PCs exposed by nasty security vulnerability». TechRadar. Retrieved November 10, 2022.

External links[edit]

  • Official website (UEFI and ACPI specifications)
  • Everything You Need to Know About the CPU C-States Power Saving Modes
  • Sample EFI ASL code used by VirtualBox; EFI/ASL code itself is from the open source Intel EFI Development Kit II (TianoCore)
  • ACPICA

From Wikipedia, the free encyclopedia

Example of ACPI tables of a Lenovo laptop.

Advanced Configuration and Power Interface (ACPI) is an open standard that operating systems can use to discover and configure computer hardware components, to perform power management (e.g. putting unused hardware components to sleep), auto configuration (e.g. Plug and Play and hot swapping), and status monitoring. First released in December 1996, ACPI aims to replace Advanced Power Management (APM), the MultiProcessor Specification, and the Plug and Play BIOS (PnP) Specification.[1] ACPI brings power management under the control of the operating system, as opposed to the previous BIOS-centric system that relied on platform-specific firmware to determine power management and configuration policies.[2] The specification is central to the Operating System-directed configuration and Power Management (OSPM) system. ACPI defines hardware abstraction interfaces between the device’s firmware (e.g. BIOS, UEFI), the computer hardware components, and the operating systems.[3][4]

Internally, ACPI advertises the available components and their functions to the operating system kernel using instruction lists («methods») provided through the system firmware (UEFI or BIOS), which the kernel parses. ACPI then executes the desired operations written in ACPI Machine Language (such as the initialization of hardware components) using an embedded minimal virtual machine.

Intel, Microsoft and Toshiba originally developed the standard, while HP, Huawei and Phoenix also participated later. In October 2013, ACPI Special Interest Group (ACPI SIG), the original developers of the ACPI standard, agreed to transfer all assets to the UEFI Forum, in which all future development will take place.[5]

The UEFI Forum published the latest version of the standard, «Release 6.5» in August 2022.[6]

Architecture[edit]

The firmware-level ACPI has three main components: the ACPI tables, the ACPI BIOS, and the ACPI registers. The ACPI BIOS generates ACPI tables and loads ACPI tables into main memory. Much of the firmware ACPI functionality is provided in bytecode of ACPI Machine Language (AML), a Turing-complete, domain-specific low-level language, stored in the ACPI tables.[7] To make use of the ACPI tables, the operating system must have an interpreter for the AML bytecode. A reference AML interpreter implementation is provided by the ACPI Component Architecture (ACPICA). At the BIOS development time, AML bytecode is compiled from the ASL (ACPI Source Language) code.[8][9]

Overall design decision was not without criticism. In November 2003, Linus Torvalds—author of the Linux kernel—described ACPI as «a complete design disaster in every way».[10][11] In 2001, other senior Linux software developers like Alan Cox expressed concerns about the requirements that bytecode from an external source must be run by the kernel with full privileges, as well as the overall complexity of the ACPI specification.[12] In 2014, Mark Shuttleworth, founder of the Ubuntu Linux distribution, compared ACPI with Trojan horses.[13]

ACPI Component Architecture (ACPICA)[edit]

The ACPI Component Architecture (ACPICA), mainly written by Intel’s engineers, provides an open-source platform-independent reference implementation of the operating system–related ACPI code.[14] The ACPICA code is used by Linux, Haiku, ArcaOS[15] and FreeBSD,[8] which supplement it with their operating-system specific code.

History[edit]

The first revision of the ACPI specification was released in December 1996, supporting 16, 24 and 32-bit addressing spaces. It was not until August 2000 that ACPI received 64-bit address support as well as support for multiprocessor workstations and servers with revision 2.0.

In 1999, then Microsoft CEO Bill Gates stated in an e-mail that Linux would benefit from ACPI without them having to do work and suggested to make it Windows-only.[16][17][18]

In September 2004, revision 3.0 was released, bringing to the ACPI specification support for SATA interfaces, PCI Express bus, multiprocessor support for more than 256 processors, ambient light sensors and user-presence devices, as well as extending the thermal model beyond the previous processor-centric support.

Released in June 2009, revision 4.0 of the ACPI specification added various new features to the design; most notable are the USB 3.0 support, logical processor idling support, and x2APIC support.

Revision 5.0 of the ACPI specification was released in December 2011,[19] which added the ARM architecture support. The revision 5.1 was released in July 2014.[20]

The latest specification revision is 6.5, which was released in August 2022.[6]

Operating systems[edit]

The «It’s now safe to turn off your computer» screen in Windows 9x. Most of the computer peripherals are offline, and the only ways to exit this screen is to power off or reset the computer.

The «It’s now safe to turn off your computer» screen in Windows NT 4.0. Unlike Windows 9x and later NT releases, most of the essential computer peripherals are working normally, so the user can opt to restart instead of powering off their computer.

Microsoft’s Windows 98 was the first operating system to implement ACPI,[21][22] but its implementation was somewhat buggy or incomplete,[23][24] although some of the problems associated with it were caused by the first-generation ACPI hardware.[25] Other operating systems, including later versions of Windows, macOS, eComStation, ArcaOS,[26] FreeBSD (since FreeBSD 5.0[27]), NetBSD (since NetBSD 1.6[28]), OpenBSD (since OpenBSD 3.8[29]), HP-UX, OpenVMS, Linux, GNU Hurd and PC versions of Solaris, have at least some support for ACPI.[30] Some newer operating systems, like Windows Vista, require the computer to have an ACPI-compliant BIOS, and since Windows 8, the S0ix/Modern Standby state was implemented.[31]

Windows operating systems use acpi.sys[32] to access ACPI events.

The 2.4 series of the Linux kernel had only minimal support for ACPI, with better support implemented (and enabled by default) from kernel version 2.6.0 onwards.[33] Old ACPI BIOS implementations tend to be quite buggy, and consequently are not supported by later operating systems. For example, Windows 2000, Windows XP, and Windows Server 2003 only use ACPI if the BIOS date is after January 1, 1999.[34] Similarly, Linux kernel 2.6 blacklisted any ACPI BIOS from before January 1, 2001.[33]

Linux-based operating systems can provide handling of ACPI events via acpid.[35]

OSPM responsibilities[edit]

Once an OSPM-compatible operating system activates ACPI, it takes exclusive control of all aspects of power management and device configuration. The OSPM implementation must expose an ACPI-compatible environment to device drivers, which exposes certain system, device and processor states.

Power states[edit]

Global states[edit]

The ACPI Specification defines the following four global «Gx» states and six sleep «Sx» states for an ACPI-compliant computer system:[36][37]

Gx Name Sx Description
G0 Working S0 The computer is running and the CPU executes instructions. «Awaymode» is a subset of S0, where monitor is off but background tasks are running
G1 Sleeping S0ix Modern Standby,[38] or «Low Power S0 Idle». Partial processor SoC sleep.[39][40] Known to ARM and x86 devices.
S1 Power on Suspend (POS): Processor caches are flushed, and the CPU(s) stops executing instructions. The power to the CPU(s) and RAM is maintained. Devices that do not indicate they must remain on may be powered off.
S2 CPU powered off. Dirty cache is flushed to RAM.
S3 commonly referred to as Standby, Sleep, or Suspend to RAM (STR): RAM remains powered.
S4 Hibernation or Suspend to Disk: All content of the main memory is saved to non-volatile memory such as a hard drive, and the system is powered down.
G2 Soft Off S5 G2/S5 is almost the same as G3 Mechanical Off, except that the power supply unit (PSU) still supplies power, at a minimum, to the power button to allow return to S0. A full reboot is required. No previous content is retained. Other components may remain powered so the computer can «wake» on input from the keyboard, clock, modem, LAN, or USB device.
G3 Mechanical Off The computer’s power has been totally removed via a mechanical switch (as on the rear of a PSU). The power cord can be removed and the system is safe for disassembly (typically, only the real-time clock continues to run using its own small battery).

The specification also defines a Legacy state: the state of an operating system which does not support ACPI. In this state, the hardware and power are not managed via ACPI, effectively disabling ACPI.

Device states[edit]

The device states D0D3 are device dependent:

  • D0 or Fully On is the operating state.
    • As with S0ix, Intel has D0ix states for intermediate levels on the SoC.[41]
  • D1 and D2 are intermediate power-states whose definition varies by device.
  • D3: The D3 state is further divided into D3 Hot (has auxiliary power), and D3 Cold (no power provided):
    • Hot: A device can assert power management requests to transition to higher power states.
    • Cold or Off has the device powered off and unresponsive to its bus.

Processor states[edit]

The CPU power states C0C3 are defined as follows:

  • C0 is the operating state.
  • C1 (often known as Halt) is a state where the processor is not executing instructions, but can return to an executing state essentially instantaneously. All ACPI-conformant processors must support this power state. Some processors, such as the Pentium 4 and AMD Athlon, also support an Enhanced C1 state (C1E or Enhanced Halt State) for lower power consumption, however this proved to be buggy on some systems.[42][43]
  • C2 (often known as Stop-Clock) is a state where the processor maintains all software-visible state, but may take longer to wake up. This processor state is optional.
  • C3 (often known as Sleep) is a state where the processor does not need to keep its cache coherent, but maintains other state. Some processors have variations on the C3 state (Deep Sleep, Deeper Sleep, etc.) that differ in how long it takes to wake the processor. This processor state is optional.
  • Additional states are defined by manufacturers for some processors. For example, Intel’s Haswell platform has states up to C10, where it distinguishes core states and package states.[44]

Performance state[edit]

While a device or processor operates (D0 and C0, respectively), it can be in one of several power-performance states. These states are implementation-dependent. P0 is always the highest-performance state, with P1 to Pn being successively lower-performance states, up to an implementation-specific limit of n no greater than 16.[45]

P-states have become known as SpeedStep in Intel processors, as PowerNow! or Cool’n’Quiet in AMD processors, and as PowerSaver in VIA processors.

  • P0 maximum power and frequency
  • P1 less than P0, voltage and frequency scaled
  • P2 less than P1, voltage and frequency scaled
  • Pn less than P(n–1), voltage and frequency scaled

Interfaces[edit]

Hardware[edit]

ACPI-compliant systems interact with hardware through either a «Function Fixed Hardware (FFH) Interface», or a platform-independent hardware programming model which relies on platform-specific ACPI Machine Language (AML) provided by the original equipment manufacturer (OEM).

Function Fixed Hardware interfaces are platform-specific features, provided by platform manufacturers for the purposes of performance and failure recovery. Standard Intel-based PCs have a fixed function interface defined by Intel,[46] which provides a set of core functionality that reduces an ACPI-compliant system’s need for full driver stacks for providing basic functionality during boot time or in the case of major system failure.

ACPI Platform Error Interface (APEI) is a specification for reporting of hardware errors, e.g. chipset, RAM to the operating system.

Firmware[edit]

ACPI defines many tables that provide the interface between an ACPI-compliant operating system and system firmware (BIOS or UEFI). This includes RSDP, RSDT, XSDT, FADT, FACS, DSDT, SSDT, MADT, and MCFG, for example.[47][48]

The tables allow description of system hardware in a platform-independent manner, and are presented as either fixed-formatted data structures or in AML. The main AML table is the DSDT (differentiated system description table). The AML can be decompiled by tools like Intel’s iASL (open-source, part of ACPICA) for purposes like patching the tables for expanding OS compatibility.[49][50]

The Root System Description Pointer (RSDP) is located in a platform-dependent manner, and describes the rest of the tables.

Security risks[edit]

A custom ACPI table called the Windows Platform Binary Table (WPBT) is used by Microsoft to allow vendors to add software into the Windows OS automatically. Some vendors, such as Lenovo, have been caught using this feature to install harmful software such as Superfish.[51] Samsung shipped PCs with Windows Update disabled.[51] Windows versions older than Windows 7 do not support this feature, but alternative techniques can be used. This behavior has been compared to rootkits.[52][53]

See also[edit]

  • Active State Power Management
  • Coreboot
  • Green computing
  • Power management keys
  • Unified Extensible Firmware Interface
  • Wake-on-LAN
  • SBSA

References[edit]

  1. ^ «ACPI Overview» (PDF). www.acpi.info. Archived from the original (slide show in PDF) on May 25, 2019.
  2. ^ «APM BIOS Specification». Intel Corporation, Microsoft Corporation. February 1996. Archived from the original (RTF) on February 6, 2012. Retrieved July 2, 2010.
  3. ^ «What is ACPI (Advanced Configuration and Power Interface)? — Definition from WhatIs.com». SearchWindowsServer. Retrieved September 18, 2020.
  4. ^ «ACPI Device Tree — Representation of ACPI Namespace — The Linux Kernel documentation». www.kernel.org. Retrieved September 18, 2020.
  5. ^
    «The Advanced Configuration & Power Interface web page has a prominent note that links to the Preexisting ACPI Specifications page on the UEFI web site». acpi.org. July 23, 2014. Retrieved January 25, 2016.
  6. ^ a b
    «Advanced Configuration and Power Interface Specification, Release 6.5» (PDF). UEFI.org/specifications. August 2022. Retrieved October 4, 2022.
  7. ^
    Bernhard Kauer (August 2009). «ATARE: ACPI Tables and Regular Expressions» (PDF). Retrieved February 18, 2019.
  8. ^ a b ACPI implementation on FreeBSD — Usenix
  9. ^ ACPI in Linux, 2005
  10. ^ Linux Magazine issue 162, May 2014, page 9
  11. ^ Searls, Doc (November 25, 2003). «Linus & the Lunatics, Part II». Linux Journal. Retrieved January 13, 2010.
  12. ^ Corbet, Jonathan (July 4, 2001). «Kernel Development». LWN.net weekly edition. LWN.net. Retrieved July 2, 2010.
  13. ^ Linux Format n°184, June 2014, page 7.
  14. ^ ACPICA: ACPI Component Architecture
  15. ^ «Readme for the ACPI Driver Package». arcanoae.com. Retrieved September 6, 2020.
  16. ^ «Microsoft wollte ACPI nur für Windows». Der Standard (in Austrian German). Retrieved November 6, 2022.
  17. ^ «Microsoft: ACPI sollte nur unter Windows funktionieren». Golem.de. Retrieved November 6, 2022.
  18. ^ Gates, Bill (January 24, 1999). «ACPI extensions» (PDF). Archived from the original (PDF) on February 2, 2007.
  19. ^ Hewlett-Packard; Intel Corporation; Microsoft; Phoenix Technologies; Toshiba (December 6, 2011). «Advanced Configuration and Power Interface Specification (Revision 5.0)» (PDF). acpi.info. Retrieved November 17, 2013.
  20. ^ «Advanced Configuration and Power Interface Specification (Revision 5.1)» (PDF). uefi.org. July 23, 2014. Retrieved May 24, 2015.
  21. ^ «Limitations When Using Microsoft Windows 98 on Compaq Armada Portables» (PDF). physik.hu-berlin.de. October 1998. p. 3. Retrieved January 27, 2014.[permanent dead link]
  22. ^ «Windows 98 on ThinkPad systems — ThinkPad General». Support.lenovo.com. Archived from the original on February 3, 2014. Retrieved January 27, 2014.
  23. ^ Robert Cowart; Brian Knittel (2000). Using Microsoft Windows 2000 Professional. Que Publishing. p. 30. ISBN 978-0-7897-2125-9.
  24. ^ Windows 98 Does Not Support ACPI Passive Cooling Mode
  25. ^ «Cover Story: Win98 Bugs & Fixes — December 1998». winmag.com. Archived from the original on October 13, 1999.
  26. ^ «ArcaOS Changelog». Retrieved August 24, 2020.
  27. ^ «FreeBSD 5.0-RELEASE Announcement». www.freebsd.org. Retrieved December 3, 2020.
  28. ^ «acpi(4) — NetBSD Manual Pages». man.netbsd.org. Retrieved December 3, 2020.
  29. ^ «acpi(4) — OpenBSD manual pages». man.openbsd.org. Retrieved December 3, 2020.
  30. ^
    Therien, Guy (January 6, 2000). «ACPI 2.0 Specification Technical Review, Intel Developer Forum» (PPT). Intel Corporation. Archived from the original on July 21, 2011. Retrieved August 21, 2011.
  31. ^ Marshall, Allen. «ACPI in Windows Vista» (PPT). Microsoft Corporation. Retrieved July 2, 2010.
  32. ^ «Acpi.sys: The Windows ACPI Driver». Microsoft Corporation. June 15, 2017. Retrieved September 20, 2019.
  33. ^ a b The State of ACPI in the Linux Kernel
  34. ^ ACPI BIOS. msdn.microsoft.com.
  35. ^ Linux in a nutshell. Ellen Siever, Ellen Siever (5th ed.). Beijing: O’Reilly. 2005. p. 36. ISBN 978-0-596-52949-9. OCLC 773210086.{{cite book}}: CS1 maint: others (link)
  36. ^ ACPI Spec Rev 5.0 — dated December 6, 2011
  37. ^ Anand Lal Shimpi (October 5, 2012). «Intel’s Haswell Architecture Analyzed». AnandTech. Retrieved October 20, 2013.
  38. ^ windows-driver-content. «Modern Standby». docs.microsoft.com. Retrieved March 20, 2020.
  39. ^ «S0ix States». software.intel.com. March 9, 2020.
  40. ^ Wang, Wendy (October 17, 2018). «How to achieve S0ix states in Linux*». 01.org.
  41. ^ «D0ix States». software.intel.com. March 9, 2020.
  42. ^ «Athlon II X2: Hardware C1E and Return of the CnQ Bug». AnandTech. Retrieved October 26, 2020.
  43. ^ Wasson, Scott (February 21, 2005). «Intel’s Pentium 4 600 series processors». The Tech Report. p. 2.
  44. ^ «Processor Package and Core C-States». AnandTech. June 9, 2013. Retrieved October 20, 2013.
  45. ^ «Advanced Configuration and Power Interface Specification, Revision 3.0, Section 2.6 Device and Processor Performance State Definitions» (PDF). ACPI.info. September 2, 2004. p. 23. Retrieved August 19, 2015.
  46. ^ Intel Corporation (September 2006). «Intel Processor Vendor-Specific ACPI» (PDF). Archived from the original (PDF) on December 25, 2012. Retrieved October 5, 2014.
  47. ^
    Brown, Len (July 20, 2005). «ACPI in Linux». Ottawa Linux Symposium: 3. CiteSeerX 10.1.1.173.2206.
  48. ^ «ACPI Tables — The Linux Kernel documentation». www.kernel.org. Retrieved November 8, 2020.
  49. ^ «DSDT». ArchWiki.
  50. ^ «Getting Started With ACPI». GitBook.
  51. ^ a b Hoffman, Chris (August 19, 2015). «Zombie Crapware: How the Windows Platform Binary Table Works». How-To Geek.
  52. ^ «Vendors ‘rootkit’: ‘Windows Platform Binary Table’ (WPBT)». Born’s Tech and Windows World. December 6, 2017.
  53. ^ Mayank Sharma (September 27, 2021). «Millions of Windows 10 PCs exposed by nasty security vulnerability». TechRadar. Retrieved November 10, 2022.

External links[edit]

  • Official website (UEFI and ACPI specifications)
  • Everything You Need to Know About the CPU C-States Power Saving Modes
  • Sample EFI ASL code used by VirtualBox; EFI/ASL code itself is from the open source Intel EFI Development Kit II (TianoCore)
  • ACPICA

ACPI расшифровывается как Advanced Configuration and Power Interface. Задача интерфейса — обеспечить взаимодействие между операционной системой, железом и BIOS. В некотором роде это некий мостик, без которого ПК работать не будет, или будет, но с ограниченными функциями.

Основная задача ACPI — способность корректно включать и выключать ПК, а также подключенные к нему устройства. Сетевые карты, звуковые карты, видеокарты — в работе всех этих устройств нужен интерфейс ACPI.

Если у вас отображается устройство ACPI-контроллер в диспетчере, но при этом ПК работает нормально — тогда пожалуй не стоит ничего делать. Если Windows сама не смогла установить драйвер, то если вы неопытный пользователь — лучше не пытаться исправить. Ошибки в работе ACPI недопустимы. Но если более-менее продвинутый пользователь, вы можете попробовать найти драйвер и установить его вручную (при помощи ИД оборудования в свойствах устройства). Либо использовать утилиту DevID Agent — она автоматически найдет нужные драйвера, которых нет на ПК и предложит их установить. Пожалуй это одна из лучших, так как нет рекламы, но при ее установке может захотеть поставиться левый софт.

Внимание! Перед ручной установкой — создайте точку восстановления!

Однако, если у вас показывает неизвестное устройство ACPI и при этом ноутбук Lenovo — то вам нужно установить Lenovo OneKey Optimizer или Lenovo Utility, в составе этих утилит есть нужный драйвер. Эта информация с официального сайта Lenovo.

Если драйвер установлен корректно, то восклицательного знака не будет:

Но если знак есть, а как исправить — вы точно не знаете, то лучше и не пытаться. ACPI — это серьезно, может Windows сообщает что он не установлен, но на самом деле используется базовый драйвер. Лучше обратиться к специалисту или даже на форум Microsoft, может там что подскажут.

На этом все, надеюсь информация помогла, удачи и добра, до новых встреч друзья!

ACPI (Advanced Configuration and Power Interface) – это стандарт (спецификация), определяющий способы программного управления электропитанием компонентов компьютера с помощью встроенных средств ОС (операционной системы). Другими словами данная технология предназначена для управления состоянием персонального компьютера и энергопотреблением его компонентов.

Кроме управления электропитанием данный стандарт позволяет выполнять конфигурацию устройств Plug and Play.

Управление электропитанием и конфигурирование устройств Plug and Play осуществляется на уровне операционной системы (предшественник спецификации ACPI стандарт АРМ реализован на уровне BIOS), то есть ОС практически полностью управляет энергопотреблением и конфигурированием устройств ПК.

Спецификация ACPI требует поддержки со стороны, как материнской платы, так и подключаемых устройств.

Для технологии ACPI определяют несколько состояний и подсостояний системы (компьютера): глобальные состояния системы, состояния ЦП (центрального процессора) и состояния устройств.

Глобальных состояний системы различают четыре:

G0 (S0) – нормальное функционирование системы;

G1 (S1, S2, S3, S4) – режимы уменьшенного энергопотребления, о которых мы поговорим чуть ниже.

G2 (S5) – программное выключение. В данном состоянии компьютер выключен, но блок питания находится под напряжением.

G3 – состояние в котором питание полностью отключено от блока питания (БП).

Режимы уменьшенного энергопотребления (S1, S2, S3, S4):

S1 (Power On Suspend, POS, Doze) – режим энергосбережения, при котором отключается монитор, винчестер, но на центральный процессор и ОЗУ (модули оперативной памяти) питание подается, снижается частота системной шины. Процессорные кэши сброшены, процессоры не выполняют инструкции, отключен генератор тактовой частоты ЦП.

S2 (Standby, Standby Mode) – режим уменьшенного энергопотребления. При данном режиме происходит отключение монитора, винчестера. От ЦП отключается напряжение питания. Останавливаются все тактовые генераторы (продолжают работать только те тактовые генераторы, которые необходимы для работы оперативной памяти). Питание подается только на системную память (в ней хранится информация о состоянии системы).

S3 (Suspend to RAM, STR, Suspend) – ждущий режим. При данном режиме энергосбережения питание подается только на оперативную память (в ней хранится информация о состоянии системы). Все другие компоненты ПК отключены.

S4 (Suspend to Disk, STD, Suspend to Hard Drive, S4-Hibernation) – глубокий сон. При данном режиме энергосбережения текущее состояние системы записывается на винчестер, после чего следует отключение питание всех компонентов ПК.

Для стандарта ACPI определяют несколько состояний процессора:

C0 – процессор работает в номинальном режиме.

C1 (Halt) – состояние уменьшенного энергопотребления. Работа процессора приостановлена, но он может незамедлительно вернуться в рабочее состояние.

C2 (Stop-Clock) – работа процессора приостановлена. Но регистры и кэш остаются в рабочем состоянии. Процессор может немедленно приступить к обработке заданий.

C3 (Sleep) – режим сна. Процессор в спящем режиме не обновляет кэш.

Для технологии ACPI также определяют четыре состояния устройств:

D0 – устройство работает в номинальном режиме.

D1 – режим уменьшенного энергопотребления (устройство использует меньше энергии чем состояние D0).

D2 – режим уменьшенного энергопотребления (устройство использует меньше энергии чем состояние D1).

D3 – устройство выключено.

Опции BIOS Setup для настройки ACPI можно найти здесь.

Интерфейс автоматического управления конфигурацией и питанием (ACPI) — это промышленный стандарт, который определяет функции управления питанием и другие сведения о конфигурации компьютера. Некоторые предыдущие версии BIOS не поддерживают интерфейс ACPI, поэтому компьютеры не могут успешно переходить в дополнительные режимы питания, например в ждущий или спящий режим.

Интерфейс автоматического управления конфигурацией и питанием (ACPI) пришел на смену уже устаревшего АРМ (Advanced Power Management).

Еще по настройке БИОС (БИОЗ) плат:

  • PCI Express, (или PCIe, или PCI-E) – это компьютерная шина расшир…

  • PCI (Peripheral Component Interconnect) – это компьютерная шина в…

  • FSB (Front Side Bus, системная шина) – это шина (набор сигнальных…

  • Чипсет (chipset) – это набор микросхем (размещенных на системной …

  • Центральный процессор (ЦП, CPU) – это микросхема, которая явля…

В данной статье пойдет речь о вопросе управления энергопотреблением в современных компьютерах, выражаясь в специфической терминологии — Power Managment. Нет-нет, не закрывайте окно браузера, считая, что вас это не касается, поскольку вы не являетесь владельцем ноутбука и не состоите в партии зеленых. Речь пойдет о гораздо более интересных вещах: совместной инициативе Intel, Microsoft и Toshiba — ACPI, и одном из наиболее интересных ее практических воплощений в Windows98/NT — технологии OnNow, должной обеспечить «постоянно доступный PC».

Итак, что же собственно это такое — ACPI? Для начала, наверное, стоит расшифровать эту аббревиатуру. ACPI, в переводе на человеческий язык, означает Advanced Configuration and Power Interface. Или, говоря по-русски, «интерфейс расширенного конфигурирования и управления питанием». Его задача — обеспечить взаимодействие между операционной системой, аппаратным обеспечением и BIOS системной платы.

Посмотрим сначала, что творится в этой области сегодня. Большинство материнских плат, даже вышедших на базе таких относительно новых чипсетов как VIA Apollo MVP3 или Intel 440BX, не поддерживают расширенное управление энергопотреблением ACPI, несмотря на то, что по идее, ACPI-совместимым считается еще аж 430TX, а сам ACPI был анонсирован в апреле 1996 года. Его использование начинается только сегодня, по мере того, как для вышедших недавно материнских плат создаются новые версии BIOS, частично поддерживающие ACPI.

В результате, на сегодняшний день картина предстает довольно печальная.

  • Совместная работа компонентов системы отсутствует, как таковая: диски начинают раскручиваться, когда это совершенно ненужно, экран гаснет во время работы, поскольку текстовый редактор забыл отметиться у операционной системы, и т.д.
  • BIOS системной платы, операционная система и приложения бьются друг с другом за контроль над аппаратным обеспечением компьютера. Но любое внешнее относительно материнской платы оборудование не участвует в процессе управления энергопотреблением — когда вы добавите в систему встроенный модем, сможет ли он как-то при установке высказать BIOS свои пожелания? И куда его пошлет BIOS?
  • Имеющееся управление энергопотреблением в основном ограничено материнской платой и отличается крайней тупостью. Ну, например, Windows98 скидывает на винт своп-файл. Даже идиоту должно быть ясно, что винт в этот момент активен, этот факт можно даже не проверять. А BIOS системной платы все равно проверяет.
  • Необходимость выключать или перезагружать компьютер при добавлении новых устройств. Кое-где уже наметился прогресс (USB, например), но все равно, до полной горячей замены еще далеко.
  • Ну и, наконец, приложения не заботятся об экономии потребляемой компьютером энергии, да и работают не ахти. Выдерните из включенного компьютера видеокарту — наверняка ведь Word зависнет. ;-)

Итак, повторюсь, основная задача ACPI — способность разумно включать и выключать PC и подключенную к нему периферию. Причем, помимо принтеров, сетевых карт, дисководов CD-ROM и прочая и прочая, могут быть и такие, пока еще экзотические устройства, как телевизор, видеомагнитофон, музыкальный центр. И конечно речь идет об умной активации PC. Так, чтобы видеоплеер при установке в него кассеты смог разбудить PC, который включил бы телевизор.

Однако на данный момент ACPI может интересовать среднего пользователя только как теоретическая архитектура. Куда интереснее основанная на нем технология OnNow, уже сегодня могущая предоставить кое-какие вполне осязаемые приятности. Ее цели: убрать задержки при включении и выключении компьютера, позволить обслуживающим приложениям, таким как дефрагментация диска или проверка на вирусы выполняться в то время, когда компьютер выключен, и вообще, улучшить общую картину энергопотребления PC.

Как же все-таки это все работает? С точки зрения ACPI, всего имеется 4 состояния PC:

  • G0 — обычное, рабочее состояние
  • G1 — suspend, спящий режим
  • G2 — soft-off, режим, когда питание отключено, но блок питания находится под напряжением, и машина готова включиться в любой момент
  • G3 — mechanical off — питание отключено напрочь

Инициатива OnNow заключается в расширении состояния G1. Вместо простого засыпания, реализованного непонятно как, вводятся 4 режима:

  • S1: (standby 1) останавливаются тактовые генераторы CPU и всей системы, но при этом состояние памяти остается неизменным. Выход из S1 осуществляется мгновенно.
  • S2: (standby 2) также останавливаются тактовые генераторы CPU и всей системы, но к тому же отключается питание кэша и CPU, а данные, хранившиеся там, сбрасываются в основную память. Включение также происходит достаточно быстро.
  • S3: (suspend-to-memory) по замыслу, именно этот режим должен был быть OnNow, но по воле разработчиков пока так не получилось. Должны обесточиваться все компоненты системы, кроме памяти, в которой сохраняются необходимые данные о состоянии CPU и кэша. Включение с восстановлением предыдущего состояния PC действительно происходит Now, то есть практически сразу.
  • S4: (suspend-to-disk) то, что реализовано в каком-то виде сейчас. Все компоненты системы обесточиваются, а данные о состоянии процессора и содержимое кэша и памяти записываются в специально отведенное место на жестком диске. При этом пробуждение может занимать значительное время.

Режим S3 (настоящий OnNow) не может быть реализован из-за того, что существующие системные платы не имеют схем разделенного питания компонентов. Поэтому, до выхода следующего поколения материнок OnNow в полном объеме реализован быть не может. Пока же, путем модификации BIOS, можно добиться только некой эмуляции — S4.

Первой же материнской платой, которая будет иметь раздельные схемы питания для своих узлов и будет, таким образом, поддерживать режим S3 станет ASUS P2B-E — модификация давно известной системной платы P2B от Asustek. Кроме возможности suspend-to-memory, кстати, P2B-E будет иметь 5 слотов PCI. В серийное производство эта плата будет запущена в ноябре текущего года.

Но вернемся к нашим баранам. Спецификацию OnNow разрабатывала небезызвестная вам фирма Microsoft. Угадайте с трех попыток, кто по этой спецификации должен стать управляющим центром компьютера по всем этим вопросам? Первые два ответа можно не считать, правильно — Windows.

Итак, дополнительно к быстрому включению и экономии электроэнергии подразумеваются следующие плюсы OnNow:

  • Автоматическое скачивание файлов из Internet и выполнение системных задач. Так, Internet’овское приложение может быть настроено для того, чтобы в 3 ночи включить компьютер, просмотреть несколько сайтов, и скачать вновь появившиеся файлы. Естественно, если оно поддерживает API OnNow. То же самое относится к таким программам, как антивирусы, резервное копирование, Scandisk, наконец.
  • Сохранение сетевых соединений. Так, при выключении компьютера, или даже при его «засыпании», сетевое соединение рвется, файлы закрываются и т.д. При возникновении подобной ситуации, приложение, написанное с учетом OnNow, автоматом выполнит автосохранение используемых файлов на локальном диске и после включения компьютера и восстановления соединения, без криков позволит пользователю продолжить работу.
  • Обработка специфических событий. Так, факс-модем способен находиться в состоянии приема 24 часа в сутки, независимо от того, включен компьютер или нет. Если он выключен, при входящем звонке модем его включит и запустит нужную программу.

В общем, я полагаю, тенденцию вы уловили. Компьютер, постоянно находящийся наготове.

Обидно, однако, что пока с практическим использованием ACPI очень дела обстоят неважно. Возьмем самое яркое видимое и единственное на данный момент проявление ACPI в Windows 98 — Hibernate (по-русски — зимняя спячка). Проще говоря, это то самое хваленое сбрасывание данных из оперативной и видеопамяти на винт, с последующим быстрым восстановлением при включении компьютера. Таким образом, у нас получается аналог спящего режима, когда к вашим услугам предоставлены всегда запущенные приложения, но с нулевым потреблением энергии. Так вот, после появления в вашем компьютере версии BIOS, поддерживающей ACPI и некоторых манипуляций с установкой Windows 98, у вас действительно в Control Panel/Power Management появится пара вожделенных пунктов:

Закладка Hibernate:

Hibernate

И соответствующий пункт в закладке Advanced:

Я уже не говорю о не так хорошо заметных проявлениях в списке системных устройств:

Device Manager

Как вам нравятся такие устройства, как ACPI System Button или Composite Power Source?

Но для появления всего этого после перепрошивки BIOS недостаточно просто переустановить Windows 98. Поддержка ACPI — опциональная, поэтому при инсталляции надо запустить SETUP с ключами /P J или же поправить реестр, добавив в ветке HKEY_LOCAL_MACHINESoftwareMicrosoftWindowsCurrent VersionDetect новую DWORD-переменную ACPIOption, установленную в 1.

Однако, небольшое но. Ох уж это но, всегда оно появляется. Как обычно, новая технология отказывается работать в Windows сразу и без ошибок. Эта печальная практика затронула и OnNow. В Windows 98 фактически он не работает. До выхода Service Pack 1 все ограничится этими красивыми, но, к сожалению, бесполезными картинками. Сегодня в Windows’98 не работают ни Hibernate, ни вообще, какие либо функции управления питанием через ACPI. Весь контроль над ними берет на себя APM. Взять тот же Composite Power Source (по-русски говоря, — блок питания в корпусе): при входе в спящий режим через ACPI он должен выключаться, а при входе через APM (сегодня) — не выключается. Улавливаете разницу в уровне контроля над железом?

Про Hibernate я вообще молчу. Там все отягощается еще и файловой системой. По крайней мере, по текущей информации, Hibernate не будет работать с FAT32. Только с FAT16. Кроме этого, для работы необходимы поддерживающие OnNow драйвера видеокарты. Пока их только делает ATI. Но и этого еще недостаточно. Многие из существующих CD ROM и SCSI-контроллеров с Hibernate также работать не могут. Остается надеяться, что к выходу SP1 (1999 год) Microsoft удастся справиться с этими проблемами. А производителям комплектующих — написать драйверы, позволяющие их продуктам корректно работать с ACPI. Уж больно не хочется видеть окно, возникающее сейчас на моем экране при попытке уйти в Suspend Mode:

:-(

Итог: любимый город может спать спокойно. По крайней мере, до 99 года, когда выйдет SP1 для Windows 98, а комплектующие и программы научатся работать в паре с ACPI.

Возможно, однако, что OnNow будет все же работать через BIOS, в обход операционной системы. Например, плате ASUS P2B-E не будет требоваться команда Windows 98 для перехода в S3 (suspend-to-memory), а уже давно вышедшая плата Aopen AX-6BC умеет делать S4 (suspend-to-disk) не пользуясь средствами операционной системы.

Понравилась статья? Поделить с друзьями:
  • Исключение unknown software exception 0xc000001d в приложении по адресу windows 10
  • Интерфейс рабочего стола windows 10 скачать
  • Искать приложение в магазине как убрать windows 10
  • Интерфейс паравиртуализации virtualbox для windows 10
  • Искать приложение в store при запуске windows 11