diff options
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/DocBook/kernel-api.tmpl | 6 | ||||
-rw-r--r-- | Documentation/kernel-parameters.txt | 32 | ||||
-rw-r--r-- | Documentation/networking/bcm43xx.txt | 97 | ||||
-rw-r--r-- | Documentation/sony-laptop.txt | 25 | ||||
-rw-r--r-- | Documentation/thinkpad-acpi.txt (renamed from Documentation/ibm-acpi.txt) | 585 | ||||
-rw-r--r-- | Documentation/video4linux/meye.txt | 7 |
6 files changed, 548 insertions, 204 deletions
diff --git a/Documentation/DocBook/kernel-api.tmpl b/Documentation/DocBook/kernel-api.tmpl index 0bb90237e230..b61dfc79e1b8 100644 --- a/Documentation/DocBook/kernel-api.tmpl +++ b/Documentation/DocBook/kernel-api.tmpl | |||
@@ -236,6 +236,12 @@ X!Ilib/string.c | |||
236 | !Enet/core/dev.c | 236 | !Enet/core/dev.c |
237 | !Enet/ethernet/eth.c | 237 | !Enet/ethernet/eth.c |
238 | !Iinclude/linux/etherdevice.h | 238 | !Iinclude/linux/etherdevice.h |
239 | !Edrivers/net/phy/phy.c | ||
240 | !Idrivers/net/phy/phy.c | ||
241 | !Edrivers/net/phy/phy_device.c | ||
242 | !Idrivers/net/phy/phy_device.c | ||
243 | !Edrivers/net/phy/mdio_bus.c | ||
244 | !Idrivers/net/phy/mdio_bus.c | ||
239 | <!-- FIXME: Removed for now since no structured comments in source | 245 | <!-- FIXME: Removed for now since no structured comments in source |
240 | X!Enet/core/wireless.c | 246 | X!Enet/core/wireless.c |
241 | --> | 247 | --> |
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt index 2017942e0966..84c3bd05c639 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt | |||
@@ -181,19 +181,41 @@ and is between 256 and 4096 characters. It is defined in the file | |||
181 | that require a timer override, but don't have | 181 | that require a timer override, but don't have |
182 | HPET | 182 | HPET |
183 | 183 | ||
184 | acpi_dbg_layer= [HW,ACPI] | 184 | acpi.debug_layer= [HW,ACPI] |
185 | Format: <int> | 185 | Format: <int> |
186 | Each bit of the <int> indicates an ACPI debug layer, | 186 | Each bit of the <int> indicates an ACPI debug layer, |
187 | 1: enable, 0: disable. It is useful for boot time | 187 | 1: enable, 0: disable. It is useful for boot time |
188 | debugging. After system has booted up, it can be set | 188 | debugging. After system has booted up, it can be set |
189 | via /proc/acpi/debug_layer. | 189 | via /sys/module/acpi/parameters/debug_layer. |
190 | 190 | CONFIG_ACPI_DEBUG must be enabled for this to produce any output. | |
191 | acpi_dbg_level= [HW,ACPI] | 191 | Available bits (add the numbers together) to enable debug output |
192 | for specific parts of the ACPI subsystem: | ||
193 | 0x01 utilities 0x02 hardware 0x04 events 0x08 tables | ||
194 | 0x10 namespace 0x20 parser 0x40 dispatcher | ||
195 | 0x80 executer 0x100 resources 0x200 acpica debugger | ||
196 | 0x400 os services 0x800 acpica disassembler. | ||
197 | The number can be in decimal or prefixed with 0x in hex. | ||
198 | Warning: Many of these options can produce a lot of | ||
199 | output and make your system unusable. Be very careful. | ||
200 | |||
201 | acpi.debug_level= [HW,ACPI] | ||
192 | Format: <int> | 202 | Format: <int> |
193 | Each bit of the <int> indicates an ACPI debug level, | 203 | Each bit of the <int> indicates an ACPI debug level, |
194 | 1: enable, 0: disable. It is useful for boot time | 204 | 1: enable, 0: disable. It is useful for boot time |
195 | debugging. After system has booted up, it can be set | 205 | debugging. After system has booted up, it can be set |
196 | via /proc/acpi/debug_level. | 206 | via /sys/module/acpi/parameters/debug_level. |
207 | CONFIG_ACPI_DEBUG must be enabled for this to produce any output. | ||
208 | Available bits (add the numbers together) to enable different | ||
209 | debug output levels of the ACPI subsystem: | ||
210 | 0x01 error 0x02 warn 0x04 init 0x08 debug object | ||
211 | 0x10 info 0x20 init names 0x40 parse 0x80 load | ||
212 | 0x100 dispatch 0x200 execute 0x400 names 0x800 operation region | ||
213 | 0x1000 bfield 0x2000 tables 0x4000 values 0x8000 objects | ||
214 | 0x10000 resources 0x20000 user requests 0x40000 package. | ||
215 | The number can be in decimal or prefixed with 0x in hex. | ||
216 | Warning: Many of these options can produce a lot of | ||
217 | output and make your system unusable. Be very careful. | ||
218 | |||
197 | 219 | ||
198 | acpi_fake_ecdt [HW,ACPI] Workaround failure due to BIOS lacking ECDT | 220 | acpi_fake_ecdt [HW,ACPI] Workaround failure due to BIOS lacking ECDT |
199 | 221 | ||
diff --git a/Documentation/networking/bcm43xx.txt b/Documentation/networking/bcm43xx.txt index 28541d2bee1e..a136721499bf 100644 --- a/Documentation/networking/bcm43xx.txt +++ b/Documentation/networking/bcm43xx.txt | |||
@@ -2,35 +2,88 @@ | |||
2 | BCM43xx Linux Driver Project | 2 | BCM43xx Linux Driver Project |
3 | ============================ | 3 | ============================ |
4 | 4 | ||
5 | About this software | 5 | Introduction |
6 | ------------------- | 6 | ------------ |
7 | 7 | ||
8 | The goal of this project is to develop a linux driver for Broadcom | 8 | Many of the wireless devices found in modern notebook computers are |
9 | BCM43xx chips, based on the specification at | 9 | based on the wireless chips produced by Broadcom. These devices have |
10 | http://bcm-specs.sipsolutions.net/ | 10 | been a problem for Linux users as there is no open-source driver |
11 | available. In addition, Broadcom has not released specifications | ||
12 | for the device, and driver availability has been limited to the | ||
13 | binary-only form used in the GPL versions of AP hardware such as the | ||
14 | Linksys WRT54G, and the Windows and OS X drivers. Before this project | ||
15 | began, the only way to use these devices were to use the Windows or | ||
16 | OS X drivers with either the Linuxant or ndiswrapper modules. There | ||
17 | is a strong penalty if this method is used as loading the binary-only | ||
18 | module "taints" the kernel, and no kernel developer will help diagnose | ||
19 | any kernel problems. | ||
11 | 20 | ||
12 | The project page is http://bcm43xx.berlios.de/ | 21 | Development |
22 | ----------- | ||
13 | 23 | ||
24 | This driver has been developed using | ||
25 | a clean-room technique that is described at | ||
26 | http://bcm-specs.sipsolutions.net/ReverseEngineeringProcess. For legal | ||
27 | reasons, none of the clean-room crew works on the on the Linux driver, | ||
28 | and none of the Linux developers sees anything but the specifications, | ||
29 | which are the ultimate product of the reverse-engineering group. | ||
14 | 30 | ||
15 | Requirements | 31 | Software |
16 | ------------ | 32 | -------- |
33 | |||
34 | Since the release of the 2.6.17 kernel, the bcm43xx driver has been | ||
35 | distributed with the kernel source, and is prebuilt in most, if not | ||
36 | all, distributions. There is, however, additional software that is | ||
37 | required. The firmware used by the chip is the intellectual property | ||
38 | of Broadcom and they have not given the bcm43xx team redistribution | ||
39 | rights to this firmware. Since we cannot legally redistribute | ||
40 | the firwmare we cannot include it with the driver. Furthermore, it | ||
41 | cannot be placed in the downloadable archives of any distributing | ||
42 | organization; therefore, the user is responsible for obtaining the | ||
43 | firmware and placing it in the appropriate location so that the driver | ||
44 | can find it when initializing. | ||
45 | |||
46 | To help with this process, the bcm43xx developers provide a separate | ||
47 | program named bcm43xx-fwcutter to "cut" the firmware out of a | ||
48 | Windows or OS X driver and write the extracted files to the proper | ||
49 | location. This program is usually provided with the distribution; | ||
50 | however, it may be downloaded from | ||
51 | |||
52 | http://developer.berlios.de/project/showfiles.php?group_id=4547 | ||
17 | 53 | ||
18 | 1) Linux Kernel 2.6.16 or later | 54 | The firmware is available in two versions. V3 firmware is used with |
19 | http://www.kernel.org/ | 55 | the in-kernel bcm43xx driver that uses a software MAC layer called |
56 | SoftMAC, and will have a microcode revision of 0x127 or smaller. The | ||
57 | V4 firmware is used by an out-of-kernel driver employing a variation of | ||
58 | the Devicescape MAC layer known as d80211. Once bcm43xx-d80211 reaches | ||
59 | a satisfactory level of development, it will replace bcm43xx-softmac | ||
60 | in the kernel as it is much more flexible and powerful. | ||
20 | 61 | ||
21 | You may want to configure your kernel with: | 62 | A source for the latest V3 firmware is |
22 | 63 | ||
23 | CONFIG_DEBUG_FS (optional): | 64 | http://downloads.openwrt.org/sources/wl_apsta-3.130.20.0.o |
24 | -> Kernel hacking | ||
25 | -> Debug Filesystem | ||
26 | 65 | ||
27 | 2) SoftMAC IEEE 802.11 Networking Stack extension and patched ieee80211 | 66 | Once this file is downloaded, the command |
28 | modules: | 67 | 'bcm43xx-fwcutter -w <dir> <filename>' |
29 | http://softmac.sipsolutions.net/ | 68 | will extract the microcode and write it to directory |
69 | <dir>. The correct directory will depend on your distribution; | ||
70 | however, most use '/lib/firmware'. Once this step is completed, | ||
71 | the bcm3xx driver should load when the system is booted. To see | ||
72 | any messages relating to the driver, issue the command 'dmesg | | ||
73 | grep bcm43xx' from a terminal window. If there are any problems, | ||
74 | please send that output to Bcm43xx-dev@lists.berlios.de. | ||
30 | 75 | ||
31 | 3) Firmware Files | 76 | Although the driver has been in-kernel since 2.6.17, the earliest |
77 | version is quite limited in its capability. Patches that include | ||
78 | all features of later versions are available for the stable kernel | ||
79 | versions from 2.6.18. These will be needed if you use a BCM4318, | ||
80 | or a PCI Express version (BCM4311 and BCM4312). In addition, if you | ||
81 | have an early BCM4306 and more than 1 GB RAM, your kernel will need | ||
82 | to be patched. These patches, which are being updated regularly, | ||
83 | are available at ftp://lwfinger.dynalias.org/patches. Look for | ||
84 | combined_2.6.YY.patch. Of course you will need kernel source downloaded | ||
85 | from kernel.org, or the source from your distribution. | ||
32 | 86 | ||
33 | Please try fwcutter. Fwcutter can extract the firmware from various | 87 | If you build your own kernel, please enable CONFIG_BCM43XX_DEBUG |
34 | binary driver files. It supports driver files from Windows, MacOS and | 88 | and CONFIG_IEEE80211_SOFTMAC_DEBUG. The log information provided is |
35 | Linux. You can get fwcutter from http://bcm43xx.berlios.de/. | 89 | essential for solving any problems. |
36 | Also, fwcutter comes with a README file for further instructions. | ||
diff --git a/Documentation/sony-laptop.txt b/Documentation/sony-laptop.txt index dfd26df056f4..7a5c1a81905c 100644 --- a/Documentation/sony-laptop.txt +++ b/Documentation/sony-laptop.txt | |||
@@ -3,12 +3,18 @@ Sony Notebook Control Driver (SNC) Readme | |||
3 | Copyright (C) 2004- 2005 Stelian Pop <stelian@popies.net> | 3 | Copyright (C) 2004- 2005 Stelian Pop <stelian@popies.net> |
4 | Copyright (C) 2007 Mattia Dongili <malattia@linux.it> | 4 | Copyright (C) 2007 Mattia Dongili <malattia@linux.it> |
5 | 5 | ||
6 | This mini-driver drives the SNC device present in the ACPI BIOS of | 6 | This mini-driver drives the SNC and SPIC device present in the ACPI BIOS of the |
7 | the Sony Vaio laptops. | 7 | Sony Vaio laptops. This driver mixes both devices functions under the same |
8 | (hopefully consistent) interface. This also means that the sonypi driver is | ||
9 | obsoleted by sony-laptop now. | ||
8 | 10 | ||
9 | It gives access to some extra laptop functionalities. In its current | 11 | Fn keys (hotkeys): |
10 | form, this driver let the user set or query the screen brightness | 12 | ------------------ |
11 | through the backlight subsystem and remove/apply power to some devices. | 13 | Some models report hotkeys through the SNC or SPIC devices, such events are |
14 | reported both through the ACPI subsystem as acpi events and through the INPUT | ||
15 | subsystem. See the logs of acpid or /proc/acpi/event and | ||
16 | /proc/bus/input/devices to find out what those events are and which input | ||
17 | devices are created by the driver. | ||
12 | 18 | ||
13 | Backlight control: | 19 | Backlight control: |
14 | ------------------ | 20 | ------------------ |
@@ -39,6 +45,8 @@ The files are: | |||
39 | audiopower power on/off the internal sound card | 45 | audiopower power on/off the internal sound card |
40 | lanpower power on/off the internal ethernet card | 46 | lanpower power on/off the internal ethernet card |
41 | (only in debug mode) | 47 | (only in debug mode) |
48 | bluetoothpower power on/off the internal bluetooth device | ||
49 | fanspeed get/set the fan speed | ||
42 | 50 | ||
43 | Note that some files may be missing if they are not supported | 51 | Note that some files may be missing if they are not supported |
44 | by your particular laptop model. | 52 | by your particular laptop model. |
@@ -76,9 +84,9 @@ The sony-laptop driver creates, for some of those methods (the most | |||
76 | current ones found on several Vaio models), an entry under | 84 | current ones found on several Vaio models), an entry under |
77 | /sys/devices/platform/sony-laptop, just like the 'cdpower' one. | 85 | /sys/devices/platform/sony-laptop, just like the 'cdpower' one. |
78 | You can create other entries corresponding to your own laptop methods by | 86 | You can create other entries corresponding to your own laptop methods by |
79 | further editing the source (see the 'sony_acpi_values' table, and add a new | 87 | further editing the source (see the 'sony_nc_values' table, and add a new |
80 | entry to this table with your get/set method names using the | 88 | entry to this table with your get/set method names using the |
81 | HANDLE_NAMES macro). | 89 | SNC_HANDLE_NAMES macro). |
82 | 90 | ||
83 | Your mission, should you accept it, is to try finding out what | 91 | Your mission, should you accept it, is to try finding out what |
84 | those entries are for, by reading/writing random values from/to those | 92 | those entries are for, by reading/writing random values from/to those |
@@ -87,6 +95,9 @@ files and find out what is the impact on your laptop. | |||
87 | Should you find anything interesting, please report it back to me, | 95 | Should you find anything interesting, please report it back to me, |
88 | I will not disavow all knowledge of your actions :) | 96 | I will not disavow all knowledge of your actions :) |
89 | 97 | ||
98 | See also http://www.linux.it/~malattia/wiki/index.php/Sony_drivers for other | ||
99 | useful info. | ||
100 | |||
90 | Bugs/Limitations: | 101 | Bugs/Limitations: |
91 | ----------------- | 102 | ----------------- |
92 | 103 | ||
diff --git a/Documentation/ibm-acpi.txt b/Documentation/thinkpad-acpi.txt index 0132d363feb5..2d4803359a04 100644 --- a/Documentation/ibm-acpi.txt +++ b/Documentation/thinkpad-acpi.txt | |||
@@ -1,16 +1,22 @@ | |||
1 | IBM ThinkPad ACPI Extras Driver | 1 | ThinkPad ACPI Extras Driver |
2 | 2 | ||
3 | Version 0.12 | 3 | Version 0.14 |
4 | 17 August 2005 | 4 | April 21st, 2007 |
5 | 5 | ||
6 | Borislav Deianov <borislav@users.sf.net> | 6 | Borislav Deianov <borislav@users.sf.net> |
7 | Henrique de Moraes Holschuh <hmh@hmh.eng.br> | ||
7 | http://ibm-acpi.sf.net/ | 8 | http://ibm-acpi.sf.net/ |
8 | 9 | ||
9 | 10 | ||
10 | This is a Linux ACPI driver for the IBM ThinkPad laptops. It supports | 11 | This is a Linux driver for the IBM and Lenovo ThinkPad laptops. It |
11 | various features of these laptops which are accessible through the | 12 | supports various features of these laptops which are accessible |
12 | ACPI framework but not otherwise supported by the generic Linux ACPI | 13 | through the ACPI and ACPI EC framework, but not otherwise fully |
13 | drivers. | 14 | supported by the generic Linux ACPI drivers. |
15 | |||
16 | This driver used to be named ibm-acpi until kernel 2.6.21 and release | ||
17 | 0.13-20070314. It used to be in the drivers/acpi tree, but it was | ||
18 | moved to the drivers/misc tree and renamed to thinkpad-acpi for kernel | ||
19 | 2.6.22, and release 0.14. | ||
14 | 20 | ||
15 | 21 | ||
16 | Status | 22 | Status |
@@ -21,7 +27,7 @@ detailed description): | |||
21 | 27 | ||
22 | - Fn key combinations | 28 | - Fn key combinations |
23 | - Bluetooth enable and disable | 29 | - Bluetooth enable and disable |
24 | - video output switching, expansion control | 30 | - video output switching, expansion control |
25 | - ThinkLight on and off | 31 | - ThinkLight on and off |
26 | - limited docking and undocking | 32 | - limited docking and undocking |
27 | - UltraBay eject | 33 | - UltraBay eject |
@@ -32,7 +38,7 @@ detailed description): | |||
32 | - Experimental: embedded controller register dump | 38 | - Experimental: embedded controller register dump |
33 | - LCD brightness control | 39 | - LCD brightness control |
34 | - Volume control | 40 | - Volume control |
35 | - Experimental: fan speed, fan enable/disable | 41 | - Fan control and monitoring: fan speed, fan enable/disable |
36 | - Experimental: WAN enable and disable | 42 | - Experimental: WAN enable and disable |
37 | 43 | ||
38 | A compatibility table by model and feature is maintained on the web | 44 | A compatibility table by model and feature is maintained on the web |
@@ -42,6 +48,8 @@ Please include the following information in your report: | |||
42 | 48 | ||
43 | - ThinkPad model name | 49 | - ThinkPad model name |
44 | - a copy of your DSDT, from /proc/acpi/dsdt | 50 | - a copy of your DSDT, from /proc/acpi/dsdt |
51 | - a copy of the output of dmidecode, with serial numbers | ||
52 | and UUIDs masked off | ||
45 | - which driver features work and which don't | 53 | - which driver features work and which don't |
46 | - the observed behavior of non-working features | 54 | - the observed behavior of non-working features |
47 | 55 | ||
@@ -52,25 +60,85 @@ Installation | |||
52 | ------------ | 60 | ------------ |
53 | 61 | ||
54 | If you are compiling this driver as included in the Linux kernel | 62 | If you are compiling this driver as included in the Linux kernel |
55 | sources, simply enable the CONFIG_ACPI_IBM option (Power Management / | 63 | sources, simply enable the CONFIG_THINKPAD_ACPI option, and optionally |
56 | ACPI / IBM ThinkPad Laptop Extras). | 64 | enable the CONFIG_THINKPAD_ACPI_BAY option if you want the |
65 | thinkpad-specific bay functionality. | ||
57 | 66 | ||
58 | Features | 67 | Features |
59 | -------- | 68 | -------- |
60 | 69 | ||
61 | The driver creates the /proc/acpi/ibm directory. There is a file under | 70 | The driver exports two different interfaces to userspace, which can be |
62 | that directory for each feature described below. Note that while the | 71 | used to access the features it provides. One is a legacy procfs-based |
63 | driver is still in the alpha stage, the exact proc file format and | 72 | interface, which will be removed at some time in the distant future. |
64 | commands supported by the various features is guaranteed to change | 73 | The other is a new sysfs-based interface which is not complete yet. |
65 | frequently. | ||
66 | 74 | ||
67 | Driver version -- /proc/acpi/ibm/driver | 75 | The procfs interface creates the /proc/acpi/ibm directory. There is a |
68 | --------------------------------------- | 76 | file under that directory for each feature it supports. The procfs |
77 | interface is mostly frozen, and will change very little if at all: it | ||
78 | will not be extended to add any new functionality in the driver, instead | ||
79 | all new functionality will be implemented on the sysfs interface. | ||
80 | |||
81 | The sysfs interface tries to blend in the generic Linux sysfs subsystems | ||
82 | and classes as much as possible. Since some of these subsystems are not | ||
83 | yet ready or stabilized, it is expected that this interface will change, | ||
84 | and any and all userspace programs must deal with it. | ||
85 | |||
86 | |||
87 | Notes about the sysfs interface: | ||
88 | |||
89 | Unlike what was done with the procfs interface, correctness when talking | ||
90 | to the sysfs interfaces will be enforced, as will correctness in the | ||
91 | thinkpad-acpi's implementation of sysfs interfaces. | ||
92 | |||
93 | Also, any bugs in the thinkpad-acpi sysfs driver code or in the | ||
94 | thinkpad-acpi's implementation of the sysfs interfaces will be fixed for | ||
95 | maximum correctness, even if that means changing an interface in | ||
96 | non-compatible ways. As these interfaces mature both in the kernel and | ||
97 | in thinkpad-acpi, such changes should become quite rare. | ||
98 | |||
99 | Applications interfacing to the thinkpad-acpi sysfs interfaces must | ||
100 | follow all sysfs guidelines and correctly process all errors (the sysfs | ||
101 | interface makes extensive use of errors). File descriptors and open / | ||
102 | close operations to the sysfs inodes must also be properly implemented. | ||
103 | |||
104 | The version of thinkpad-acpi's sysfs interface is exported by the driver | ||
105 | as a driver attribute (see below). | ||
106 | |||
107 | Sysfs driver attributes are on the driver's sysfs attribute space, | ||
108 | for 2.6.20 this is /sys/bus/platform/drivers/thinkpad-acpi/. | ||
109 | |||
110 | Sysfs device attributes are on the driver's sysfs attribute space, | ||
111 | for 2.6.20 this is /sys/devices/platform/thinkpad-acpi/. | ||
112 | |||
113 | Driver version | ||
114 | -------------- | ||
115 | |||
116 | procfs: /proc/acpi/ibm/driver | ||
117 | sysfs driver attribute: version | ||
69 | 118 | ||
70 | The driver name and version. No commands can be written to this file. | 119 | The driver name and version. No commands can be written to this file. |
71 | 120 | ||
72 | Hot keys -- /proc/acpi/ibm/hotkey | 121 | Sysfs interface version |
73 | --------------------------------- | 122 | ----------------------- |
123 | |||
124 | sysfs driver attribute: interface_version | ||
125 | |||
126 | Version of the thinkpad-acpi sysfs interface, as an unsigned long | ||
127 | (output in hex format: 0xAAAABBCC), where: | ||
128 | AAAA - major revision | ||
129 | BB - minor revision | ||
130 | CC - bugfix revision | ||
131 | |||
132 | The sysfs interface version changelog for the driver can be found at the | ||
133 | end of this document. Changes to the sysfs interface done by the kernel | ||
134 | subsystems are not documented here, nor are they tracked by this | ||
135 | attribute. | ||
136 | |||
137 | Hot keys | ||
138 | -------- | ||
139 | |||
140 | procfs: /proc/acpi/ibm/hotkey | ||
141 | sysfs device attribute: hotkey/* | ||
74 | 142 | ||
75 | Without this driver, only the Fn-F4 key (sleep button) generates an | 143 | Without this driver, only the Fn-F4 key (sleep button) generates an |
76 | ACPI event. With the driver loaded, the hotkey feature enabled and the | 144 | ACPI event. With the driver loaded, the hotkey feature enabled and the |
@@ -84,15 +152,6 @@ All labeled Fn-Fx key combinations generate distinct events. In | |||
84 | addition, the lid microswitch and some docking station buttons may | 152 | addition, the lid microswitch and some docking station buttons may |
85 | also generate such events. | 153 | also generate such events. |
86 | 154 | ||
87 | The following commands can be written to this file: | ||
88 | |||
89 | echo enable > /proc/acpi/ibm/hotkey -- enable the hot keys feature | ||
90 | echo disable > /proc/acpi/ibm/hotkey -- disable the hot keys feature | ||
91 | echo 0xffff > /proc/acpi/ibm/hotkey -- enable all possible hot keys | ||
92 | echo 0x0000 > /proc/acpi/ibm/hotkey -- disable all possible hot keys | ||
93 | ... any other 4-hex-digit mask ... | ||
94 | echo reset > /proc/acpi/ibm/hotkey -- restore the original mask | ||
95 | |||
96 | The bit mask allows some control over which hot keys generate ACPI | 155 | The bit mask allows some control over which hot keys generate ACPI |
97 | events. Not all bits in the mask can be modified. Not all bits that | 156 | events. Not all bits in the mask can be modified. Not all bits that |
98 | can be modified do anything. Not all hot keys can be individually | 157 | can be modified do anything. Not all hot keys can be individually |
@@ -124,15 +183,77 @@ buttons do not generate ACPI events even with this driver. They *can* | |||
124 | be used through the "ThinkPad Buttons" utility, see | 183 | be used through the "ThinkPad Buttons" utility, see |
125 | http://www.nongnu.org/tpb/ | 184 | http://www.nongnu.org/tpb/ |
126 | 185 | ||
127 | Bluetooth -- /proc/acpi/ibm/bluetooth | 186 | procfs notes: |
128 | ------------------------------------- | 187 | |
188 | The following commands can be written to the /proc/acpi/ibm/hotkey file: | ||
189 | |||
190 | echo enable > /proc/acpi/ibm/hotkey -- enable the hot keys feature | ||
191 | echo disable > /proc/acpi/ibm/hotkey -- disable the hot keys feature | ||
192 | echo 0xffff > /proc/acpi/ibm/hotkey -- enable all possible hot keys | ||
193 | echo 0x0000 > /proc/acpi/ibm/hotkey -- disable all possible hot keys | ||
194 | ... any other 4-hex-digit mask ... | ||
195 | echo reset > /proc/acpi/ibm/hotkey -- restore the original mask | ||
196 | |||
197 | sysfs notes: | ||
198 | |||
199 | The hot keys attributes are in a hotkey/ subdirectory off the | ||
200 | thinkpad device. | ||
201 | |||
202 | bios_enabled: | ||
203 | Returns the status of the hot keys feature when | ||
204 | thinkpad-acpi was loaded. Upon module unload, the hot | ||
205 | key feature status will be restored to this value. | ||
206 | |||
207 | 0: hot keys were disabled | ||
208 | 1: hot keys were enabled | ||
209 | |||
210 | bios_mask: | ||
211 | Returns the hot keys mask when thinkpad-acpi was loaded. | ||
212 | Upon module unload, the hot keys mask will be restored | ||
213 | to this value. | ||
214 | |||
215 | enable: | ||
216 | Enables/disables the hot keys feature, and reports | ||
217 | current status of the hot keys feature. | ||
218 | |||
219 | 0: disables the hot keys feature / feature disabled | ||
220 | 1: enables the hot keys feature / feature enabled | ||
221 | |||
222 | mask: | ||
223 | bit mask to enable ACPI event generation for each hot | ||
224 | key (see above). Returns the current status of the hot | ||
225 | keys mask, and allows one to modify it. | ||
226 | |||
129 | 227 | ||
130 | This feature shows the presence and current state of a Bluetooth | 228 | Bluetooth |
131 | device. If Bluetooth is installed, the following commands can be used: | 229 | --------- |
230 | |||
231 | procfs: /proc/acpi/ibm/bluetooth | ||
232 | sysfs device attribute: bluetooth/enable | ||
233 | |||
234 | This feature shows the presence and current state of a ThinkPad | ||
235 | Bluetooth device in the internal ThinkPad CDC slot. | ||
236 | |||
237 | Procfs notes: | ||
238 | |||
239 | If Bluetooth is installed, the following commands can be used: | ||
132 | 240 | ||
133 | echo enable > /proc/acpi/ibm/bluetooth | 241 | echo enable > /proc/acpi/ibm/bluetooth |
134 | echo disable > /proc/acpi/ibm/bluetooth | 242 | echo disable > /proc/acpi/ibm/bluetooth |
135 | 243 | ||
244 | Sysfs notes: | ||
245 | |||
246 | If the Bluetooth CDC card is installed, it can be enabled / | ||
247 | disabled through the "bluetooth/enable" thinkpad-acpi device | ||
248 | attribute, and its current status can also be queried. | ||
249 | |||
250 | enable: | ||
251 | 0: disables Bluetooth / Bluetooth is disabled | ||
252 | 1: enables Bluetooth / Bluetooth is enabled. | ||
253 | |||
254 | Note: this interface will be probably be superseeded by the | ||
255 | generic rfkill class. | ||
256 | |||
136 | Video output control -- /proc/acpi/ibm/video | 257 | Video output control -- /proc/acpi/ibm/video |
137 | -------------------------------------------- | 258 | -------------------------------------------- |
138 | 259 | ||
@@ -209,7 +330,7 @@ hot plugging of devices in the Linux ACPI framework. If the laptop was | |||
209 | booted while not in the dock, the following message is shown in the | 330 | booted while not in the dock, the following message is shown in the |
210 | logs: | 331 | logs: |
211 | 332 | ||
212 | Mar 17 01:42:34 aero kernel: ibm_acpi: dock device not present | 333 | Mar 17 01:42:34 aero kernel: thinkpad_acpi: dock device not present |
213 | 334 | ||
214 | In this case, no dock-related events are generated but the dock and | 335 | In this case, no dock-related events are generated but the dock and |
215 | undock commands described below still work. They can be executed | 336 | undock commands described below still work. They can be executed |
@@ -269,7 +390,7 @@ This is due to the current lack of support for hot plugging of devices | |||
269 | in the Linux ACPI framework. If the laptop was booted without the | 390 | in the Linux ACPI framework. If the laptop was booted without the |
270 | UltraBay, the following message is shown in the logs: | 391 | UltraBay, the following message is shown in the logs: |
271 | 392 | ||
272 | Mar 17 01:42:34 aero kernel: ibm_acpi: bay device not present | 393 | Mar 17 01:42:34 aero kernel: thinkpad_acpi: bay device not present |
273 | 394 | ||
274 | In this case, no bay-related events are generated but the eject | 395 | In this case, no bay-related events are generated but the eject |
275 | command described below still works. It can be executed manually or | 396 | command described below still works. It can be executed manually or |
@@ -313,23 +434,19 @@ supported. Use "eject2" instead of "eject" for the second bay. | |||
313 | Note: the UltraBay eject support on the 600e/x, A22p and A3x is | 434 | Note: the UltraBay eject support on the 600e/x, A22p and A3x is |
314 | EXPERIMENTAL and may not work as expected. USE WITH CAUTION! | 435 | EXPERIMENTAL and may not work as expected. USE WITH CAUTION! |
315 | 436 | ||
316 | CMOS control -- /proc/acpi/ibm/cmos | 437 | CMOS control |
317 | ----------------------------------- | 438 | ------------ |
439 | |||
440 | procfs: /proc/acpi/ibm/cmos | ||
441 | sysfs device attribute: cmos_command | ||
318 | 442 | ||
319 | This feature is used internally by the ACPI firmware to control the | 443 | This feature is used internally by the ACPI firmware to control the |
320 | ThinkLight on most newer ThinkPad models. It may also control LCD | 444 | ThinkLight on most newer ThinkPad models. It may also control LCD |
321 | brightness, sounds volume and more, but only on some models. | 445 | brightness, sounds volume and more, but only on some models. |
322 | 446 | ||
323 | The commands are non-negative integer numbers: | 447 | The range of valid cmos command numbers is 0 to 21, but not all have an |
324 | 448 | effect and the behavior varies from model to model. Here is the behavior | |
325 | echo 0 >/proc/acpi/ibm/cmos | 449 | on the X40 (tpb is the ThinkPad Buttons utility): |
326 | echo 1 >/proc/acpi/ibm/cmos | ||
327 | echo 2 >/proc/acpi/ibm/cmos | ||
328 | ... | ||
329 | |||
330 | The range of valid numbers is 0 to 21, but not all have an effect and | ||
331 | the behavior varies from model to model. Here is the behavior on the | ||
332 | X40 (tpb is the ThinkPad Buttons utility): | ||
333 | 450 | ||
334 | 0 - no effect but tpb reports "Volume down" | 451 | 0 - no effect but tpb reports "Volume down" |
335 | 1 - no effect but tpb reports "Volume up" | 452 | 1 - no effect but tpb reports "Volume up" |
@@ -342,6 +459,9 @@ X40 (tpb is the ThinkPad Buttons utility): | |||
342 | 13 - ThinkLight off | 459 | 13 - ThinkLight off |
343 | 14 - no effect but tpb reports ThinkLight status change | 460 | 14 - no effect but tpb reports ThinkLight status change |
344 | 461 | ||
462 | The cmos command interface is prone to firmware split-brain problems, as | ||
463 | in newer ThinkPads it is just a compatibility layer. | ||
464 | |||
345 | LED control -- /proc/acpi/ibm/led | 465 | LED control -- /proc/acpi/ibm/led |
346 | --------------------------------- | 466 | --------------------------------- |
347 | 467 | ||
@@ -393,17 +513,17 @@ X40: | |||
393 | 16 - one medium-pitched beep repeating constantly, stop with 17 | 513 | 16 - one medium-pitched beep repeating constantly, stop with 17 |
394 | 17 - stop 16 | 514 | 17 - stop 16 |
395 | 515 | ||
396 | Temperature sensors -- /proc/acpi/ibm/thermal | 516 | Temperature sensors |
397 | --------------------------------------------- | 517 | ------------------- |
518 | |||
519 | procfs: /proc/acpi/ibm/thermal | ||
520 | sysfs device attributes: (hwmon) temp*_input | ||
398 | 521 | ||
399 | Most ThinkPads include six or more separate temperature sensors but | 522 | Most ThinkPads include six or more separate temperature sensors but |
400 | only expose the CPU temperature through the standard ACPI methods. | 523 | only expose the CPU temperature through the standard ACPI methods. |
401 | This feature shows readings from up to eight different sensors on older | 524 | This feature shows readings from up to eight different sensors on older |
402 | ThinkPads, and it has experimental support for up to sixteen different | 525 | ThinkPads, and it has experimental support for up to sixteen different |
403 | sensors on newer ThinkPads. Readings from sensors that are not available | 526 | sensors on newer ThinkPads. |
404 | return -128. | ||
405 | |||
406 | No commands can be written to this file. | ||
407 | 527 | ||
408 | EXPERIMENTAL: The 16-sensors feature is marked EXPERIMENTAL because the | 528 | EXPERIMENTAL: The 16-sensors feature is marked EXPERIMENTAL because the |
409 | implementation directly accesses hardware registers and may not work as | 529 | implementation directly accesses hardware registers and may not work as |
@@ -460,6 +580,20 @@ The A31 has a very atypical layout for the thermal sensors | |||
460 | 8: Bay Battery: secondary sensor | 580 | 8: Bay Battery: secondary sensor |
461 | 581 | ||
462 | 582 | ||
583 | Procfs notes: | ||
584 | Readings from sensors that are not available return -128. | ||
585 | No commands can be written to this file. | ||
586 | |||
587 | Sysfs notes: | ||
588 | Sensors that are not available return the ENXIO error. This | ||
589 | status may change at runtime, as there are hotplug thermal | ||
590 | sensors, like those inside the batteries and docks. | ||
591 | |||
592 | thinkpad-acpi thermal sensors are reported through the hwmon | ||
593 | subsystem, and follow all of the hwmon guidelines at | ||
594 | Documentation/hwmon. | ||
595 | |||
596 | |||
463 | EXPERIMENTAL: Embedded controller register dump -- /proc/acpi/ibm/ecdump | 597 | EXPERIMENTAL: Embedded controller register dump -- /proc/acpi/ibm/ecdump |
464 | ------------------------------------------------------------------------ | 598 | ------------------------------------------------------------------------ |
465 | 599 | ||
@@ -472,7 +606,7 @@ This feature dumps the values of 256 embedded controller | |||
472 | registers. Values which have changed since the last time the registers | 606 | registers. Values which have changed since the last time the registers |
473 | were dumped are marked with a star: | 607 | were dumped are marked with a star: |
474 | 608 | ||
475 | [root@x40 ibm-acpi]# cat /proc/acpi/ibm/ecdump | 609 | [root@x40 ibm-acpi]# cat /proc/acpi/ibm/ecdump |
476 | EC +00 +01 +02 +03 +04 +05 +06 +07 +08 +09 +0a +0b +0c +0d +0e +0f | 610 | EC +00 +01 +02 +03 +04 +05 +06 +07 +08 +09 +0a +0b +0c +0d +0e +0f |
477 | EC 0x00: a7 47 87 01 fe 96 00 08 01 00 cb 00 00 00 40 00 | 611 | EC 0x00: a7 47 87 01 fe 96 00 08 01 00 cb 00 00 00 40 00 |
478 | EC 0x10: 00 00 ff ff f4 3c 87 09 01 ff 42 01 ff ff 0d 00 | 612 | EC 0x10: 00 00 ff ff f4 3c 87 09 01 ff 42 01 ff ff 0d 00 |
@@ -503,7 +637,7 @@ vary. The second ensures that the fan-related values do vary, since | |||
503 | the fan speed fluctuates a bit. The third will (hopefully) mark the | 637 | the fan speed fluctuates a bit. The third will (hopefully) mark the |
504 | fan register with a star: | 638 | fan register with a star: |
505 | 639 | ||
506 | [root@x40 ibm-acpi]# cat /proc/acpi/ibm/ecdump | 640 | [root@x40 ibm-acpi]# cat /proc/acpi/ibm/ecdump |
507 | EC +00 +01 +02 +03 +04 +05 +06 +07 +08 +09 +0a +0b +0c +0d +0e +0f | 641 | EC +00 +01 +02 +03 +04 +05 +06 +07 +08 +09 +0a +0b +0c +0d +0e +0f |
508 | EC 0x00: a7 47 87 01 fe 96 00 08 01 00 cb 00 00 00 40 00 | 642 | EC 0x00: a7 47 87 01 fe 96 00 08 01 00 cb 00 00 00 40 00 |
509 | EC 0x10: 00 00 ff ff f4 3c 87 09 01 ff 42 01 ff ff 0d 00 | 643 | EC 0x10: 00 00 ff ff f4 3c 87 09 01 ff 42 01 ff ff 0d 00 |
@@ -533,19 +667,59 @@ registers contain the current battery capacity, etc. If you experiment | |||
533 | with this, do send me your results (including some complete dumps with | 667 | with this, do send me your results (including some complete dumps with |
534 | a description of the conditions when they were taken.) | 668 | a description of the conditions when they were taken.) |
535 | 669 | ||
536 | LCD brightness control -- /proc/acpi/ibm/brightness | 670 | LCD brightness control |
537 | --------------------------------------------------- | 671 | ---------------------- |
672 | |||
673 | procfs: /proc/acpi/ibm/brightness | ||
674 | sysfs backlight device "thinkpad_screen" | ||
538 | 675 | ||
539 | This feature allows software control of the LCD brightness on ThinkPad | 676 | This feature allows software control of the LCD brightness on ThinkPad |
540 | models which don't have a hardware brightness slider. The available | 677 | models which don't have a hardware brightness slider. |
541 | commands are: | 678 | |
679 | It has some limitations: the LCD backlight cannot be actually turned on or off | ||
680 | by this interface, and in many ThinkPad models, the "dim while on battery" | ||
681 | functionality will be enabled by the BIOS when this interface is used, and | ||
682 | cannot be controlled. | ||
683 | |||
684 | The backlight control has eight levels, ranging from 0 to 7. Some of the | ||
685 | levels may not be distinct. | ||
686 | |||
687 | Procfs notes: | ||
688 | |||
689 | The available commands are: | ||
542 | 690 | ||
543 | echo up >/proc/acpi/ibm/brightness | 691 | echo up >/proc/acpi/ibm/brightness |
544 | echo down >/proc/acpi/ibm/brightness | 692 | echo down >/proc/acpi/ibm/brightness |
545 | echo 'level <level>' >/proc/acpi/ibm/brightness | 693 | echo 'level <level>' >/proc/acpi/ibm/brightness |
546 | 694 | ||
547 | The <level> number range is 0 to 7, although not all of them may be | 695 | Sysfs notes: |
548 | distinct. The current brightness level is shown in the file. | 696 | |
697 | The interface is implemented through the backlight sysfs class, which is poorly | ||
698 | documented at this time. | ||
699 | |||
700 | Locate the thinkpad_screen device under /sys/class/backlight, and inside it | ||
701 | there will be the following attributes: | ||
702 | |||
703 | max_brightness: | ||
704 | Reads the maximum brightness the hardware can be set to. | ||
705 | The minimum is always zero. | ||
706 | |||
707 | actual_brightness: | ||
708 | Reads what brightness the screen is set to at this instant. | ||
709 | |||
710 | brightness: | ||
711 | Writes request the driver to change brightness to the given | ||
712 | value. Reads will tell you what brightness the driver is trying | ||
713 | to set the display to when "power" is set to zero and the display | ||
714 | has not been dimmed by a kernel power management event. | ||
715 | |||
716 | power: | ||
717 | power management mode, where 0 is "display on", and 1 to 3 will | ||
718 | dim the display backlight to brightness level 0 because | ||
719 | thinkpad-acpi cannot really turn the backlight off. Kernel | ||
720 | power management events can temporarily increase the current | ||
721 | power management level, i.e. they can dim the display. | ||
722 | |||
549 | 723 | ||
550 | Volume control -- /proc/acpi/ibm/volume | 724 | Volume control -- /proc/acpi/ibm/volume |
551 | --------------------------------------- | 725 | --------------------------------------- |
@@ -563,41 +737,42 @@ distinct. The unmute the volume after the mute command, use either the | |||
563 | up or down command (the level command will not unmute the volume). | 737 | up or down command (the level command will not unmute the volume). |
564 | The current volume level and mute state is shown in the file. | 738 | The current volume level and mute state is shown in the file. |
565 | 739 | ||
566 | EXPERIMENTAL: fan speed, fan enable/disable -- /proc/acpi/ibm/fan | 740 | Fan control and monitoring: fan speed, fan enable/disable |
567 | ----------------------------------------------------------------- | 741 | --------------------------------------------------------- |
568 | 742 | ||
569 | This feature is marked EXPERIMENTAL because the implementation | 743 | procfs: /proc/acpi/ibm/fan |
570 | directly accesses hardware registers and may not work as expected. USE | 744 | sysfs device attributes: (hwmon) fan_input, pwm1, pwm1_enable |
571 | WITH CAUTION! To use this feature, you need to supply the | 745 | |
572 | experimental=1 parameter when loading the module. | 746 | NOTE NOTE NOTE: fan control operations are disabled by default for |
747 | safety reasons. To enable them, the module parameter "fan_control=1" | ||
748 | must be given to thinkpad-acpi. | ||
573 | 749 | ||
574 | This feature attempts to show the current fan speed, control mode and | 750 | This feature attempts to show the current fan speed, control mode and |
575 | other fan data that might be available. The speed is read directly | 751 | other fan data that might be available. The speed is read directly |
576 | from the hardware registers of the embedded controller. This is known | 752 | from the hardware registers of the embedded controller. This is known |
577 | to work on later R, T and X series ThinkPads but may show a bogus | 753 | to work on later R, T, X and Z series ThinkPads but may show a bogus |
578 | value on other models. | 754 | value on other models. |
579 | 755 | ||
580 | Most ThinkPad fans work in "levels". Level 0 stops the fan. The higher | 756 | Fan levels: |
581 | the level, the higher the fan speed, although adjacent levels often map | ||
582 | to the same fan speed. 7 is the highest level, where the fan reaches | ||
583 | the maximum recommended speed. Level "auto" means the EC changes the | ||
584 | fan level according to some internal algorithm, usually based on | ||
585 | readings from the thermal sensors. Level "disengaged" means the EC | ||
586 | disables the speed-locked closed-loop fan control, and drives the fan as | ||
587 | fast as it can go, which might exceed hardware limits, so use this level | ||
588 | with caution. | ||
589 | 757 | ||
590 | The fan usually ramps up or down slowly from one speed to another, | 758 | Most ThinkPad fans work in "levels" at the firmware interface. Level 0 |
591 | and it is normal for the EC to take several seconds to react to fan | 759 | stops the fan. The higher the level, the higher the fan speed, although |
592 | commands. | 760 | adjacent levels often map to the same fan speed. 7 is the highest |
761 | level, where the fan reaches the maximum recommended speed. | ||
593 | 762 | ||
594 | The fan may be enabled or disabled with the following commands: | 763 | Level "auto" means the EC changes the fan level according to some |
764 | internal algorithm, usually based on readings from the thermal sensors. | ||
595 | 765 | ||
596 | echo enable >/proc/acpi/ibm/fan | 766 | There is also a "full-speed" level, also known as "disengaged" level. |
597 | echo disable >/proc/acpi/ibm/fan | 767 | In this level, the EC disables the speed-locked closed-loop fan control, |
768 | and drives the fan as fast as it can go, which might exceed hardware | ||
769 | limits, so use this level with caution. | ||
598 | 770 | ||
599 | Placing a fan on level 0 is the same as disabling it. Enabling a fan | 771 | The fan usually ramps up or down slowly from one speed to another, and |
600 | will try to place it in a safe level if it is too slow or disabled. | 772 | it is normal for the EC to take several seconds to react to fan |
773 | commands. The full-speed level may take up to two minutes to ramp up to | ||
774 | maximum speed, and in some ThinkPads, the tachometer readings go stale | ||
775 | while the EC is transitioning to the full-speed level. | ||
601 | 776 | ||
602 | WARNING WARNING WARNING: do not leave the fan disabled unless you are | 777 | WARNING WARNING WARNING: do not leave the fan disabled unless you are |
603 | monitoring all of the temperature sensor readings and you are ready to | 778 | monitoring all of the temperature sensor readings and you are ready to |
@@ -615,46 +790,146 @@ fan is turned off when the CPU temperature drops to 49 degrees and the | |||
615 | HDD temperature drops to 41 degrees. These thresholds cannot | 790 | HDD temperature drops to 41 degrees. These thresholds cannot |
616 | currently be controlled. | 791 | currently be controlled. |
617 | 792 | ||
793 | The ThinkPad's ACPI DSDT code will reprogram the fan on its own when | ||
794 | certain conditions are met. It will override any fan programming done | ||
795 | through thinkpad-acpi. | ||
796 | |||
797 | The thinkpad-acpi kernel driver can be programmed to revert the fan | ||
798 | level to a safe setting if userspace does not issue one of the procfs | ||
799 | fan commands: "enable", "disable", "level" or "watchdog", or if there | ||
800 | are no writes to pwm1_enable (or to pwm1 *if and only if* pwm1_enable is | ||
801 | set to 1, manual mode) within a configurable amount of time of up to | ||
802 | 120 seconds. This functionality is called fan safety watchdog. | ||
803 | |||
804 | Note that the watchdog timer stops after it enables the fan. It will be | ||
805 | rearmed again automatically (using the same interval) when one of the | ||
806 | above mentioned fan commands is received. The fan watchdog is, | ||
807 | therefore, not suitable to protect against fan mode changes made through | ||
808 | means other than the "enable", "disable", and "level" procfs fan | ||
809 | commands, or the hwmon fan control sysfs interface. | ||
810 | |||
811 | Procfs notes: | ||
812 | |||
813 | The fan may be enabled or disabled with the following commands: | ||
814 | |||
815 | echo enable >/proc/acpi/ibm/fan | ||
816 | echo disable >/proc/acpi/ibm/fan | ||
817 | |||
818 | Placing a fan on level 0 is the same as disabling it. Enabling a fan | ||
819 | will try to place it in a safe level if it is too slow or disabled. | ||
820 | |||
618 | The fan level can be controlled with the command: | 821 | The fan level can be controlled with the command: |
619 | 822 | ||
620 | echo 'level <level>' > /proc/acpi/ibm/thermal | 823 | echo 'level <level>' > /proc/acpi/ibm/fan |
621 | 824 | ||
622 | Where <level> is an integer from 0 to 7, or one of the words "auto" | 825 | Where <level> is an integer from 0 to 7, or one of the words "auto" or |
623 | or "disengaged" (without the quotes). Not all ThinkPads support the | 826 | "full-speed" (without the quotes). Not all ThinkPads support the "auto" |
624 | "auto" and "disengaged" levels. | 827 | and "full-speed" levels. The driver accepts "disengaged" as an alias for |
828 | "full-speed", and reports it as "disengaged" for backwards | ||
829 | compatibility. | ||
625 | 830 | ||
626 | On the X31 and X40 (and ONLY on those models), the fan speed can be | 831 | On the X31 and X40 (and ONLY on those models), the fan speed can be |
627 | controlled to a certain degree. Once the fan is running, it can be | 832 | controlled to a certain degree. Once the fan is running, it can be |
628 | forced to run faster or slower with the following command: | 833 | forced to run faster or slower with the following command: |
629 | 834 | ||
630 | echo 'speed <speed>' > /proc/acpi/ibm/thermal | 835 | echo 'speed <speed>' > /proc/acpi/ibm/fan |
631 | 836 | ||
632 | The sustainable range of fan speeds on the X40 appears to be from | 837 | The sustainable range of fan speeds on the X40 appears to be from about |
633 | about 3700 to about 7350. Values outside this range either do not have | 838 | 3700 to about 7350. Values outside this range either do not have any |
634 | any effect or the fan speed eventually settles somewhere in that | 839 | effect or the fan speed eventually settles somewhere in that range. The |
635 | range. The fan cannot be stopped or started with this command. | 840 | fan cannot be stopped or started with this command. This functionality |
841 | is incomplete, and not available through the sysfs interface. | ||
636 | 842 | ||
637 | The ThinkPad's ACPI DSDT code will reprogram the fan on its own when | 843 | To program the safety watchdog, use the "watchdog" command. |
638 | certain conditions are met. It will override any fan programming done | ||
639 | through ibm-acpi. | ||
640 | 844 | ||
641 | EXPERIMENTAL: WAN -- /proc/acpi/ibm/wan | 845 | echo 'watchdog <interval in seconds>' > /proc/acpi/ibm/fan |
642 | --------------------------------------- | 846 | |
847 | If you want to disable the watchdog, use 0 as the interval. | ||
848 | |||
849 | Sysfs notes: | ||
850 | |||
851 | The sysfs interface follows the hwmon subsystem guidelines for the most | ||
852 | part, and the exception is the fan safety watchdog. | ||
853 | |||
854 | Writes to any of the sysfs attributes may return the EINVAL error if | ||
855 | that operation is not supported in a given ThinkPad or if the parameter | ||
856 | is out-of-bounds, and EPERM if it is forbidden. They may also return | ||
857 | EINTR (interrupted system call), and EIO (I/O error while trying to talk | ||
858 | to the firmware). | ||
859 | |||
860 | Features not yet implemented by the driver return ENOSYS. | ||
861 | |||
862 | hwmon device attribute pwm1_enable: | ||
863 | 0: PWM offline (fan is set to full-speed mode) | ||
864 | 1: Manual PWM control (use pwm1 to set fan level) | ||
865 | 2: Hardware PWM control (EC "auto" mode) | ||
866 | 3: reserved (Software PWM control, not implemented yet) | ||
867 | |||
868 | Modes 0 and 2 are not supported by all ThinkPads, and the | ||
869 | driver is not always able to detect this. If it does know a | ||
870 | mode is unsupported, it will return -EINVAL. | ||
871 | |||
872 | hwmon device attribute pwm1: | ||
873 | Fan level, scaled from the firmware values of 0-7 to the hwmon | ||
874 | scale of 0-255. 0 means fan stopped, 255 means highest normal | ||
875 | speed (level 7). | ||
876 | |||
877 | This attribute only commands the fan if pmw1_enable is set to 1 | ||
878 | (manual PWM control). | ||
879 | |||
880 | hwmon device attribute fan1_input: | ||
881 | Fan tachometer reading, in RPM. May go stale on certain | ||
882 | ThinkPads while the EC transitions the PWM to offline mode, | ||
883 | which can take up to two minutes. May return rubbish on older | ||
884 | ThinkPads. | ||
885 | |||
886 | driver attribute fan_watchdog: | ||
887 | Fan safety watchdog timer interval, in seconds. Minimum is | ||
888 | 1 second, maximum is 120 seconds. 0 disables the watchdog. | ||
889 | |||
890 | To stop the fan: set pwm1 to zero, and pwm1_enable to 1. | ||
891 | |||
892 | To start the fan in a safe mode: set pwm1_enable to 2. If that fails | ||
893 | with EINVAL, try to set pwm1_enable to 1 and pwm1 to at least 128 (255 | ||
894 | would be the safest choice, though). | ||
895 | |||
896 | |||
897 | EXPERIMENTAL: WAN | ||
898 | ----------------- | ||
899 | |||
900 | procfs: /proc/acpi/ibm/wan | ||
901 | sysfs device attribute: wwan/enable | ||
643 | 902 | ||
644 | This feature is marked EXPERIMENTAL because the implementation | 903 | This feature is marked EXPERIMENTAL because the implementation |
645 | directly accesses hardware registers and may not work as expected. USE | 904 | directly accesses hardware registers and may not work as expected. USE |
646 | WITH CAUTION! To use this feature, you need to supply the | 905 | WITH CAUTION! To use this feature, you need to supply the |
647 | experimental=1 parameter when loading the module. | 906 | experimental=1 parameter when loading the module. |
648 | 907 | ||
649 | This feature shows the presence and current state of a WAN (Sierra | 908 | This feature shows the presence and current state of a W-WAN (Sierra |
650 | Wireless EV-DO) device. If WAN is installed, the following commands can | 909 | Wireless EV-DO) device. |
651 | be used: | 910 | |
911 | It was tested on a Lenovo Thinkpad X60. It should probably work on other | ||
912 | Thinkpad models which come with this module installed. | ||
913 | |||
914 | Procfs notes: | ||
915 | |||
916 | If the W-WAN card is installed, the following commands can be used: | ||
652 | 917 | ||
653 | echo enable > /proc/acpi/ibm/wan | 918 | echo enable > /proc/acpi/ibm/wan |
654 | echo disable > /proc/acpi/ibm/wan | 919 | echo disable > /proc/acpi/ibm/wan |
655 | 920 | ||
656 | It was tested on a Lenovo Thinkpad X60. It should probably work on other | 921 | Sysfs notes: |
657 | Thinkpad models which come with this module installed. | 922 | |
923 | If the W-WAN card is installed, it can be enabled / | ||
924 | disabled through the "wwan/enable" thinkpad-acpi device | ||
925 | attribute, and its current status can also be queried. | ||
926 | |||
927 | enable: | ||
928 | 0: disables WWAN card / WWAN card is disabled | ||
929 | 1: enables WWAN card / WWAN card is enabled. | ||
930 | |||
931 | Note: this interface will be probably be superseeded by the | ||
932 | generic rfkill class. | ||
658 | 933 | ||
659 | Multiple Commands, Module Parameters | 934 | Multiple Commands, Module Parameters |
660 | ------------------------------------ | 935 | ------------------------------------ |
@@ -665,64 +940,42 @@ separating them with commas, for example: | |||
665 | echo enable,0xffff > /proc/acpi/ibm/hotkey | 940 | echo enable,0xffff > /proc/acpi/ibm/hotkey |
666 | echo lcd_disable,crt_enable > /proc/acpi/ibm/video | 941 | echo lcd_disable,crt_enable > /proc/acpi/ibm/video |
667 | 942 | ||
668 | Commands can also be specified when loading the ibm_acpi module, for | 943 | Commands can also be specified when loading the thinkpad-acpi module, |
669 | example: | 944 | for example: |
670 | 945 | ||
671 | modprobe ibm_acpi hotkey=enable,0xffff video=auto_disable | 946 | modprobe thinkpad_acpi hotkey=enable,0xffff video=auto_disable |
672 | 947 | ||
673 | The ibm-acpi kernel driver can be programmed to revert the fan level | 948 | Enabling debugging output |
674 | to a safe setting if userspace does not issue one of the fan commands: | 949 | ------------------------- |
675 | "enable", "disable", "level" or "watchdog" within a configurable | 950 | |
676 | ammount of time. To do this, use the "watchdog" command. | 951 | The module takes a debug paramater which can be used to selectively |
677 | 952 | enable various classes of debugging output, for example: | |
678 | echo 'watchdog <interval>' > /proc/acpi/ibm/fan | 953 | |
679 | 954 | modprobe ibm_acpi debug=0xffff | |
680 | Interval is the ammount of time in seconds to wait for one of the | 955 | |
681 | above mentioned fan commands before reseting the fan level to a safe | 956 | will enable all debugging output classes. It takes a bitmask, so |
682 | one. If set to zero, the watchdog is disabled (default). When the | 957 | to enable more than one output class, just add their values. |
683 | watchdog timer runs out, it does the exact equivalent of the "enable" | 958 | |
684 | fan command. | 959 | Debug bitmask Description |
685 | 960 | 0x0001 Initialization and probing | |
686 | Note that the watchdog timer stops after it enables the fan. It will | 961 | 0x0002 Removal |
687 | be rearmed again automatically (using the same interval) when one of | 962 | |
688 | the above mentioned fan commands is received. The fan watchdog is, | 963 | There is also a kernel build option to enable more debugging |
689 | therefore, not suitable to protect against fan mode changes made | 964 | information, which may be necessary to debug driver problems. |
690 | through means other than the "enable", "disable", and "level" fan | 965 | |
691 | commands. | 966 | The level of debugging information output by the driver can be changed |
692 | 967 | at runtime through sysfs, using the driver attribute debug_level. The | |
693 | 968 | attribute takes the same bitmask as the debug module parameter above. | |
694 | Example Configuration | 969 | |
695 | --------------------- | 970 | Force loading of module |
696 | 971 | ----------------------- | |
697 | The ACPI support in the kernel is intended to be used in conjunction | 972 | |
698 | with a user-space daemon, acpid. The configuration files for this | 973 | If thinkpad-acpi refuses to detect your ThinkPad, you can try to specify |
699 | daemon control what actions are taken in response to various ACPI | 974 | the module parameter force_load=1. Regardless of whether this works or |
700 | events. An example set of configuration files are included in the | 975 | not, please contact ibm-acpi-devel@lists.sourceforge.net with a report. |
701 | config/ directory of the tarball package available on the web | 976 | |
702 | site. Note that these are provided for illustration purposes only and | 977 | |
703 | may need to be adapted to your particular setup. | 978 | Sysfs interface changelog: |
704 | 979 | ||
705 | The following utility scripts are used by the example action | 980 | 0x000100: Initial sysfs support, as a single platform driver and |
706 | scripts (included with ibm-acpi for completeness): | 981 | device. |
707 | |||
708 | /usr/local/sbin/idectl -- from the hdparm source distribution, | ||
709 | see http://www.ibiblio.org/pub/Linux/system/hardware | ||
710 | /usr/local/sbin/laptop_mode -- from the Linux kernel source | ||
711 | distribution, see Documentation/laptop-mode.txt | ||
712 | /sbin/service -- comes with Redhat/Fedora distributions | ||
713 | /usr/sbin/hibernate -- from the Software Suspend 2 distribution, | ||
714 | see http://softwaresuspend.berlios.de/ | ||
715 | |||
716 | Toan T Nguyen <ntt@physics.ucla.edu> notes that Suse uses the | ||
717 | powersave program to suspend ('powersave --suspend-to-ram') or | ||
718 | hibernate ('powersave --suspend-to-disk'). This means that the | ||
719 | hibernate script is not needed on that distribution. | ||
720 | |||
721 | Henrik Brix Andersen <brix@gentoo.org> has written a Gentoo ACPI event | ||
722 | handler script for the X31. You can get the latest version from | ||
723 | http://dev.gentoo.org/~brix/files/x31.sh | ||
724 | |||
725 | David Schweikert <dws@ee.eth.ch> has written an alternative blank.sh | ||
726 | script which works on Debian systems. This scripts has now been | ||
727 | extended to also work on Fedora systems and included as the default | ||
728 | blank.sh in the distribution. | ||
diff --git a/Documentation/video4linux/meye.txt b/Documentation/video4linux/meye.txt index ecb34160e61d..5e51c59bf2b0 100644 --- a/Documentation/video4linux/meye.txt +++ b/Documentation/video4linux/meye.txt | |||
@@ -5,10 +5,9 @@ Vaio Picturebook Motion Eye Camera Driver Readme | |||
5 | Copyright (C) 2000 Andrew Tridgell <tridge@samba.org> | 5 | Copyright (C) 2000 Andrew Tridgell <tridge@samba.org> |
6 | 6 | ||
7 | This driver enable the use of video4linux compatible applications with the | 7 | This driver enable the use of video4linux compatible applications with the |
8 | Motion Eye camera. This driver requires the "Sony Vaio Programmable I/O | 8 | Motion Eye camera. This driver requires the "Sony Laptop Extras" driver (which |
9 | Control Device" driver (which can be found in the "Character drivers" | 9 | can be found in the "Misc devices" section of the kernel configuration utility) |
10 | section of the kernel configuration utility) to be compiled and installed | 10 | to be compiled and installed (using its "camera=1" parameter). |
11 | (using its "camera=1" parameter). | ||
12 | 11 | ||
13 | It can do at maximum 30 fps @ 320x240 or 15 fps @ 640x480. | 12 | It can do at maximum 30 fps @ 320x240 or 15 fps @ 640x480. |
14 | 13 | ||