thinkpad-acpi.txt 44 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177
  1. ThinkPad ACPI Extras Driver
  2. Version 0.15
  3. July 1st, 2007
  4. Borislav Deianov <borislav@users.sf.net>
  5. Henrique de Moraes Holschuh <hmh@hmh.eng.br>
  6. http://ibm-acpi.sf.net/
  7. This is a Linux driver for the IBM and Lenovo ThinkPad laptops. It
  8. supports various features of these laptops which are accessible
  9. through the ACPI and ACPI EC framework, but not otherwise fully
  10. supported by the generic Linux ACPI drivers.
  11. This driver used to be named ibm-acpi until kernel 2.6.21 and release
  12. 0.13-20070314. It used to be in the drivers/acpi tree, but it was
  13. moved to the drivers/misc tree and renamed to thinkpad-acpi for kernel
  14. 2.6.22, and release 0.14.
  15. Status
  16. ------
  17. The features currently supported are the following (see below for
  18. detailed description):
  19. - Fn key combinations
  20. - Bluetooth enable and disable
  21. - video output switching, expansion control
  22. - ThinkLight on and off
  23. - limited docking and undocking
  24. - UltraBay eject
  25. - CMOS control
  26. - LED control
  27. - ACPI sounds
  28. - temperature sensors
  29. - Experimental: embedded controller register dump
  30. - LCD brightness control
  31. - Volume control
  32. - Fan control and monitoring: fan speed, fan enable/disable
  33. - Experimental: WAN enable and disable
  34. A compatibility table by model and feature is maintained on the web
  35. site, http://ibm-acpi.sf.net/. I appreciate any success or failure
  36. reports, especially if they add to or correct the compatibility table.
  37. Please include the following information in your report:
  38. - ThinkPad model name
  39. - a copy of your DSDT, from /proc/acpi/dsdt
  40. - a copy of the output of dmidecode, with serial numbers
  41. and UUIDs masked off
  42. - which driver features work and which don't
  43. - the observed behavior of non-working features
  44. Any other comments or patches are also more than welcome.
  45. Installation
  46. ------------
  47. If you are compiling this driver as included in the Linux kernel
  48. sources, simply enable the CONFIG_THINKPAD_ACPI option, and optionally
  49. enable the CONFIG_THINKPAD_ACPI_BAY option if you want the
  50. thinkpad-specific bay functionality.
  51. Features
  52. --------
  53. The driver exports two different interfaces to userspace, which can be
  54. used to access the features it provides. One is a legacy procfs-based
  55. interface, which will be removed at some time in the distant future.
  56. The other is a new sysfs-based interface which is not complete yet.
  57. The procfs interface creates the /proc/acpi/ibm directory. There is a
  58. file under that directory for each feature it supports. The procfs
  59. interface is mostly frozen, and will change very little if at all: it
  60. will not be extended to add any new functionality in the driver, instead
  61. all new functionality will be implemented on the sysfs interface.
  62. The sysfs interface tries to blend in the generic Linux sysfs subsystems
  63. and classes as much as possible. Since some of these subsystems are not
  64. yet ready or stabilized, it is expected that this interface will change,
  65. and any and all userspace programs must deal with it.
  66. Notes about the sysfs interface:
  67. Unlike what was done with the procfs interface, correctness when talking
  68. to the sysfs interfaces will be enforced, as will correctness in the
  69. thinkpad-acpi's implementation of sysfs interfaces.
  70. Also, any bugs in the thinkpad-acpi sysfs driver code or in the
  71. thinkpad-acpi's implementation of the sysfs interfaces will be fixed for
  72. maximum correctness, even if that means changing an interface in
  73. non-compatible ways. As these interfaces mature both in the kernel and
  74. in thinkpad-acpi, such changes should become quite rare.
  75. Applications interfacing to the thinkpad-acpi sysfs interfaces must
  76. follow all sysfs guidelines and correctly process all errors (the sysfs
  77. interface makes extensive use of errors). File descriptors and open /
  78. close operations to the sysfs inodes must also be properly implemented.
  79. The version of thinkpad-acpi's sysfs interface is exported by the driver
  80. as a driver attribute (see below).
  81. Sysfs driver attributes are on the driver's sysfs attribute space,
  82. for 2.6.20 this is /sys/bus/platform/drivers/thinkpad-acpi/.
  83. Sysfs device attributes are on the driver's sysfs attribute space,
  84. for 2.6.20 this is /sys/devices/platform/thinkpad-acpi/.
  85. Driver version
  86. --------------
  87. procfs: /proc/acpi/ibm/driver
  88. sysfs driver attribute: version
  89. The driver name and version. No commands can be written to this file.
  90. Sysfs interface version
  91. -----------------------
  92. sysfs driver attribute: interface_version
  93. Version of the thinkpad-acpi sysfs interface, as an unsigned long
  94. (output in hex format: 0xAAAABBCC), where:
  95. AAAA - major revision
  96. BB - minor revision
  97. CC - bugfix revision
  98. The sysfs interface version changelog for the driver can be found at the
  99. end of this document. Changes to the sysfs interface done by the kernel
  100. subsystems are not documented here, nor are they tracked by this
  101. attribute.
  102. Changes to the thinkpad-acpi sysfs interface are only considered
  103. non-experimental when they are submitted to Linux mainline, at which
  104. point the changes in this interface are documented and interface_version
  105. may be updated. If you are using any thinkpad-acpi features not yet
  106. sent to mainline for merging, you do so on your own risk: these features
  107. may disappear, or be implemented in a different and incompatible way by
  108. the time they are merged in Linux mainline.
  109. Changes that are backwards-compatible by nature (e.g. the addition of
  110. attributes that do not change the way the other attributes work) do not
  111. always warrant an update of interface_version. Therefore, one must
  112. expect that an attribute might not be there, and deal with it properly
  113. (an attribute not being there *is* a valid way to make it clear that a
  114. feature is not available in sysfs).
  115. Hot keys
  116. --------
  117. procfs: /proc/acpi/ibm/hotkey
  118. sysfs device attribute: hotkey_*
  119. In a ThinkPad, the ACPI HKEY handler is responsible for comunicating
  120. some important events and also keyboard hot key presses to the operating
  121. system. Enabling the hotkey functionality of thinkpad-acpi signals the
  122. firmware that such a driver is present, and modifies how the ThinkPad
  123. firmware will behave in many situations.
  124. When the hotkey feature is enabled and the hot key mask is set (see
  125. below), the various hot keys either generate ACPI events in the
  126. following format:
  127. ibm/hotkey HKEY 00000080 0000xxxx
  128. or events over the input layer. The input layer support accepts the
  129. standard IOCTLs to remap the keycodes assigned to each hotkey.
  130. When the input device is open, the driver will suppress any ACPI hot key
  131. events that get translated into a meaningful input layer event, in order
  132. to avoid sending duplicate events to userspace. Hot keys that are
  133. mapped to KEY_RESERVED in the keymap are not translated, and will always
  134. generate an ACPI ibm/hotkey HKEY event, and no input layer events.
  135. The hot key bit mask allows some control over which hot keys generate
  136. events. If a key is "masked" (bit set to 0 in the mask), the firmware
  137. will handle it. If it is "unmasked", it signals the firmware that
  138. thinkpad-acpi would prefer to handle it, if the firmware would be so
  139. kind to allow it (and it often doesn't!).
  140. Not all bits in the mask can be modified. Not all bits that can be
  141. modified do anything. Not all hot keys can be individually controlled
  142. by the mask. Some models do not support the mask at all, and in those
  143. models, hot keys cannot be controlled individually. The behaviour of
  144. the mask is, therefore, higly dependent on the ThinkPad model.
  145. Note that unmasking some keys prevents their default behavior. For
  146. example, if Fn+F5 is unmasked, that key will no longer enable/disable
  147. Bluetooth by itself.
  148. Note also that not all Fn key combinations are supported through ACPI.
  149. For example, on the X40, the brightness, volume and "Access IBM" buttons
  150. do not generate ACPI events even with this driver. They *can* be used
  151. through the "ThinkPad Buttons" utility, see http://www.nongnu.org/tpb/
  152. procfs notes:
  153. The following commands can be written to the /proc/acpi/ibm/hotkey file:
  154. echo enable > /proc/acpi/ibm/hotkey -- enable the hot keys feature
  155. echo disable > /proc/acpi/ibm/hotkey -- disable the hot keys feature
  156. echo 0xffffffff > /proc/acpi/ibm/hotkey -- enable all hot keys
  157. echo 0 > /proc/acpi/ibm/hotkey -- disable all possible hot keys
  158. ... any other 8-hex-digit mask ...
  159. echo reset > /proc/acpi/ibm/hotkey -- restore the original mask
  160. sysfs notes:
  161. hotkey_bios_enabled:
  162. Returns the status of the hot keys feature when
  163. thinkpad-acpi was loaded. Upon module unload, the hot
  164. key feature status will be restored to this value.
  165. 0: hot keys were disabled
  166. 1: hot keys were enabled (unusual)
  167. hotkey_bios_mask:
  168. Returns the hot keys mask when thinkpad-acpi was loaded.
  169. Upon module unload, the hot keys mask will be restored
  170. to this value.
  171. hotkey_enable:
  172. Enables/disables the hot keys feature, and reports
  173. current status of the hot keys feature.
  174. 0: disables the hot keys feature / feature disabled
  175. 1: enables the hot keys feature / feature enabled
  176. hotkey_mask:
  177. bit mask to enable driver-handling and ACPI event
  178. generation for each hot key (see above). Returns the
  179. current status of the hot keys mask, and allows one to
  180. modify it.
  181. hotkey_all_mask:
  182. bit mask that should enable event reporting for all
  183. supported hot keys, when echoed to hotkey_mask above.
  184. Unless you know which events need to be handled
  185. passively (because the firmware *will* handle them
  186. anyway), do *not* use hotkey_all_mask. Use
  187. hotkey_recommended_mask, instead. You have been warned.
  188. hotkey_recommended_mask:
  189. bit mask that should enable event reporting for all
  190. supported hot keys, except those which are always
  191. handled by the firmware anyway. Echo it to
  192. hotkey_mask above, to use.
  193. hotkey_radio_sw:
  194. if the ThinkPad has a hardware radio switch, this
  195. attribute will read 0 if the switch is in the "radios
  196. disabled" postition, and 1 if the switch is in the
  197. "radios enabled" position.
  198. input layer notes:
  199. A Hot key is mapped to a single input layer EV_KEY event, possibly
  200. followed by an EV_MSC MSC_SCAN event that shall contain that key's scan
  201. code. An EV_SYN event will always be generated to mark the end of the
  202. event block.
  203. Do not use the EV_MSC MSC_SCAN events to process keys. They are to be
  204. used as a helper to remap keys, only. They are particularly useful when
  205. remapping KEY_UNKNOWN keys.
  206. The events are available in an input device, with the following id:
  207. Bus: BUS_HOST
  208. vendor: 0x1014 (PCI_VENDOR_ID_IBM) or
  209. 0x17aa (PCI_VENDOR_ID_LENOVO)
  210. product: 0x5054 ("TP")
  211. version: 0x4101
  212. The version will have its LSB incremented if the keymap changes in a
  213. backwards-compatible way. The MSB shall always be 0x41 for this input
  214. device. If the MSB is not 0x41, do not use the device as described in
  215. this section, as it is either something else (e.g. another input device
  216. exported by a thinkpad driver, such as HDAPS) or its functionality has
  217. been changed in a non-backwards compatible way.
  218. Adding other event types for other functionalities shall be considered a
  219. backwards-compatible change for this input device.
  220. Thinkpad-acpi Hot Key event map (version 0x4101):
  221. ACPI Scan
  222. event code Key Notes
  223. 0x1001 0x00 FN+F1 -
  224. 0x1002 0x01 FN+F2 IBM: battery (rare)
  225. Lenovo: Screen lock
  226. 0x1003 0x02 FN+F3 Many IBM models always report
  227. this hot key, even with hot keys
  228. disabled or with Fn+F3 masked
  229. off
  230. IBM: screen lock
  231. Lenovo: battery
  232. 0x1004 0x03 FN+F4 Sleep button (ACPI sleep button
  233. semanthics, i.e. sleep-to-RAM).
  234. It is always generate some kind
  235. of event, either the hot key
  236. event or a ACPI sleep button
  237. event. The firmware may
  238. refuse to generate further FN+F4
  239. key presses until a S3 or S4 ACPI
  240. sleep cycle is performed or some
  241. time passes.
  242. 0x1005 0x04 FN+F5 Radio. Enables/disables
  243. the internal BlueTooth hardware
  244. and W-WAN card if left in control
  245. of the firmware. Does not affect
  246. the WLAN card.
  247. Should be used to turn on/off all
  248. radios (bluetooth+W-WAN+WLAN),
  249. really.
  250. 0x1006 0x05 FN+F6 -
  251. 0x1007 0x06 FN+F7 Video output cycle.
  252. Do you feel lucky today?
  253. 0x1008 0x07 FN+F8 IBM: toggle screen expand
  254. Lenovo: configure ultranav
  255. 0x1009 0x08 FN+F9 -
  256. .. .. ..
  257. 0x100B 0x0A FN+F11 -
  258. 0x100C 0x0B FN+F12 Sleep to disk. You are always
  259. supposed to handle it yourself,
  260. either through the ACPI event,
  261. or through a hotkey event.
  262. The firmware may refuse to
  263. generate further FN+F4 key
  264. press events until a S3 or S4
  265. ACPI sleep cycle is performed,
  266. or some time passes.
  267. 0x100D 0x0C FN+BACKSPACE -
  268. 0x100E 0x0D FN+INSERT -
  269. 0x100F 0x0E FN+DELETE -
  270. 0x1010 0x0F FN+HOME Brightness up. This key is
  271. always handled by the firmware
  272. in IBM ThinkPads, even when
  273. unmasked. Just leave it alone.
  274. For Lenovo ThinkPads with a new
  275. BIOS, it has to be handled either
  276. by the ACPI OSI, or by userspace.
  277. 0x1011 0x10 FN+END Brightness down. See brightness
  278. up for details.
  279. 0x1012 0x11 FN+PGUP Thinklight toggle. This key is
  280. always handled by the firmware,
  281. even when unmasked.
  282. 0x1013 0x12 FN+PGDOWN -
  283. 0x1014 0x13 FN+SPACE Zoom key
  284. 0x1015 0x14 VOLUME UP Internal mixer volume up. This
  285. key is always handled by the
  286. firmware, even when unmasked.
  287. NOTE: Lenovo seems to be changing
  288. this.
  289. 0x1016 0x15 VOLUME DOWN Internal mixer volume up. This
  290. key is always handled by the
  291. firmware, even when unmasked.
  292. NOTE: Lenovo seems to be changing
  293. this.
  294. 0x1017 0x16 MUTE Mute internal mixer. This
  295. key is always handled by the
  296. firmware, even when unmasked.
  297. 0x1018 0x17 THINKPAD Thinkpad/Access IBM/Lenovo key
  298. 0x1019 0x18 unknown
  299. .. .. ..
  300. 0x1020 0x1F unknown
  301. The ThinkPad firmware does not allow one to differentiate when most hot
  302. keys are pressed or released (either that, or we don't know how to, yet).
  303. For these keys, the driver generates a set of events for a key press and
  304. immediately issues the same set of events for a key release. It is
  305. unknown by the driver if the ThinkPad firmware triggered these events on
  306. hot key press or release, but the firmware will do it for either one, not
  307. both.
  308. If a key is mapped to KEY_RESERVED, it generates no input events at all,
  309. and it may generate a legacy thinkpad-acpi ACPI hotkey event.
  310. If a key is mapped to KEY_UNKNOWN, it generates an input event that
  311. includes an scan code, and it may also generate a legacy thinkpad-acpi
  312. ACPI hotkey event.
  313. If a key is mapped to anything else, it will only generate legacy
  314. thinkpad-acpi ACPI hotkey events if nobody has opened the input device.
  315. Non hot-key ACPI HKEY event map:
  316. 0x5001 Lid closed
  317. 0x5002 Lid opened
  318. 0x7000 Radio Switch may have changed state
  319. Bluetooth
  320. ---------
  321. procfs: /proc/acpi/ibm/bluetooth
  322. sysfs device attribute: bluetooth_enable
  323. This feature shows the presence and current state of a ThinkPad
  324. Bluetooth device in the internal ThinkPad CDC slot.
  325. Procfs notes:
  326. If Bluetooth is installed, the following commands can be used:
  327. echo enable > /proc/acpi/ibm/bluetooth
  328. echo disable > /proc/acpi/ibm/bluetooth
  329. Sysfs notes:
  330. If the Bluetooth CDC card is installed, it can be enabled /
  331. disabled through the "bluetooth_enable" thinkpad-acpi device
  332. attribute, and its current status can also be queried.
  333. enable:
  334. 0: disables Bluetooth / Bluetooth is disabled
  335. 1: enables Bluetooth / Bluetooth is enabled.
  336. Note: this interface will be probably be superseeded by the
  337. generic rfkill class, so it is NOT to be considered stable yet.
  338. Video output control -- /proc/acpi/ibm/video
  339. --------------------------------------------
  340. This feature allows control over the devices used for video output -
  341. LCD, CRT or DVI (if available). The following commands are available:
  342. echo lcd_enable > /proc/acpi/ibm/video
  343. echo lcd_disable > /proc/acpi/ibm/video
  344. echo crt_enable > /proc/acpi/ibm/video
  345. echo crt_disable > /proc/acpi/ibm/video
  346. echo dvi_enable > /proc/acpi/ibm/video
  347. echo dvi_disable > /proc/acpi/ibm/video
  348. echo auto_enable > /proc/acpi/ibm/video
  349. echo auto_disable > /proc/acpi/ibm/video
  350. echo expand_toggle > /proc/acpi/ibm/video
  351. echo video_switch > /proc/acpi/ibm/video
  352. Each video output device can be enabled or disabled individually.
  353. Reading /proc/acpi/ibm/video shows the status of each device.
  354. Automatic video switching can be enabled or disabled. When automatic
  355. video switching is enabled, certain events (e.g. opening the lid,
  356. docking or undocking) cause the video output device to change
  357. automatically. While this can be useful, it also causes flickering
  358. and, on the X40, video corruption. By disabling automatic switching,
  359. the flickering or video corruption can be avoided.
  360. The video_switch command cycles through the available video outputs
  361. (it simulates the behavior of Fn-F7).
  362. Video expansion can be toggled through this feature. This controls
  363. whether the display is expanded to fill the entire LCD screen when a
  364. mode with less than full resolution is used. Note that the current
  365. video expansion status cannot be determined through this feature.
  366. Note that on many models (particularly those using Radeon graphics
  367. chips) the X driver configures the video card in a way which prevents
  368. Fn-F7 from working. This also disables the video output switching
  369. features of this driver, as it uses the same ACPI methods as
  370. Fn-F7. Video switching on the console should still work.
  371. UPDATE: There's now a patch for the X.org Radeon driver which
  372. addresses this issue. Some people are reporting success with the patch
  373. while others are still having problems. For more information:
  374. https://bugs.freedesktop.org/show_bug.cgi?id=2000
  375. ThinkLight control -- /proc/acpi/ibm/light
  376. ------------------------------------------
  377. The current status of the ThinkLight can be found in this file. A few
  378. models which do not make the status available will show it as
  379. "unknown". The available commands are:
  380. echo on > /proc/acpi/ibm/light
  381. echo off > /proc/acpi/ibm/light
  382. Docking / undocking -- /proc/acpi/ibm/dock
  383. ------------------------------------------
  384. Docking and undocking (e.g. with the X4 UltraBase) requires some
  385. actions to be taken by the operating system to safely make or break
  386. the electrical connections with the dock.
  387. The docking feature of this driver generates the following ACPI events:
  388. ibm/dock GDCK 00000003 00000001 -- eject request
  389. ibm/dock GDCK 00000003 00000002 -- undocked
  390. ibm/dock GDCK 00000000 00000003 -- docked
  391. NOTE: These events will only be generated if the laptop was docked
  392. when originally booted. This is due to the current lack of support for
  393. hot plugging of devices in the Linux ACPI framework. If the laptop was
  394. booted while not in the dock, the following message is shown in the
  395. logs:
  396. Mar 17 01:42:34 aero kernel: thinkpad_acpi: dock device not present
  397. In this case, no dock-related events are generated but the dock and
  398. undock commands described below still work. They can be executed
  399. manually or triggered by Fn key combinations (see the example acpid
  400. configuration files included in the driver tarball package available
  401. on the web site).
  402. When the eject request button on the dock is pressed, the first event
  403. above is generated. The handler for this event should issue the
  404. following command:
  405. echo undock > /proc/acpi/ibm/dock
  406. After the LED on the dock goes off, it is safe to eject the laptop.
  407. Note: if you pressed this key by mistake, go ahead and eject the
  408. laptop, then dock it back in. Otherwise, the dock may not function as
  409. expected.
  410. When the laptop is docked, the third event above is generated. The
  411. handler for this event should issue the following command to fully
  412. enable the dock:
  413. echo dock > /proc/acpi/ibm/dock
  414. The contents of the /proc/acpi/ibm/dock file shows the current status
  415. of the dock, as provided by the ACPI framework.
  416. The docking support in this driver does not take care of enabling or
  417. disabling any other devices you may have attached to the dock. For
  418. example, a CD drive plugged into the UltraBase needs to be disabled or
  419. enabled separately. See the provided example acpid configuration files
  420. for how this can be accomplished.
  421. There is no support yet for PCI devices that may be attached to a
  422. docking station, e.g. in the ThinkPad Dock II. The driver currently
  423. does not recognize, enable or disable such devices. This means that
  424. the only docking stations currently supported are the X-series
  425. UltraBase docks and "dumb" port replicators like the Mini Dock (the
  426. latter don't need any ACPI support, actually).
  427. UltraBay eject -- /proc/acpi/ibm/bay
  428. ------------------------------------
  429. Inserting or ejecting an UltraBay device requires some actions to be
  430. taken by the operating system to safely make or break the electrical
  431. connections with the device.
  432. This feature generates the following ACPI events:
  433. ibm/bay MSTR 00000003 00000000 -- eject request
  434. ibm/bay MSTR 00000001 00000000 -- eject lever inserted
  435. NOTE: These events will only be generated if the UltraBay was present
  436. when the laptop was originally booted (on the X series, the UltraBay
  437. is in the dock, so it may not be present if the laptop was undocked).
  438. This is due to the current lack of support for hot plugging of devices
  439. in the Linux ACPI framework. If the laptop was booted without the
  440. UltraBay, the following message is shown in the logs:
  441. Mar 17 01:42:34 aero kernel: thinkpad_acpi: bay device not present
  442. In this case, no bay-related events are generated but the eject
  443. command described below still works. It can be executed manually or
  444. triggered by a hot key combination.
  445. Sliding the eject lever generates the first event shown above. The
  446. handler for this event should take whatever actions are necessary to
  447. shut down the device in the UltraBay (e.g. call idectl), then issue
  448. the following command:
  449. echo eject > /proc/acpi/ibm/bay
  450. After the LED on the UltraBay goes off, it is safe to pull out the
  451. device.
  452. When the eject lever is inserted, the second event above is
  453. generated. The handler for this event should take whatever actions are
  454. necessary to enable the UltraBay device (e.g. call idectl).
  455. The contents of the /proc/acpi/ibm/bay file shows the current status
  456. of the UltraBay, as provided by the ACPI framework.
  457. EXPERIMENTAL warm eject support on the 600e/x, A22p and A3x (To use
  458. this feature, you need to supply the experimental=1 parameter when
  459. loading the module):
  460. These models do not have a button near the UltraBay device to request
  461. a hot eject but rather require the laptop to be put to sleep
  462. (suspend-to-ram) before the bay device is ejected or inserted).
  463. The sequence of steps to eject the device is as follows:
  464. echo eject > /proc/acpi/ibm/bay
  465. put the ThinkPad to sleep
  466. remove the drive
  467. resume from sleep
  468. cat /proc/acpi/ibm/bay should show that the drive was removed
  469. On the A3x, both the UltraBay 2000 and UltraBay Plus devices are
  470. supported. Use "eject2" instead of "eject" for the second bay.
  471. Note: the UltraBay eject support on the 600e/x, A22p and A3x is
  472. EXPERIMENTAL and may not work as expected. USE WITH CAUTION!
  473. CMOS control
  474. ------------
  475. procfs: /proc/acpi/ibm/cmos
  476. sysfs device attribute: cmos_command
  477. This feature is mostly used internally by the ACPI firmware to keep the legacy
  478. CMOS NVRAM bits in sync with the current machine state, and to record this
  479. state so that the ThinkPad will retain such settings across reboots.
  480. Some of these commands actually perform actions in some ThinkPad models, but
  481. this is expected to disappear more and more in newer models. As an example, in
  482. a T43 and in a X40, commands 12 and 13 still control the ThinkLight state for
  483. real, but commands 0 to 2 don't control the mixer anymore (they have been
  484. phased out) and just update the NVRAM.
  485. The range of valid cmos command numbers is 0 to 21, but not all have an
  486. effect and the behavior varies from model to model. Here is the behavior
  487. on the X40 (tpb is the ThinkPad Buttons utility):
  488. 0 - Related to "Volume down" key press
  489. 1 - Related to "Volume up" key press
  490. 2 - Related to "Mute on" key press
  491. 3 - Related to "Access IBM" key press
  492. 4 - Related to "LCD brightness up" key pess
  493. 5 - Related to "LCD brightness down" key press
  494. 11 - Related to "toggle screen expansion" key press/function
  495. 12 - Related to "ThinkLight on"
  496. 13 - Related to "ThinkLight off"
  497. 14 - Related to "ThinkLight" key press (toggle thinklight)
  498. The cmos command interface is prone to firmware split-brain problems, as
  499. in newer ThinkPads it is just a compatibility layer. Do not use it, it is
  500. exported just as a debug tool.
  501. LED control -- /proc/acpi/ibm/led
  502. ---------------------------------
  503. Some of the LED indicators can be controlled through this feature. The
  504. available commands are:
  505. echo '<led number> on' >/proc/acpi/ibm/led
  506. echo '<led number> off' >/proc/acpi/ibm/led
  507. echo '<led number> blink' >/proc/acpi/ibm/led
  508. The <led number> range is 0 to 7. The set of LEDs that can be
  509. controlled varies from model to model. Here is the mapping on the X40:
  510. 0 - power
  511. 1 - battery (orange)
  512. 2 - battery (green)
  513. 3 - UltraBase
  514. 4 - UltraBay
  515. 7 - standby
  516. All of the above can be turned on and off and can be made to blink.
  517. ACPI sounds -- /proc/acpi/ibm/beep
  518. ----------------------------------
  519. The BEEP method is used internally by the ACPI firmware to provide
  520. audible alerts in various situations. This feature allows the same
  521. sounds to be triggered manually.
  522. The commands are non-negative integer numbers:
  523. echo <number> >/proc/acpi/ibm/beep
  524. The valid <number> range is 0 to 17. Not all numbers trigger sounds
  525. and the sounds vary from model to model. Here is the behavior on the
  526. X40:
  527. 0 - stop a sound in progress (but use 17 to stop 16)
  528. 2 - two beeps, pause, third beep ("low battery")
  529. 3 - single beep
  530. 4 - high, followed by low-pitched beep ("unable")
  531. 5 - single beep
  532. 6 - very high, followed by high-pitched beep ("AC/DC")
  533. 7 - high-pitched beep
  534. 9 - three short beeps
  535. 10 - very long beep
  536. 12 - low-pitched beep
  537. 15 - three high-pitched beeps repeating constantly, stop with 0
  538. 16 - one medium-pitched beep repeating constantly, stop with 17
  539. 17 - stop 16
  540. Temperature sensors
  541. -------------------
  542. procfs: /proc/acpi/ibm/thermal
  543. sysfs device attributes: (hwmon) temp*_input
  544. Most ThinkPads include six or more separate temperature sensors but only
  545. expose the CPU temperature through the standard ACPI methods. This
  546. feature shows readings from up to eight different sensors on older
  547. ThinkPads, and up to sixteen different sensors on newer ThinkPads.
  548. For example, on the X40, a typical output may be:
  549. temperatures: 42 42 45 41 36 -128 33 -128
  550. On the T43/p, a typical output may be:
  551. temperatures: 48 48 36 52 38 -128 31 -128 48 52 48 -128 -128 -128 -128 -128
  552. The mapping of thermal sensors to physical locations varies depending on
  553. system-board model (and thus, on ThinkPad model).
  554. http://thinkwiki.org/wiki/Thermal_Sensors is a public wiki page that
  555. tries to track down these locations for various models.
  556. Most (newer?) models seem to follow this pattern:
  557. 1: CPU
  558. 2: (depends on model)
  559. 3: (depends on model)
  560. 4: GPU
  561. 5: Main battery: main sensor
  562. 6: Bay battery: main sensor
  563. 7: Main battery: secondary sensor
  564. 8: Bay battery: secondary sensor
  565. 9-15: (depends on model)
  566. For the R51 (source: Thomas Gruber):
  567. 2: Mini-PCI
  568. 3: Internal HDD
  569. For the T43, T43/p (source: Shmidoax/Thinkwiki.org)
  570. http://thinkwiki.org/wiki/Thermal_Sensors#ThinkPad_T43.2C_T43p
  571. 2: System board, left side (near PCMCIA slot), reported as HDAPS temp
  572. 3: PCMCIA slot
  573. 9: MCH (northbridge) to DRAM Bus
  574. 10: Clock-generator, mini-pci card and ICH (southbridge), under Mini-PCI
  575. card, under touchpad
  576. 11: Power regulator, underside of system board, below F2 key
  577. The A31 has a very atypical layout for the thermal sensors
  578. (source: Milos Popovic, http://thinkwiki.org/wiki/Thermal_Sensors#ThinkPad_A31)
  579. 1: CPU
  580. 2: Main Battery: main sensor
  581. 3: Power Converter
  582. 4: Bay Battery: main sensor
  583. 5: MCH (northbridge)
  584. 6: PCMCIA/ambient
  585. 7: Main Battery: secondary sensor
  586. 8: Bay Battery: secondary sensor
  587. Procfs notes:
  588. Readings from sensors that are not available return -128.
  589. No commands can be written to this file.
  590. Sysfs notes:
  591. Sensors that are not available return the ENXIO error. This
  592. status may change at runtime, as there are hotplug thermal
  593. sensors, like those inside the batteries and docks.
  594. thinkpad-acpi thermal sensors are reported through the hwmon
  595. subsystem, and follow all of the hwmon guidelines at
  596. Documentation/hwmon.
  597. EXPERIMENTAL: Embedded controller register dump -- /proc/acpi/ibm/ecdump
  598. ------------------------------------------------------------------------
  599. This feature is marked EXPERIMENTAL because the implementation
  600. directly accesses hardware registers and may not work as expected. USE
  601. WITH CAUTION! To use this feature, you need to supply the
  602. experimental=1 parameter when loading the module.
  603. This feature dumps the values of 256 embedded controller
  604. registers. Values which have changed since the last time the registers
  605. were dumped are marked with a star:
  606. [root@x40 ibm-acpi]# cat /proc/acpi/ibm/ecdump
  607. EC +00 +01 +02 +03 +04 +05 +06 +07 +08 +09 +0a +0b +0c +0d +0e +0f
  608. EC 0x00: a7 47 87 01 fe 96 00 08 01 00 cb 00 00 00 40 00
  609. EC 0x10: 00 00 ff ff f4 3c 87 09 01 ff 42 01 ff ff 0d 00
  610. EC 0x20: 00 00 00 00 00 00 00 00 00 00 00 03 43 00 00 80
  611. EC 0x30: 01 07 1a 00 30 04 00 00 *85 00 00 10 00 50 00 00
  612. EC 0x40: 00 00 00 00 00 00 14 01 00 04 00 00 00 00 00 00
  613. EC 0x50: 00 c0 02 0d 00 01 01 02 02 03 03 03 03 *bc *02 *bc
  614. EC 0x60: *02 *bc *02 00 00 00 00 00 00 00 00 00 00 00 00 00
  615. EC 0x70: 00 00 00 00 00 12 30 40 *24 *26 *2c *27 *20 80 *1f 80
  616. EC 0x80: 00 00 00 06 *37 *0e 03 00 00 00 0e 07 00 00 00 00
  617. EC 0x90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  618. EC 0xa0: *ff 09 ff 09 ff ff *64 00 *00 *00 *a2 41 *ff *ff *e0 00
  619. EC 0xb0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  620. EC 0xc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  621. EC 0xd0: 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  622. EC 0xe0: 00 00 00 00 00 00 00 00 11 20 49 04 24 06 55 03
  623. EC 0xf0: 31 55 48 54 35 38 57 57 08 2f 45 73 07 65 6c 1a
  624. This feature can be used to determine the register holding the fan
  625. speed on some models. To do that, do the following:
  626. - make sure the battery is fully charged
  627. - make sure the fan is running
  628. - run 'cat /proc/acpi/ibm/ecdump' several times, once per second or so
  629. The first step makes sure various charging-related values don't
  630. vary. The second ensures that the fan-related values do vary, since
  631. the fan speed fluctuates a bit. The third will (hopefully) mark the
  632. fan register with a star:
  633. [root@x40 ibm-acpi]# cat /proc/acpi/ibm/ecdump
  634. EC +00 +01 +02 +03 +04 +05 +06 +07 +08 +09 +0a +0b +0c +0d +0e +0f
  635. EC 0x00: a7 47 87 01 fe 96 00 08 01 00 cb 00 00 00 40 00
  636. EC 0x10: 00 00 ff ff f4 3c 87 09 01 ff 42 01 ff ff 0d 00
  637. EC 0x20: 00 00 00 00 00 00 00 00 00 00 00 03 43 00 00 80
  638. EC 0x30: 01 07 1a 00 30 04 00 00 85 00 00 10 00 50 00 00
  639. EC 0x40: 00 00 00 00 00 00 14 01 00 04 00 00 00 00 00 00
  640. EC 0x50: 00 c0 02 0d 00 01 01 02 02 03 03 03 03 bc 02 bc
  641. EC 0x60: 02 bc 02 00 00 00 00 00 00 00 00 00 00 00 00 00
  642. EC 0x70: 00 00 00 00 00 12 30 40 24 27 2c 27 21 80 1f 80
  643. EC 0x80: 00 00 00 06 *be 0d 03 00 00 00 0e 07 00 00 00 00
  644. EC 0x90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  645. EC 0xa0: ff 09 ff 09 ff ff 64 00 00 00 a2 41 ff ff e0 00
  646. EC 0xb0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  647. EC 0xc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  648. EC 0xd0: 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  649. EC 0xe0: 00 00 00 00 00 00 00 00 11 20 49 04 24 06 55 03
  650. EC 0xf0: 31 55 48 54 35 38 57 57 08 2f 45 73 07 65 6c 1a
  651. Another set of values that varies often is the temperature
  652. readings. Since temperatures don't change vary fast, you can take
  653. several quick dumps to eliminate them.
  654. You can use a similar method to figure out the meaning of other
  655. embedded controller registers - e.g. make sure nothing else changes
  656. except the charging or discharging battery to determine which
  657. registers contain the current battery capacity, etc. If you experiment
  658. with this, do send me your results (including some complete dumps with
  659. a description of the conditions when they were taken.)
  660. LCD brightness control
  661. ----------------------
  662. procfs: /proc/acpi/ibm/brightness
  663. sysfs backlight device "thinkpad_screen"
  664. This feature allows software control of the LCD brightness on ThinkPad
  665. models which don't have a hardware brightness slider.
  666. It has some limitations: the LCD backlight cannot be actually turned on or off
  667. by this interface, and in many ThinkPad models, the "dim while on battery"
  668. functionality will be enabled by the BIOS when this interface is used, and
  669. cannot be controlled.
  670. The backlight control has eight levels, ranging from 0 to 7. Some of the
  671. levels may not be distinct.
  672. There are two interfaces to the firmware for brightness control, EC and CMOS.
  673. To select which one should be used, use the brightness_mode module parameter:
  674. brightness_mode=1 selects EC mode, brightness_mode=2 selects CMOS mode,
  675. brightness_mode=3 selects both EC and CMOS. The driver tries to autodetect
  676. which interface to use.
  677. Procfs notes:
  678. The available commands are:
  679. echo up >/proc/acpi/ibm/brightness
  680. echo down >/proc/acpi/ibm/brightness
  681. echo 'level <level>' >/proc/acpi/ibm/brightness
  682. Sysfs notes:
  683. The interface is implemented through the backlight sysfs class, which is poorly
  684. documented at this time.
  685. Locate the thinkpad_screen device under /sys/class/backlight, and inside it
  686. there will be the following attributes:
  687. max_brightness:
  688. Reads the maximum brightness the hardware can be set to.
  689. The minimum is always zero.
  690. actual_brightness:
  691. Reads what brightness the screen is set to at this instant.
  692. brightness:
  693. Writes request the driver to change brightness to the given
  694. value. Reads will tell you what brightness the driver is trying
  695. to set the display to when "power" is set to zero and the display
  696. has not been dimmed by a kernel power management event.
  697. power:
  698. power management mode, where 0 is "display on", and 1 to 3 will
  699. dim the display backlight to brightness level 0 because
  700. thinkpad-acpi cannot really turn the backlight off. Kernel
  701. power management events can temporarily increase the current
  702. power management level, i.e. they can dim the display.
  703. Volume control -- /proc/acpi/ibm/volume
  704. ---------------------------------------
  705. This feature allows volume control on ThinkPad models which don't have
  706. a hardware volume knob. The available commands are:
  707. echo up >/proc/acpi/ibm/volume
  708. echo down >/proc/acpi/ibm/volume
  709. echo mute >/proc/acpi/ibm/volume
  710. echo 'level <level>' >/proc/acpi/ibm/volume
  711. The <level> number range is 0 to 15 although not all of them may be
  712. distinct. The unmute the volume after the mute command, use either the
  713. up or down command (the level command will not unmute the volume).
  714. The current volume level and mute state is shown in the file.
  715. Fan control and monitoring: fan speed, fan enable/disable
  716. ---------------------------------------------------------
  717. procfs: /proc/acpi/ibm/fan
  718. sysfs device attributes: (hwmon) fan_input, pwm1, pwm1_enable
  719. NOTE NOTE NOTE: fan control operations are disabled by default for
  720. safety reasons. To enable them, the module parameter "fan_control=1"
  721. must be given to thinkpad-acpi.
  722. This feature attempts to show the current fan speed, control mode and
  723. other fan data that might be available. The speed is read directly
  724. from the hardware registers of the embedded controller. This is known
  725. to work on later R, T, X and Z series ThinkPads but may show a bogus
  726. value on other models.
  727. Fan levels:
  728. Most ThinkPad fans work in "levels" at the firmware interface. Level 0
  729. stops the fan. The higher the level, the higher the fan speed, although
  730. adjacent levels often map to the same fan speed. 7 is the highest
  731. level, where the fan reaches the maximum recommended speed.
  732. Level "auto" means the EC changes the fan level according to some
  733. internal algorithm, usually based on readings from the thermal sensors.
  734. There is also a "full-speed" level, also known as "disengaged" level.
  735. In this level, the EC disables the speed-locked closed-loop fan control,
  736. and drives the fan as fast as it can go, which might exceed hardware
  737. limits, so use this level with caution.
  738. The fan usually ramps up or down slowly from one speed to another, and
  739. it is normal for the EC to take several seconds to react to fan
  740. commands. The full-speed level may take up to two minutes to ramp up to
  741. maximum speed, and in some ThinkPads, the tachometer readings go stale
  742. while the EC is transitioning to the full-speed level.
  743. WARNING WARNING WARNING: do not leave the fan disabled unless you are
  744. monitoring all of the temperature sensor readings and you are ready to
  745. enable it if necessary to avoid overheating.
  746. An enabled fan in level "auto" may stop spinning if the EC decides the
  747. ThinkPad is cool enough and doesn't need the extra airflow. This is
  748. normal, and the EC will spin the fan up if the varios thermal readings
  749. rise too much.
  750. On the X40, this seems to depend on the CPU and HDD temperatures.
  751. Specifically, the fan is turned on when either the CPU temperature
  752. climbs to 56 degrees or the HDD temperature climbs to 46 degrees. The
  753. fan is turned off when the CPU temperature drops to 49 degrees and the
  754. HDD temperature drops to 41 degrees. These thresholds cannot
  755. currently be controlled.
  756. The ThinkPad's ACPI DSDT code will reprogram the fan on its own when
  757. certain conditions are met. It will override any fan programming done
  758. through thinkpad-acpi.
  759. The thinkpad-acpi kernel driver can be programmed to revert the fan
  760. level to a safe setting if userspace does not issue one of the procfs
  761. fan commands: "enable", "disable", "level" or "watchdog", or if there
  762. are no writes to pwm1_enable (or to pwm1 *if and only if* pwm1_enable is
  763. set to 1, manual mode) within a configurable amount of time of up to
  764. 120 seconds. This functionality is called fan safety watchdog.
  765. Note that the watchdog timer stops after it enables the fan. It will be
  766. rearmed again automatically (using the same interval) when one of the
  767. above mentioned fan commands is received. The fan watchdog is,
  768. therefore, not suitable to protect against fan mode changes made through
  769. means other than the "enable", "disable", and "level" procfs fan
  770. commands, or the hwmon fan control sysfs interface.
  771. Procfs notes:
  772. The fan may be enabled or disabled with the following commands:
  773. echo enable >/proc/acpi/ibm/fan
  774. echo disable >/proc/acpi/ibm/fan
  775. Placing a fan on level 0 is the same as disabling it. Enabling a fan
  776. will try to place it in a safe level if it is too slow or disabled.
  777. The fan level can be controlled with the command:
  778. echo 'level <level>' > /proc/acpi/ibm/fan
  779. Where <level> is an integer from 0 to 7, or one of the words "auto" or
  780. "full-speed" (without the quotes). Not all ThinkPads support the "auto"
  781. and "full-speed" levels. The driver accepts "disengaged" as an alias for
  782. "full-speed", and reports it as "disengaged" for backwards
  783. compatibility.
  784. On the X31 and X40 (and ONLY on those models), the fan speed can be
  785. controlled to a certain degree. Once the fan is running, it can be
  786. forced to run faster or slower with the following command:
  787. echo 'speed <speed>' > /proc/acpi/ibm/fan
  788. The sustainable range of fan speeds on the X40 appears to be from about
  789. 3700 to about 7350. Values outside this range either do not have any
  790. effect or the fan speed eventually settles somewhere in that range. The
  791. fan cannot be stopped or started with this command. This functionality
  792. is incomplete, and not available through the sysfs interface.
  793. To program the safety watchdog, use the "watchdog" command.
  794. echo 'watchdog <interval in seconds>' > /proc/acpi/ibm/fan
  795. If you want to disable the watchdog, use 0 as the interval.
  796. Sysfs notes:
  797. The sysfs interface follows the hwmon subsystem guidelines for the most
  798. part, and the exception is the fan safety watchdog.
  799. Writes to any of the sysfs attributes may return the EINVAL error if
  800. that operation is not supported in a given ThinkPad or if the parameter
  801. is out-of-bounds, and EPERM if it is forbidden. They may also return
  802. EINTR (interrupted system call), and EIO (I/O error while trying to talk
  803. to the firmware).
  804. Features not yet implemented by the driver return ENOSYS.
  805. hwmon device attribute pwm1_enable:
  806. 0: PWM offline (fan is set to full-speed mode)
  807. 1: Manual PWM control (use pwm1 to set fan level)
  808. 2: Hardware PWM control (EC "auto" mode)
  809. 3: reserved (Software PWM control, not implemented yet)
  810. Modes 0 and 2 are not supported by all ThinkPads, and the
  811. driver is not always able to detect this. If it does know a
  812. mode is unsupported, it will return -EINVAL.
  813. hwmon device attribute pwm1:
  814. Fan level, scaled from the firmware values of 0-7 to the hwmon
  815. scale of 0-255. 0 means fan stopped, 255 means highest normal
  816. speed (level 7).
  817. This attribute only commands the fan if pmw1_enable is set to 1
  818. (manual PWM control).
  819. hwmon device attribute fan1_input:
  820. Fan tachometer reading, in RPM. May go stale on certain
  821. ThinkPads while the EC transitions the PWM to offline mode,
  822. which can take up to two minutes. May return rubbish on older
  823. ThinkPads.
  824. driver attribute fan_watchdog:
  825. Fan safety watchdog timer interval, in seconds. Minimum is
  826. 1 second, maximum is 120 seconds. 0 disables the watchdog.
  827. To stop the fan: set pwm1 to zero, and pwm1_enable to 1.
  828. To start the fan in a safe mode: set pwm1_enable to 2. If that fails
  829. with EINVAL, try to set pwm1_enable to 1 and pwm1 to at least 128 (255
  830. would be the safest choice, though).
  831. EXPERIMENTAL: WAN
  832. -----------------
  833. procfs: /proc/acpi/ibm/wan
  834. sysfs device attribute: wwan_enable
  835. This feature is marked EXPERIMENTAL because the implementation
  836. directly accesses hardware registers and may not work as expected. USE
  837. WITH CAUTION! To use this feature, you need to supply the
  838. experimental=1 parameter when loading the module.
  839. This feature shows the presence and current state of a W-WAN (Sierra
  840. Wireless EV-DO) device.
  841. It was tested on a Lenovo Thinkpad X60. It should probably work on other
  842. Thinkpad models which come with this module installed.
  843. Procfs notes:
  844. If the W-WAN card is installed, the following commands can be used:
  845. echo enable > /proc/acpi/ibm/wan
  846. echo disable > /proc/acpi/ibm/wan
  847. Sysfs notes:
  848. If the W-WAN card is installed, it can be enabled /
  849. disabled through the "wwan_enable" thinkpad-acpi device
  850. attribute, and its current status can also be queried.
  851. enable:
  852. 0: disables WWAN card / WWAN card is disabled
  853. 1: enables WWAN card / WWAN card is enabled.
  854. Note: this interface will be probably be superseeded by the
  855. generic rfkill class, so it is NOT to be considered stable yet.
  856. Multiple Commands, Module Parameters
  857. ------------------------------------
  858. Multiple commands can be written to the proc files in one shot by
  859. separating them with commas, for example:
  860. echo enable,0xffff > /proc/acpi/ibm/hotkey
  861. echo lcd_disable,crt_enable > /proc/acpi/ibm/video
  862. Commands can also be specified when loading the thinkpad-acpi module,
  863. for example:
  864. modprobe thinkpad_acpi hotkey=enable,0xffff video=auto_disable
  865. Enabling debugging output
  866. -------------------------
  867. The module takes a debug paramater which can be used to selectively
  868. enable various classes of debugging output, for example:
  869. modprobe ibm_acpi debug=0xffff
  870. will enable all debugging output classes. It takes a bitmask, so
  871. to enable more than one output class, just add their values.
  872. Debug bitmask Description
  873. 0x0001 Initialization and probing
  874. 0x0002 Removal
  875. There is also a kernel build option to enable more debugging
  876. information, which may be necessary to debug driver problems.
  877. The level of debugging information output by the driver can be changed
  878. at runtime through sysfs, using the driver attribute debug_level. The
  879. attribute takes the same bitmask as the debug module parameter above.
  880. Force loading of module
  881. -----------------------
  882. If thinkpad-acpi refuses to detect your ThinkPad, you can try to specify
  883. the module parameter force_load=1. Regardless of whether this works or
  884. not, please contact ibm-acpi-devel@lists.sourceforge.net with a report.
  885. Sysfs interface changelog:
  886. 0x000100: Initial sysfs support, as a single platform driver and
  887. device.
  888. 0x000200: Hot key support for 32 hot keys, and radio slider switch
  889. support.
  890. 0x010000: Hot keys are now handled by default over the input
  891. layer, the radio switch generates input event EV_RADIO,
  892. and the driver enables hot key handling by default in
  893. the firmware.