ACPI modules

From ArchWiki
Revision as of 21:36, 8 March 2012 by Aroko (Talk | contribs) (Normal user suffices.)

Jump to: navigation, search

This template has only maintenance purposes. For linking to local translations please use interlanguage links, see Help:i18n#Interlanguage links.


Local languages: Català – Dansk – English – Español – Esperanto – Hrvatski – Indonesia – Italiano – Lietuviškai – Magyar – Nederlands – Norsk Bokmål – Polski – Português – Slovenský – Česky – Ελληνικά – Български – Русский – Српски – Українська – עברית – العربية – ไทย – 日本語 – 正體中文 – 简体中文 – 한국어


External languages (all articles in these languages should be moved to the external wiki): Deutsch – Français – Română – Suomi – Svenska – Tiếng Việt – Türkçe – فارسی

Summary

Since kernel 2.6.20.7, ACPI modules are all modularized to avoid ACPI issues that were reported on some machines.

This is a small list and summary of ACPI kernel modules, that enable special ACPI functions or add information to /proc or /sys, that can be parsed by acpid for events or other monitoring applications.

Note: Using /proc to store ACPI information has been discouraged and deprecated since 2.6.24. The same data is available in /sys now and interested parties can (should) subscribe to ACPI events from the kernel via netlink. To read out battery information you can simply run

acpi -i

Which modules are available?

  • ac (power connector status) => autoloaded during boot initscripts-0.8-7!
  • asus-laptop (useful on ASUS/medion laptops)
  • battery (battery status) => autoloaded during boot initscripts-0.8-7!
  • bay (bay status)
  • button (catch button events, like LID or POWER BUTTON) => autoloaded during boot initscripts-0.8-7!
  • container (container status)
  • dock (docking station status)
  • fan (fan status) => autoloaded during boot initscripts-0.8-7
  • i2c_ec (EC SMBUs driver)
  • ibm_acpi (useful on IBM laptops) (thinkpad_acpi since 2.6.22)
  • processor (processor status) => built into kernel 2.6.20.7-2!
  • sbs (smart battery status)
  • thermal (status of thermal sensors) => built into kernel 2.6.20.7-2!
  • toshiba_acpi (useful for Toshiba laptops)
  • video (status of video devices)

complete list of your running kernel:

$ ls -l /lib/modules/$(uname -r)/kernel/drivers/acpi
total 112
-rw-r--r-- 1 root root  2808 Aug 29 23:58 ac.ko.gz
-rw-r--r-- 1 root root  3021 Aug 29 23:58 acpi_ipmi.ko.gz
-rw-r--r-- 1 root root  3354 Aug 29 23:58 acpi_memhotplug.ko.gz
-rw-r--r-- 1 root root  4628 Aug 29 23:58 acpi_pad.ko.gz
drwxr-xr-x 2 root root  4096 Aug 29 23:59 apei
-rw-r--r-- 1 root root  7120 Aug 29 23:58 battery.ko.gz
-rw-r--r-- 1 root root  3700 Aug 29 23:58 button.ko.gz
-rw-r--r-- 1 root root  2181 Aug 29 23:58 container.ko.gz
-rw-r--r-- 1 root root  1525 Aug 29 23:58 custom_method.ko.gz
-rw-r--r-- 1 root root  1909 Aug 29 23:58 ec_sys.ko.gz
-rw-r--r-- 1 root root  2001 Aug 29 23:58 fan.ko.gz
-rw-r--r-- 1 root root  1532 Aug 29 23:58 hed.ko.gz
-rw-r--r-- 1 root root  3241 Aug 29 23:58 pci_slot.ko.gz
-rw-r--r-- 1 root root 17742 Aug 29 23:58 processor.ko.gz
-rw-r--r-- 1 root root  3073 Aug 29 23:58 sbshc.ko.gz
-rw-r--r-- 1 root root  7098 Aug 29 23:58 sbs.ko.gz
-rw-r--r-- 1 root root  6311 Aug 29 23:58 thermal.ko.gz
-rw-r--r-- 1 root root  8891 Aug 29 23:58 video.ko.gz

How to select the correct ones

You have to try yourself which module works for your machine:

# modprobe <yourmodule>

then check if the module is supported on your hardware by using

$ dmesg
Tip: It may help to add a grep text search to narrow your results.
[blue@wanders ~]$ dmesg | grep acpi
[    0.000000] ACPI: LAPIC (acpi_id[0x00] lapic_id[0x00] enabled)
[    0.000000] ACPI: LAPIC (acpi_id[0x01] lapic_id[0x04] enabled)
[    0.000000] ACPI: LAPIC (acpi_id[0x02] lapic_id[0x01] enabled)
[    0.000000] ACPI: LAPIC (acpi_id[0x03] lapic_id[0x05] enabled)
[    0.000000] ACPI: LAPIC_NMI (acpi_id[0x00] high edge lint[0x1])
[    0.000000] ACPI: LAPIC_NMI (acpi_id[0x01] high edge lint[0x1])
[    0.000000] ACPI: LAPIC_NMI (acpi_id[0x02] high edge lint[0x1])
[    0.000000] ACPI: LAPIC_NMI (acpi_id[0x03] high edge lint[0x1])
[    5.066752] ACPI: acpi_idle yielding to intel_idle
[    5.438998] acpi device:04: registered as cooling_device4

Add the working ones to your MODULES=() array in /etc/rc.conf

On laptops, basically these ones should work:

  • ac
  • battery
  • button
  • fan

On desktops/servers, this one should work:

  • button

Updates since 2.6.24

/proc is being deprecated, so you will find the information again in sysfs. E.g for battery:

/sys/class/power_supply/BAT0/

Troubleshooting

DSDT fix

If problems with power management persist despite having loaded the proper modules, a Linux-unfriendly DSDT might be the cause. See the wiki article on DSDT.

ACPI fix for notebook

Sometimes you see ACPI: EC: input buffer is not empty, aborting transaction, it is problem with acpi: there are two way:

1. "Easy" acpi=off in kernel line in menu.lst (if using GRUB), but you kill all acpi function like battery charge.

2. "Hard" build your kernel with patch bugs.launchpad.net.