<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.thinkwiki.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=ThinkGNU</id>
	<title>ThinkWiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://www.thinkwiki.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=ThinkGNU"/>
	<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/wiki/Special:Contributions/ThinkGNU"/>
	<updated>2026-04-11T15:30:43Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.31.12</generator>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=ThinkWiki_talk:General_disclaimer&amp;diff=62694</id>
		<title>ThinkWiki talk:General disclaimer</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=ThinkWiki_talk:General_disclaimer&amp;diff=62694"/>
		<updated>2026-01-21T03:48:21Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Added note, removed spam.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Anything forgotten?&lt;br /&gt;
Please tell us!&lt;br /&gt;
&lt;br /&gt;
--[[User:Akw|akw]] 13:01, 27 Sep 2004 (CEST)&lt;br /&gt;
&lt;br /&gt;
`&amp;quot;ThinkWiki&amp;quot; and the ThinkWiki logo are private property of Arno Willig` - what on earth does this mean? Is &amp;quot;ThinkWiki&amp;quot; trademarked? As for the logo, it includes the Linux penguin, which different drawings have been released under difference licenses, for example the GPLv2-or-later - regardless neither trademarks nor copyrights are property laws. I also see &amp;quot;the original authors of these ThinkWiki articles under the GFDL licensing scheme&amp;quot; - wouldn't that mean that the articles would really need to be released under a GFDL«version»-compatible license? [[User:ThinkGNU|ThinkGNU]] ([[User talk:ThinkGNU|talk]]) 04:48, 21 January 2026 (CET)&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Category:500&amp;diff=62693</id>
		<title>Category:500</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Category:500&amp;diff=62693"/>
		<updated>2026-01-21T03:36:41Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Seems × got corrupted into Ã—?&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== ThinkPad 500 ===&lt;br /&gt;
This page gives an overview of all ThinkPad 500 related topics.&lt;br /&gt;
==== Standard Features ====&lt;br /&gt;
* [[IBM 486|IBM 486 SLC2]] 50 MHz CPU&lt;br /&gt;
* [[WD90C26]] video controller&lt;br /&gt;
* Monochrome 7.24&amp;quot; [[STN display]] with 640×480 resolution&lt;br /&gt;
* 4MB memory standard&lt;br /&gt;
* 85 or 170MB HDD&lt;br /&gt;
* External 1.44MB FDD&lt;br /&gt;
* (1) Type II [[PCMCIA slot]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
* [http://download.lenovo.com/ibmdl/pub/pc/pccbbs/bp_thinkpad/tpvol1.pdf HMM - ThinkPad 500]&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
[[image:ThinkPad500.jpg|ThinkPad 500]]&lt;br /&gt;
|}&lt;br /&gt;
[[Category:5 Series]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Category:R400&amp;diff=62692</id>
		<title>Category:R400</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Category:R400&amp;diff=62692"/>
		<updated>2025-10-27T04:29:01Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: I ran into a R400 with switchable Radeon graphics - the 2787-22M - so those do exist. I can't find any evidence that models with nvidia graphics existed.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== ThinkPad R400 ===&lt;br /&gt;
This page gives an overview of the ThinkPad R400.&lt;br /&gt;
&lt;br /&gt;
=== Machine Type ===&lt;br /&gt;
{{NOTE|Switchable Graphics models are extremely rare but do exist.}}&lt;br /&gt;
* 2782, 2783, 2784, 2786, 2787, 2788, 2789 AMD Mobility Radeon HD3470&lt;br /&gt;
* 7438, 7439, 7440, 7443, 7445, 7446, 7447 Intel Graphics GMA 4500MHD&lt;br /&gt;
&lt;br /&gt;
It appears that some models (such as 2784-R1U) were possibly shipped with nVidia Ge Force 9300M graphics&lt;br /&gt;
&lt;br /&gt;
==== Standard Features ====&lt;br /&gt;
* One of the following processors:&lt;br /&gt;
** [[Intel Core 2 Duo (Merom)]] T5870 and 5670&lt;br /&gt;
** [[Intel Core 2 Duo (Penryn)]] P8400, P8600, T9400 and T9600&lt;br /&gt;
** [[Intel Celeron M| Intel Celeron M (Merom L)]] 575 and 585&lt;br /&gt;
* Chipset&lt;br /&gt;
** Mobile Intel® GM45 Express CS/ICH 9M-E&lt;br /&gt;
** Mobile Intel® GMA X4500 HD&lt;br /&gt;
** Mobile Intel® GL667 MHz (Celeron®)&lt;br /&gt;
* One of the following graphics adapters:&lt;br /&gt;
** [[Intel Graphics Media Accelerator 4500MHD]]&lt;br /&gt;
** [[Switchable Graphics]] with [[Intel Graphics Media_Accelerator 4500MHD|Intel GMA 4500MHD]] and [[ATI Mobility Radeon HD 3470]] &lt;br /&gt;
** [[nVidia GeForce 9300M]] (unconfirmed)&lt;br /&gt;
* One of the following displays:&lt;br /&gt;
** 14.1&amp;quot; wide: WXGA (1280 x 800, 107DPI, 185+ nit)&lt;br /&gt;
** 14.1&amp;quot; wide: WXGA+ (1440 x 900, 120DPI, 200+ nit)&lt;br /&gt;
*System Memory&lt;br /&gt;
** Up to 8GB of [[PC3-8500]] 1066MHz DDR3&lt;br /&gt;
*Harddrive&lt;br /&gt;
** 80, 160, 250 or 320GB 5400RPM SATA HDD &lt;br /&gt;
** 160, 200GB (FDE) 7200 RPM SATA HDD &lt;br /&gt;
* [[Intel Gigabit Ethernet (10/100/1000) PCI-Express]]&lt;br /&gt;
* Intel HD Audio with a [[CX20561]] codec&lt;br /&gt;
* [[ThinkPad Modem (MDC-3.0, 56kbps HDA)]]&lt;br /&gt;
* [[MiniPCI Express slot]] 1 with one of the following:&lt;br /&gt;
** [[Intel Wifi Link 5100 (AGN)]] (1x2AGN)&lt;br /&gt;
** [[Intel Wifi Link 5300 (AGN)]] (3x3 AGN)&lt;br /&gt;
** [[ThinkPad 11b/g/n Wireless LAN Mini-PCI Express Adapter II]]&lt;br /&gt;
* [[MiniPCI Express slot]] 2 with one of the following:&lt;br /&gt;
** None (not upgradable)&lt;br /&gt;
** [[Intel® Turbo Memory hard drive cache]] up to 2GB&lt;br /&gt;
** [[Wireless USB (UWB)]]&lt;br /&gt;
* 1 [[CardBus slot]] (Type 2)&lt;br /&gt;
* under which there one of:&lt;br /&gt;
** [[ExpressCard slot|ExpressCard/54 slot]] &lt;br /&gt;
** SmartCard reader&lt;br /&gt;
** [[Ricoh_R5C843|4-in-1 Memory reader]]&lt;br /&gt;
* [[Embedded Security Subsystem|Trusted Computing Group TPM 1.2]]&lt;br /&gt;
* [[Active Protection System]]&lt;br /&gt;
* [[Integrated Fingerprint Reader]] on select models&lt;br /&gt;
* [[ThinkPad_Bluetooth_with_Enhanced_Data_Rate_(BDC-2.1)|Bluetooth]] on select models&lt;br /&gt;
* [[UltraNav]] (TrackPoint / Touchpad combo)&lt;br /&gt;
* 1.3MP [[Integrated camera]] on select models&lt;br /&gt;
* [[Firewire Port|Firewire 400]] (IEEE1394a) on selected models&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
[[image:ThinkPadR400.jpg|ThinkPad R400|300px]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:R Series]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=ATI_Mobility_Radeon_HD_3470&amp;diff=62691</id>
		<title>ATI Mobility Radeon HD 3470</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=ATI_Mobility_Radeon_HD_3470&amp;diff=62691"/>
		<updated>2025-10-27T04:09:46Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: The driver has only some source code available - part of the driver is proprietary software that runs on the card. The driver has improved.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is a ATI video adapter&lt;br /&gt;
== Features ==&lt;br /&gt;
* Chipset: ATI RV620&lt;br /&gt;
* PCI ID: 1002:95c4&lt;br /&gt;
* PCI-E&lt;br /&gt;
* 128 or 256MB video memory&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Linux driver - Partially Source Available ==&lt;br /&gt;
The partially source-available &amp;quot;radeon&amp;quot; driver works quite well for 2D. It gets a bit hotter than fglrx. 3D support was previously limited as per the [https://web.archive.org/web/20121101090730if_/http://www.x.org/wiki/RadeonProgram old radeon game database], but it is now reported to [https://www.x.org/wiki/RadeonFeature/ work fine].&lt;br /&gt;
&lt;br /&gt;
The patched version of radeon in GNU Linux-libre works fine with llvmpipe - 3D is just slow and suspend cannot work.&lt;br /&gt;
&lt;br /&gt;
== Linux driver - Proprietary ==&lt;br /&gt;
Please look at the [[fglrx]] page for details&lt;br /&gt;
&lt;br /&gt;
== ThinkPads this chip may be found in ==&lt;br /&gt;
* {{R400}}, {{R500}}&lt;br /&gt;
* {{T400}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Video Controllers]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=CompactFlash_boot_drive&amp;diff=62690</id>
		<title>CompactFlash boot drive</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=CompactFlash_boot_drive&amp;diff=62690"/>
		<updated>2025-10-27T03:45:09Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Grammar. It is incorrect that a single business came up with SSD write reduction. Linux is only a kernel. Occasionally de-fragmenting a large SSD improves performance as metadata frag. reduces it.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
[[image:Addonics.JPG|thumb|Addonics Dual CF-IDE HDD Adapter with 8GB SanDisk Extreme IV CompactFlash]]&lt;br /&gt;
Changing your HDD for a CF boot drive (CompactFlash card on CF-PATA/SATA adapter) is an alternative to using SSD to boost the performance.&lt;br /&gt;
&lt;br /&gt;
This is primarily done by ThinkPad {{X40}}, {{X41}} and {{X41 Tablet}} series owners due to the extremely slow speed of the 1.8&amp;quot; HDD.&lt;br /&gt;
&lt;br /&gt;
Previously, using CompactFlash cards meant giving up on storage capacity. Nowadays the biggest available CF sizes are up to 100 GB so you even gain more storage space compared to a classic 1.8&amp;quot; HDD.&lt;br /&gt;
&lt;br /&gt;
ThinkPads utilizing a PATA controller for the HDD slot can recognize both CF cards installed on a dual adapter. While newer ThinkPads, such as X41, which utilize a SATA controller, can only recognize the single card installed in the primary slot.&lt;br /&gt;
&lt;br /&gt;
===Advantages of CF boot drive===&lt;br /&gt;
* Much faster access time (&amp;lt;1ms for CF, &amp;gt;20ms for 4200RPM HDD and &amp;gt;15ms for 5400RPM HDD)&lt;br /&gt;
* Higher read throughput for &amp;gt;8KB blocks (may differ depending on brand, model, partition type and cluster size)&lt;br /&gt;
* Higher write throughput for &amp;gt;64KB blocks (may differ depending on brand, model, partition type and cluster size)&lt;br /&gt;
* Minimal risk of mechanical damage due to shock and vibration. The [[Active Protection System]] is therefore unnecessary&lt;br /&gt;
* Does not generate any noise or vibrations&lt;br /&gt;
* (Possibly) a slight increase in battery life&lt;br /&gt;
* (Possibly) less heat being generated&lt;br /&gt;
&lt;br /&gt;
===Disadvantages of CF boot drive===&lt;br /&gt;
* Lower read throughput for &amp;lt;8KB blocks (may differ depending on brand, model, partition type and cluster size)&lt;br /&gt;
* Lower write throughput for &amp;lt;64KB blocks (may differ depending on brand, model, partition type and cluster size)&lt;br /&gt;
* Lower capacity&lt;br /&gt;
* Higher price per GB&lt;br /&gt;
* Not officially supported&lt;br /&gt;
* Invoke boot error 2010 on certain ThinkPads, including the X41 series&lt;br /&gt;
&lt;br /&gt;
{{NOTE|A often mentioned disadvantage of flash-based storage is the limited number of write cycles (typically 100,000 for the current generation Single-Level Cell (SLC) NAND, the type typically used in the faster CF cards). This should not however be as much of an issue because...&amp;lt;br&amp;gt;&lt;br /&gt;
* The 100,000 write cycles applies to each address block separately in the card, not to the card as a whole&amp;lt;br&amp;gt;&lt;br /&gt;
* The flash controller automatically distributes write operations evenly (wear leveling), so that the number of writes to each address block is kept low&amp;lt;br&amp;gt;&lt;br /&gt;
Therefore, it should take years of typical real world usage to render a flash memory card based on SLC NAND unusable&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
However, manufacturers beginning in 2008 started using Multi-Level Cell (MLC) NAND to make SSDs. MLC NAND typically has only around 10,000 write cycles per block. But there are techniques that flash controllers can use to reduce write amplification and therefore extend SSD lifespan - for example a company called EasyCo claims Managed Flash Technology (MFT) &amp;quot;increases the write-life of Flash Disks more than 50-fold&amp;quot;.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If in doubt, check with the manufacturer directly for details.&lt;br /&gt;
&lt;br /&gt;
See [http://www.storagesearch.com/ssdmyths-endurance.html] and [http://www.storagesearch.com/ssd-slc-mlc-notes.html] for more information.}}&lt;br /&gt;
&lt;br /&gt;
==What you need==&lt;br /&gt;
* A passive CF to PATA/SATA adapter&lt;br /&gt;
** Sadly, the X30's native CF slot does not appear to be bootable, so you're stuck using an adapter in the PATA drive sled like everyone else.&lt;br /&gt;
* One or more CompactFlash cards with the following parameters:&lt;br /&gt;
** (For Windows) Identify itself as a fixed disk instead of removable media&lt;br /&gt;
** (Preferably) UDMA support&lt;br /&gt;
** (Preferably) 266X speed or better&lt;br /&gt;
&lt;br /&gt;
==CF to PATA adapter==&lt;br /&gt;
===CF to PATA (IDE)===&lt;br /&gt;
These adapters will work with both ThinkPads with 1.8&amp;quot; and 2.5&amp;quot; HDD slot with PATA interface&lt;br /&gt;
* Addonics AD44MIDECF (single slot) [http://www.addonics.com/products/flash_memory_reader/ad44midecf.asp]&lt;br /&gt;
* Addonics AD44MIDE2CF (dual slot) [http://www.addonics.com/products/flash_memory_reader/ad44midecf.asp]&lt;br /&gt;
&lt;br /&gt;
{{WARN|Many of the adapters sold in eBay may not be usable for x40 as their #1 pin is on the left side (looking from the top, usually marked by a white diagonal line). The #1 pin should be on the right side as the Addonics series. Flipping the insertion of popular &amp;quot;V B1&amp;quot; adapter works but there is no guarantee of performance and space may not permit. On the other hand PA-CF18H adapter has been reported to work fine and may be a good alternative for Addonics converters. Please read page 15 of the forum discussion link below this page.}}&lt;br /&gt;
&lt;br /&gt;
{{WARN|The second (slave) slots on dual slot adapters, or a single slot configured as slave (Device 1), do not work on newer ThinkPads, including the {{X41}}, {{X41T}}, {{T43}}, {{T43p}} and {{R52}}. Because their ATA interface is actually connected to the SATA controller via a PATA-SATA bridge.&lt;br /&gt;
The second slot works fine on the others, like the X40, which use a native PATA controller, and 2 separated drives will be recognized.}}&lt;br /&gt;
&lt;br /&gt;
{{WARN|On the {{X41}}, {{X41T}}, {{T43}}, {{T43p}} and {{R52}}, the [[Problem with non-ThinkPad hard disks|system will complain that an unsupported disk is installed (Error 2010)]], but will continue to boot after 5-10 seconds or after pressing enter (assuming you have a recent BIOS installed). The beeps can be muted by using the hardware mute button before the last shutdown/reboot}}&lt;br /&gt;
&lt;br /&gt;
==CompactFlash cards==&lt;br /&gt;
&lt;br /&gt;
===Speed===&lt;br /&gt;
While many CF cards claim to have high throughput, it's not necessarily a good indicator. As the claimed throughput is usually only attainable in specific situations (usually sequential and large block operations). But in typical usage as a boot drive, it usually involves lots of random and small block operations.&lt;br /&gt;
&lt;br /&gt;
Therefore, the actual performance figures can only be found out via real world benchmarks.&lt;br /&gt;
&lt;br /&gt;
Below is a list of some of the cards reported to be working, it's by no mean authoritative and final.&lt;br /&gt;
&lt;br /&gt;
{{WARN|&lt;br /&gt;
Most CompactFlash cards by default identify themselves as '''removable media''' instead of '''fixed disk'''. Which is fine for GNU/Linux, but not for Windows.&lt;br /&gt;
&lt;br /&gt;
If you have to use a CF card that has the type bits set to Removable and want to install Windows XP you can work around it as follows;&lt;br /&gt;
* Use fdisk &amp;amp; mkfs.fat or (g)parted in GNU/Linux to partition the drive with a FAT32 partition (you can boot from one of the LiveCD/LiveUSB distributions for this), making sure to set the partition as bootable.&lt;br /&gt;
* Start the install of Windows, during install you will be given the opportunity to migrate to NTFS&lt;br /&gt;
* After the install is finished you will need to install the Hitachi microdrive disk drivers (google for XPfildrvr1224.zip), which will mask the removable bits and should allow suspend and other operations that fail on a removable drive to work.}}&lt;br /&gt;
&lt;br /&gt;
===Transcend 133X/266X/300X===&lt;br /&gt;
These cards are known to identify themselves as fixed disk via CF-IDE adapters without any manual intervention, and is of good value, and speed (for 266X/300X).&lt;br /&gt;
&lt;br /&gt;
===SanDisk Extreme===&lt;br /&gt;
SanDisk used to provide a utility (when asked) under NDA to change the type bit to Fixed disk. It now refuses to provide it. This utility (ATCFWCHG.COM) however can be found for download at various places (try a search engine).&lt;br /&gt;
&lt;br /&gt;
You will need to boot DOS and run it with the CF configured as either the master on the primary IDE interface or the master on the secondary interface. It will not work if the drive is attached as a slave or to any other interfaces.&lt;br /&gt;
&lt;br /&gt;
To set a SanDisk Extreme adapter attached to the primary IDE interface to Fixed disk&lt;br /&gt;
 ATCFWCHG.COM /P /F&lt;br /&gt;
To set a SanDisk Extreme adapter attached to the secondary IDE interface (Ultrabay) to Fixed disk&lt;br /&gt;
 ATCFWCHG.COM /S /F&lt;br /&gt;
&lt;br /&gt;
{{NOTE|It seems that the ATCFWCHG.EXE utility is incompatible with SATA to IDE bridges, such as found in the X41. In those cases you will have to connect the CF card to another computer or ThinkPad with a regular IDE (PATA) interface to change the flag, after which you can put it into the ThinkPad X41.}}&lt;br /&gt;
&lt;br /&gt;
===SanDisk Ultra II 4 GB===&lt;br /&gt;
This card doesn't work with the Debian stable 2.6.26 kernel in a X41 tablet with SATA controller, it seems to be to slow.&lt;br /&gt;
&lt;br /&gt;
===Kingston Ultimate===&lt;br /&gt;
The Kingston Ultimate CF card ships as CF-Removable, and although Kingston admits it is possible to change the type to Fixed disk, it was not willing when asked to provide a tool/application for this purpose.&lt;br /&gt;
&lt;br /&gt;
But supposedly the Kingston card automatically changes ID based on the adapter used, so it will ID as fixed disk when used with an IDE-CF or SATA-CF adapter, but will ID as CF-Removable when used with a PCMCIA adapter.&lt;br /&gt;
&lt;br /&gt;
===Silicon Power 300X===&lt;br /&gt;
to be updated&lt;br /&gt;
&lt;br /&gt;
===Photofast 533X===&lt;br /&gt;
Works fine, read performance up to 43mbit/s acording to hdparm&lt;br /&gt;
&lt;br /&gt;
==Storage capacity issues==&lt;br /&gt;
Due to the limited capacity for high speed CF cards, the space may not be enough for some users. As a typical OS may already consume 3-4GB already. Here are some suggestions on how to work around it. Each of the below suggestion has its pros and cons, and should be selected on a case-to-case basis.&lt;br /&gt;
* Put only the OS and frequently accessed files on the main CF card&lt;br /&gt;
* (If dual-CF is possible) Add a second CF card, which will show up as an additional drive. Moreover since the speed needs not be as fast as the main CF card, a slower card with larger capacity could be desirable.&lt;br /&gt;
* On certain ThinkPads, there is an internal card reader (e.g. CF on X20/X30, and SD/SDHC on X40/X41/X60/X61) which can house another flash card. However, the speed is certainly to be worse than connecting to the PATA/SATA interface.&lt;br /&gt;
* Use a PC Card/ExpressCard SSD drive. However, the price of SSD is likely to be more expensive than flash cards.&lt;br /&gt;
* Use a PC Card/ExpressCard flash reader to house another flash card.&lt;br /&gt;
* Use a USB drive. Take mind that the drive will stick out, which is less desirable as a permanent solution (appearance/damage/speed especially if USB 2.0 is not supported)&lt;br /&gt;
* (If network access is readily available) Store the files on a network drive (e.g. server disk/NAS)&lt;br /&gt;
&lt;br /&gt;
==GNU/Linux issues==&lt;br /&gt;
With the Addonics adapters listed above (and possibly with other ones as well), the kernel's libata driver might warn about a 40-wire cable and default to UDMA/33 operation:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[ 27.831146] ata1.00: limited to UDMA/33 due to 40-wire cable&lt;br /&gt;
[ 27.846808] ata1.00: configured for UDMA/33&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This has been observed with version 2.6.24 of the kernel, and it may affect older ones, too.  A patch is available from [http://permalink.gmane.org/gmane.linux.ide/26879] that adds a &amp;lt;tt&amp;gt;force_cbl&amp;lt;/tt&amp;gt; kernel parameter.  After applying the patch and recompiling the kernel, you can then set &amp;lt;tt&amp;gt;force_cbl=80&amp;lt;/tt&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[    7.140864] ata1: forcing 80c&lt;br /&gt;
[    7.140886] ata1.00: CFA: LEXAR ATA FLASH CARD, 20071016, max UDMA/100&lt;br /&gt;
[    7.140890] ata1.00: 7831152 sectors, multi 0: LBA &lt;br /&gt;
[    7.140908] ata1.00: forcing 80c&lt;br /&gt;
[    7.141625] ata1.00: configured for UDMA/100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
With the patch enabled, the above system achieves 42MB/sec read performance according to &amp;lt;tt&amp;gt;hdparm&amp;lt;/tt&amp;gt;.  Without it, performance suffers: 23MB/sec.&lt;br /&gt;
&lt;br /&gt;
==GNU/Linux tuning==&lt;br /&gt;
* edit /etc/fstab and add the option noatime to disable writing of last access timestamps on each file or directory access for each ext3 filesystem&lt;br /&gt;
 LABEL=/ / ext3 defaults,noatime 1 1&lt;br /&gt;
* disable swap (remove swap volume from /etc/fstab), just make sure you have enough memory installed (as old memory is now cheap, should be easy to just max out the machine!)&lt;br /&gt;
* increase writeback time (add the following line to /etc/rc.local)&lt;br /&gt;
 echo 1500 &amp;gt; /proc/sys/vm/dirty_writeback_centisecs&lt;br /&gt;
* remove beagle (if installed) from your system, it indexes the filesystem, but causes disk activity and keeps your cpu busy&lt;br /&gt;
 rpm -e beagle beagle-gnome beagle-evolution&lt;br /&gt;
&lt;br /&gt;
== Windows tuning==&lt;br /&gt;
{{NOTE|Instead of throwing together all kind of tweaks here, it's probably better to keep the tweaks be CF boot-specific... And link to another page showing the more generic tweaks...}}&lt;br /&gt;
Due to the space constraints of CF, you will want to do some tuning of Windows. In addition there are some tunes that help performance, and can even help in the case where your not changing your HDD to CF.&lt;br /&gt;
* Do a minimal Windows XP install (not a recovery) with nLite, this allows you to remove components of Windows before they even get to the HDD, such as Movie Maker, Windows Messenger and Outlook Express that you might not need, while at the same time slipstreaming the latest ServicePack (SP3 for XP). Alternatively if you cannot reinstall, you can try the public domain xplite program, but for it to be useful you need to pay, and it does not work with SP3.&lt;br /&gt;
* Disable NTFS from updating the last access of a file or directory on each access. This causes NTFS to do a write for each file read operation and writes are always slower, and with flash storage might not be a good idea, for this you need to set NtfsDisableLastAccessUpdate in your registry.&lt;br /&gt;
* Disable Indexing of the drive (drive properties)&lt;br /&gt;
* Compress the drive (NTFS only), this saves space and might in some cases even be faster as it will require less disk access (drive properties)&lt;br /&gt;
* Disable swap (system properties), just make sure you have enough memory (just max out the machine, RAM is cheap these days)&lt;br /&gt;
* Disable windows system restore (system properties), if you feel you can live without it. It reserves a defined amount of space for this purpose&lt;br /&gt;
* Do not enable Hibernation, it requires a huge hibernation file and suspend should be good enough.&lt;br /&gt;
* Disable programs from starting on boot that you do not need (do you really need Java, Adobe, Apple iTunes, etc from starting on boot each time?) with a program such as MSCONFIG (-&amp;gt;Start -&amp;gt;Run -&amp;gt; msconfig)&lt;br /&gt;
* Disable Windows services that you do not need from starting on boot&lt;br /&gt;
* Only install the IBM/Lenovo applications you truly know you will need (in my case, only the Hotkey utility and the Wireless drivers package to be able to disable wireless with Fn-F5)&lt;br /&gt;
* Never do a full install of an application, do a custom install and prune the options to remove all the stuff you will never use&lt;br /&gt;
* Disable HW devices in device manager that you do not need (in my case, the Modem and Infrared)&lt;br /&gt;
* Only install drivers you actually need (video, ethernet, wireless and sound in my case), and remove the C:\DRIVERS directory after your done.&lt;br /&gt;
* Do not run defrag, it is pointless on CF type media and just causes unnecessary writes!&lt;br /&gt;
With this I was able to Install Windows XP (SP3) with Office 2003 (SP2), IE7, WMP 11, Symantec Client Security, Adobe acrobat reader, Firefox, Thunderbird, Pidgin and Palm Desktop in addition to the necessary drivers in under 4GB of an 8GB CF card on a ThinkPad X40.&lt;br /&gt;
&lt;br /&gt;
==useful links==&lt;br /&gt;
* [http://forum.thinkpads.com/viewtopic.php?t=41568 ThinkPads Forum discussion on the subject]&lt;br /&gt;
* [http://www.hjreggel.net/cardspeed/index.html Flash memory speed - check out the UDMA CF link]&lt;br /&gt;
* [http://www.nliteos.com/ nLite - Utility to create a minimal Windows install CD with fixes and drivers]&lt;br /&gt;
* [http://www.daniel-boehmer.de/thinkpad-cf using Compact Flash cards as SSD alternative]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Problems_with_SATA_and_Linux&amp;diff=62689</id>
		<title>Problems with SATA and Linux</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Problems_with_SATA_and_Linux&amp;diff=62689"/>
		<updated>2025-10-27T03:06:02Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: You're installing more than just Linux. Linux is only a kernel and therefore it is repetitive to write kernel and the point is in fact the version of Linux. Can't work out the template problem.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top;padding-right:20px;width:10px;white-space:nowrap;&amp;quot; | __TOC__&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
Some ThinkPad models use an [[Intel ICH6-M]] SATA/PATA controller for the system hard disk. This causes several complications for GNU/Linux installation. The following lists these problems and known workarounds. Note that the details are often version- and distribution-specific.&lt;br /&gt;
{{HINT|The information on this page is outdated. As long as you have a fairly recent distribution with kernel 2.6.19 or newer, none of the issues described here apply}}&lt;br /&gt;
===Models using a SATA disk interface===&lt;br /&gt;
Models using a SATA controller and a SATA system disk:&lt;br /&gt;
*ThinkPad {{R60}}, {{R60e}}, {{R61}}&lt;br /&gt;
*ThinkPad {{T60}}, {{T60p}}, {{T61}}&lt;br /&gt;
*ThinkPad {{X60}}, {{X60s}}, {{X60_Tablet}}, {{X61}}, {{X61s}}, {{X61_Tablet}}&lt;br /&gt;
*ThinkPad {{Z60t}}, {{Z60m}}&lt;br /&gt;
*ThinkPad {{Z61e}}, {{Z61t}}, {{Z61m}}, {{Z61p}}&lt;br /&gt;
Models using a SATA controller and a PATA (IDE) system disk with a SATA-to-PATA bridge:&lt;br /&gt;
*ThinkPad {{T43}}, {{T43p}}&lt;br /&gt;
*ThinkPad {{R52}}&lt;br /&gt;
*ThinkPad {{X41}}, {{X41T}}&lt;br /&gt;
&lt;br /&gt;
{{NOTE|Some of these problems (namely SMART support, power management and disk information) are solved in Linux 2.6.15 with the inclusion of libata pass-through. See the SATA driver [http://linux-ata.org/features.html features], [http://linux-ata.org/software-status.html software status] and [http://linux-ata.org/driver-status.html hardware status].}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Hang on resume from suspend to RAM==&lt;br /&gt;
&lt;br /&gt;
Linux versions prior to 2.6.16 (ata_piix) and 2.6.19 (ahci) do not support suspend and resume for SATA devices. As a result, the machine hangs upon the first disk access after resume. A kernel patch ([http://lkml.org/lkml/2005/5/2/46 LKML posting]) fixes this by adding SATA power management support.&lt;br /&gt;
&lt;br /&gt;
Kernel 2.6.16 and later fixes this problem for most systems. The Thinkpad T60 and X60s still need some patches to get resume working using 2.6.16, see [[Talk:Problems with SATA and Linux#Patch against SATA-resume problem with T60|here]]. The T60p resumes properly with 2.6.17-rc6, the T60 and X60 should also.  You need to enable ata_piix and disable AHCI in the bios. The latest fedora (FC5) 2.6.17 kernel seems to have fixed the resume problem on the T60p, still need to disable AHCI though. Applying [http://cvs.fedora.redhat.com/viewcvs/rpms/kernel/FC-5/linux-2.6-console-suspend.patch this FC5 patch] makes suspend-to-ram work with AHCI enabled.&lt;br /&gt;
&lt;br /&gt;
===Patches===&lt;br /&gt;
* [http://shamrock.dyndns.org/~ln/linux/sata_pm.2.6.12.diff Patch for kernel 2.6.12]&lt;br /&gt;
* [http://shamrock.dyndns.org/~ln/linux/sata_pm.2.6.13-rc5.diff Patch for kernel 2.6.13-rc5]&lt;br /&gt;
* [http://lkml.org/lkml/2005/9/23/97 Patch for kernel 2.6.14]&lt;br /&gt;
* [http://www.xenotime.net/linux/SATA/2.6.15-rc/libata_suspend.patch Patch for kernel 2.6.15-rc4]&lt;br /&gt;
* [http://tpctl.sourceforge.net/tmp/sata_pm.2.6.15-rc6.patch Patch for kernels 2.6.15-rc6 through 2.6.15]&lt;br /&gt;
&lt;br /&gt;
Some distributions already include this patch (e.g., {{Ubuntu}} Breezy, {{Gentoo}}'s gentoo-sources 2.6.15-r1), but some don't (e.g., {{Fedora}} 4). If your distribution doesn't include the patch, you will need to compile your own kernel with this patch included.&lt;br /&gt;
&lt;br /&gt;
===Links===&lt;br /&gt;
* RedHat Bugzilla [https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=169201 bug 169201: &amp;quot;SATA drives fail on laptop suspend&amp;quot;]&lt;br /&gt;
* [http://lkml.org/lkml/2005/11/15/385 Fix to libata.h recommended on LKML] in case you get &amp;quot;ata: abnormal state 0x80 on port 0x1F7&amp;quot;&lt;br /&gt;
* RedHat Bugzilla [https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=183138 bug 183138&amp;quot;: &amp;quot;SATA failure after pm-suspend/resume ata1: handling error/timeout&amp;quot;]&lt;br /&gt;
&lt;br /&gt;
==Failed resume from suspend to disk==&lt;br /&gt;
&lt;br /&gt;
Suspend to disk (using [[swsusp]] or [[Software Suspend 2]]) needs to load the memory image from the SATA disk. For this to work, you either need an initrd with all the necessary SATA modules, or the SATA drivers compiled into the kernel.&lt;br /&gt;
&lt;br /&gt;
==No DMA on DVD drive==&lt;br /&gt;
&lt;br /&gt;
Using the IDE driver, DMA support cannot be enabled on an Ultrabay optical drive:&lt;br /&gt;
&lt;br /&gt;
 # hdparm -d1 /dev/hdc&lt;br /&gt;
 &lt;br /&gt;
 /dev/hdc:&lt;br /&gt;
  setting using_dma to 1 (on)&lt;br /&gt;
  HDIO_SET_DMA failed: Operation not permitted&lt;br /&gt;
  using_dma    =  0 (off)&lt;br /&gt;
&lt;br /&gt;
As a result, the optical drive is slow, and in particular, too slow to play video DVDs.&lt;br /&gt;
&lt;br /&gt;
One workaround is to use the &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; driver (instead of the IDE driver) for the optical drive. This requires enabling the ATAPI support of the &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; driver (which as of 2.6.2x kernels, is working fine but wasn't stable in kernels before 2.6.18). You must also make sure that the IDE driver (&amp;lt;tt&amp;gt;ide-generic&amp;lt;/tt&amp;gt;) does not grab the devices before &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
* Grab a recent kernel (must be 2.6.18 or newer)&lt;br /&gt;
* Do one of the following:&lt;br /&gt;
** Enable the &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;libata&amp;lt;/tt&amp;gt; drivers as built-in,&lt;br /&gt;
** Enable &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;libata&amp;lt;/tt&amp;gt; as modules (this is often the default) and add &amp;quot;&amp;lt;tt&amp;gt;options libata atapi_enabled=1&amp;lt;/tt&amp;gt;&amp;quot; to your {{path|/etc/modprobe.conf}} (or the equivalent in your distribution). &lt;br /&gt;
* Do one of the following:&lt;br /&gt;
** Disable the IDE system.&lt;br /&gt;
** Build the IDE driver as built-in (this is often the default) and add the {{bootparm|hdc|noprobe}} kernel argument (e.g., in in {{path|/boot/grub/menu.lst}} or {{path|/etc/lilo.conf}}. Don't forget to run lilo after changes).&lt;br /&gt;
** Build the IDE driver as module and add &amp;quot;&amp;lt;tt&amp;gt;options ide hdc=noprobe&amp;lt;/tt&amp;gt;&amp;quot; to your {{path|/etc/modprobe.conf}} (or the equivalent in your distribution).&lt;br /&gt;
* If you chose to use modules above, regenerate your &amp;lt;tt&amp;gt;initrd&amp;lt;/tt&amp;gt; file.&lt;br /&gt;
&lt;br /&gt;
Note : If you are using a ''Debian Sid'' system, and want to use Debian precompiled kernels, then type the following command in a ''root'' shell (This creates a new &amp;lt;tt&amp;gt;initrd&amp;lt;/tt&amp;gt; with enabled ATAPI support of &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; and loads &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; before the IDE driver): &lt;br /&gt;
 '''# echo options libata atapi_enabled=1&amp;gt;/etc/modprobe.d/atapienable &amp;amp;&amp;amp; update-initramfs -u'''&lt;br /&gt;
(this is apparently not necessary with newer kernels)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;The following is likely obsolete with recent kernels&amp;lt;/b&amp;gt;&lt;br /&gt;
Note : If your work was successful, your CD-ROM drive will no longer be accessible through /dev/hdc, but /dev/scd0 or /dev/sr0.&lt;br /&gt;
&lt;br /&gt;
If this all doesn't work, use {{cmd|lspci -vn|}} to check whether one of the following chipsets is used in the Thinkpad:&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!PCI ID &lt;br /&gt;
!Name&lt;br /&gt;
|-&lt;br /&gt;
|8086:7111&lt;br /&gt;
|Intel 82371AB/EB/MB PIIX4 IDE&lt;br /&gt;
|-&lt;br /&gt;
|8086:24db&lt;br /&gt;
|Intel 82801EB/ER (ICH5/ICH5R) IDE Controller&lt;br /&gt;
|-&lt;br /&gt;
|8086:25a2&lt;br /&gt;
|Intel 6300ESB PATA Storage Controller&lt;br /&gt;
|}&lt;br /&gt;
If yes, enable support for these chipsets has to be enabled by setting&lt;br /&gt;
 #define ATA_ENABLE_PATA&lt;br /&gt;
in {{path|include/linux/libata.h}} (and report your ThinkPad model in the discussion page).&lt;br /&gt;
&lt;br /&gt;
There have been reports that DVD burning doesn't work under this configuration, but it seems to work with kernel 2.6.14 and later (tested on a ThinkPad {{T43}} and {{T43p}} with a [[UltraBay Slim DVD Multi-Burner Plus]]).&lt;br /&gt;
&lt;br /&gt;
===Problem with kernel 2.6.16 kernel and suspend2 2.2.1===&lt;br /&gt;
DVD access fails with kernel 2.6.16.* and [[Software Suspend 2|suspend2]] 2.2.1. Thia is fixed by later versions of suspend2, or by deleting the 4000-libata-rollup-2616-rc3.patch (see &lt;br /&gt;
[http://lists.suspend2.net/lurker/message/20060322.082452.873dc526.en.html this post notice] by Alexander E. Patrakov).&lt;br /&gt;
&lt;br /&gt;
===Links===&lt;br /&gt;
* RedHat Bugzilla [https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=163418 bug 163418: &amp;quot;can't enable DMA on DVD drive&amp;quot;]&lt;br /&gt;
* Enabling DMA on a SATA DVD drive, kernel 2.6.18 [http://thomer.com/howtos/dma_on_sata_dvd.html]&lt;br /&gt;
&lt;br /&gt;
==No DMA on system hard disk==&lt;br /&gt;
&lt;br /&gt;
In recent Linux versions, there are two modules capable of handling the ICH6 disk controller:&lt;br /&gt;
* &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt;: the disk shows as {{path|/dev/sda}} and DMA is enabled.&lt;br /&gt;
* Generic IDE driver (&amp;lt;tt&amp;gt;ide-disk&amp;lt;/tt&amp;gt;): the disk shows as {{path|/dev/hda}} and DMA is disabled.&lt;br /&gt;
&lt;br /&gt;
The simplest way to enable DMA is to force the IDE driver to ignore the system hard disk by passing the {{bootparm|hda|noprobe}} and {{bootparm|hda|none}} kernel argument. The driver will then be handled by the &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; driver. Note that this will change its device name to {{path|/dev/sda}} (which may require changes in {{path|/etc/fstab}} and the boot loader) and may cause other problems as listed above.&lt;br /&gt;
&lt;br /&gt;
(Observed on a ThinkPad T43 with Fedora Core kernel 2.6.13-1.1526_FC4.)&lt;br /&gt;
(Observed on a ThinkPad X40 with Debian kernel 2.6.18-4-686.) [[User:Hendry|Hendry]] 20:05, 11 June 2007 (UTC)&lt;br /&gt;
&lt;br /&gt;
It may be necessary to set CONFIG_IDE to n and not pass the parameters mentioned above.&lt;br /&gt;
&lt;br /&gt;
(Observed on a ThinkPad T60 with gentoo kernel 2.6.26)&lt;br /&gt;
&lt;br /&gt;
==No SMART support==&lt;br /&gt;
&lt;br /&gt;
Prior to kernel 2.6.15, the Linux SATA system did not support SMART commands (e.g., via smartctl).&lt;br /&gt;
&lt;br /&gt;
The necessary capability is &amp;quot;libata pass-through&amp;quot;, which was incorporated into Linux 2.6.15-rc1 and later. A patch is available for older kernels:&lt;br /&gt;
* Kernel 2.6.12: http://rtr.ca/dell_i9300/kernel/kernel-2.6.12/03_libata_passthru.patch&lt;br /&gt;
* Kernel 2.6.13: http://rtr.ca/dell_i9300/kernel/kernel-2.6.13/02_libata_passthru.patch&lt;br /&gt;
* Kernel 2.6.14: http://www.foo.fh-furtwangen.de/~koenigr/02_libata_passthru.fixed.again.patch&lt;br /&gt;
* Kernel 2.6.14 with the above suspend-to-RAM patch: http://linux.spiney.org/system/files?file=02_libata_passthru.fixed.patch&lt;br /&gt;
&lt;br /&gt;
After applying the patch, run smartctl with the &amp;quot;-d ata&amp;quot; parameter:&lt;br /&gt;
:{{cmdroot|smartctl -d ata -a /dev/sda}}&lt;br /&gt;
&lt;br /&gt;
From smartmontools version 5.37 &amp;quot;-d sat&amp;quot; is preferred to &amp;quot;-d ata&amp;quot;. The smartctl command will auto-detect SATA disks so:&lt;br /&gt;
:{{cmdroot|smartctl -a /dev/sda}}&lt;br /&gt;
should just work. The smartd daemon still requires &amp;quot;-d sat&amp;quot; in /etc/smartd.conf .&lt;br /&gt;
&lt;br /&gt;
==No disk power management==&lt;br /&gt;
&lt;br /&gt;
Prior to kernel 2.6.15, the Linux SATA system did not support power management commands on these models.&lt;br /&gt;
&lt;br /&gt;
The above patches for SMART support resolves this, and in particular enables the following commands:&lt;br /&gt;
* {{cmdroot|hdparm -y}} (spin down)&lt;br /&gt;
* {{cmdroot|hdparm -S num}} (automatic spin down timeout)&lt;br /&gt;
* {{cmdroot|hdparm -B num}} (advanced power management level)&lt;br /&gt;
Note that this command is still rejected:&lt;br /&gt;
* {{cmdroot|hdparm -M num}} (acoustic management)&lt;br /&gt;
(Tested with patched kernels 2.6.13.1 and 2.6.12-4 and a 60GB 7200RPM disk model HTS726060M9AT00.)&lt;br /&gt;
&lt;br /&gt;
Refer to [[How to make use of Harddisk Power Management features]] for details about using&lt;br /&gt;
HD power management.  Refer to [[Laptop-mode]] if you are interested into spinning down your HD.&lt;br /&gt;
&lt;br /&gt;
==No disk information==&lt;br /&gt;
&lt;br /&gt;
Prior to kernel 2.6.15, on these models the disk information could not be read by the standard commands such as:&lt;br /&gt;
*{{cmdroot|hdparm -i /dev/sda}}&lt;br /&gt;
*{{cmdroot|hdparm -I /dev/sda}}&lt;br /&gt;
The latter is fixed by the above patch for SMART support.&lt;br /&gt;
&lt;br /&gt;
==No swapping of UltraBay device==&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; driver in mainline Linux supports hot-swapping and warm-swapping of PATA and SATA devices. This requires kernel 2.6.18 or newer (with older kernels, you must power off the laptop before swapping such devices). See [[How to hotswap Ultrabay devices#When_using_the_ata_piix_driver|How to hotswap Ultrabay devices]] for further information.&lt;br /&gt;
&lt;br /&gt;
Swapping of the [[Ultrabay Slim Battery]] works out-of-the box.&lt;br /&gt;
&lt;br /&gt;
==BIOS error 2010 on user-installed hard disk==&lt;br /&gt;
&lt;br /&gt;
There is an issue with installing alternative PATA (IDE) hard disks as the system drive (this has nothing to do with Linux). Unless the disk is one of the few approved disks listed inside the BIOS, you will get an BIOS error 2010 during system boot, and the disk may operate unreliably. See [[Problem with non-ThinkPad hard disks]].&lt;br /&gt;
&lt;br /&gt;
==CompactFlash module doesn't work==&lt;br /&gt;
&lt;br /&gt;
Normally, PATA disks can be replaced with a solid-state [[CompactFlash]] module using a cheap PATA-to-CompactFlash adapter. However, there is a [http://thread.gmane.org/gmane.linux.ide/22400 report] that replacing the system disk with CompactFlash fails on a ThinkPad {{X41}}, possibly due to the SATA-to-PATA bridge. If so, the problem would probably occur also on the {{X41T}}, {{T43}}, {{T43p}} and {{R52}}.&lt;br /&gt;
I (KotCzarny) can confirm that {{X41T}} has this issue. READ is OK, but every attempt to do a WRITE results in timeouts as listed in gmane report. A quick and dirty workaround is to use generic ide driver (not sata one) to disable DMA. You won't get high speeds but at least it will work.&lt;br /&gt;
&lt;br /&gt;
'''Update''' please check [[Compact Flash boot drive]] for more current information on using Compact Flash to boot&lt;br /&gt;
&lt;br /&gt;
==RHEL3.0 Update 7 on T60p==&lt;br /&gt;
&lt;br /&gt;
RHEL3.0 Update 7 will install on a {{T60p}}, but you need to make an adjustment.  Both uni-processor and SMP kernels get installed, with the SMP kerrnel the default.  However, the SMP kernel can't seem to find the disk drive.  You can work around this by use &amp;quot;e&amp;quot; at the GRUB kernel prompt, then on the &amp;quot;kernel&amp;quot; line appending &amp;quot; noapic&amp;quot;.  After the system boots, you'll want to edit /boot/grub/grub.conf to add the &amp;quot; noapic&amp;quot; option to the kernel line as well.&lt;br /&gt;
&lt;br /&gt;
==Mandriva 2006 on T60==&lt;br /&gt;
&lt;br /&gt;
Mandriva 2006.0 has a problem with SATA on a {{T60}}, to fix this you need to make an adjustment. The install procedure can't seem to find the SATA disk drive, you can work around this by adding the &amp;quot;noapic&amp;quot; kernel option during CD/DVD boot. You *might* need to add this to lilo or GRUB for normal operations, after install completes. The problem with not using apic during normal operations is that you might have problems with power management, please see article on [[Software Suspend 2]]&lt;br /&gt;
&lt;br /&gt;
==Problem burning CD/DVD==&lt;br /&gt;
&lt;br /&gt;
To a CD/DVD problem, try to burn a CD/DVD as &amp;quot;root&amp;quot;-user on command-line with the option &amp;quot;-dummy&amp;quot; and &amp;quot;-v&amp;quot; enabled, do not use K3B or similar. Doing so you will get more informations and waste less CD/DVD's. &lt;br /&gt;
&lt;br /&gt;
Experiment with the parameters &amp;quot;burnfree&amp;quot; and &amp;quot;dev&amp;quot;. With cdrecord on debian etch, burnfree seems not work, disable it. With wodim on debian etch: try parameter &amp;quot;dev=/dev/scd0&amp;quot;, the default &amp;quot;dev=1,0,0&amp;quot; seems not to work.&lt;br /&gt;
&lt;br /&gt;
==Spurious NCQ completions==&lt;br /&gt;
&lt;br /&gt;
It was initially thought the HDD controller software support for NCQ was buggy ([http://lkml.org/lkml/2007/6/6/15 LKML posting] and [http://lkml.org/lkml/2007/6/6/195 LKML posting]).&lt;br /&gt;
It was later found that it was a driver misinterpretation and there is no hardware problem ([http://article.gmane.org/gmane.linux.ide/26012 newsgroup posting]).&lt;br /&gt;
&lt;br /&gt;
If you have an old kernel and get some warnings about spurious NCQ completions, you can safely ignore them. You are advised, anyway, to upgrade to a recent kernel.&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=How_to_hotswap_Ultrabay_devices&amp;diff=62688</id>
		<title>How to hotswap Ultrabay devices</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=How_to_hotswap_Ultrabay_devices&amp;diff=62688"/>
		<updated>2025-10-27T02:53:54Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: R400 etc is not the latest generation anymore. The userland software is not merely tools. Spelling and grammar. Hdparm sets the password, not Linux.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following discusses hotswap (AKA &amp;quot;hotplug&amp;quot;) of devices in the [[Ultrabay]].&lt;br /&gt;
&lt;br /&gt;
This page has a lot of old information.  Some cleanup might be useful.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Which driver?==&lt;br /&gt;
This may be confusing, so first a quick history lesson.&lt;br /&gt;
&lt;br /&gt;
Older ThinkPads (up to the R51, T42p and X40) were fully IDE (PATA) for both the internal HDD and Ultrabay. For these there are two drivers, the modern libata based {{path|ata_piix}} and the old legacy {{path|piix}}/{{path|ide-disk}} combo. Most modern distributions will default to the {{path|ata_piix}} driver, which is really what you want anyway.&lt;br /&gt;
&lt;br /&gt;
ThinkPads like the R52, T43, T43p, X41 and X41 Tablet are strange hybrids. They have a Serial-ATA (SATA) chipset for the internal disk controller, but the actual disk is still legacy IDE, using a separate SATA-PATA bridge chip. The Ultrabay, though, is still connected to the legacy IDE host controller. This results in a setup where the internal disk is handled by a SATA driver and the Ultrabay is handled by either {{path|ata_piix}} or {{path|piix}}/{{path|ide-disk}}.&lt;br /&gt;
&lt;br /&gt;
ThinkPads like the R60, T60 and Z60 series are also hybrids, but they use a native SATA HDD internal. Ultrabay still uses legacy IDE (PATA) though. So just like with the previous models you end up with two separate drivers for the internal HDD and the Ultrabay.&lt;br /&gt;
&lt;br /&gt;
Newer generation ThinkPads like the R400, R500, T400, T500, W500, W700, X200, and X301 are all fully SATA for both the internal HDD and the Ultrabay device, so both are handled by the same SATA driver.&lt;br /&gt;
{{Todo|Figure out in which category the X60 series ThinkPads truly belong. Some of these machines might have been shipped with a 1.8&amp;quot; HDD which is likely to be PATA, in fact the HMM even states so. But tabook and ltwbook only lists SATA models, so the 1.8&amp;quot; model might never have shipped. But even if it did there will be a SATA-PATA bridge chip, so from the OS it will look like SATA.}}&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+Overview of disk interface types&lt;br /&gt;
! Thinkpad !! internal HDD !! Ultrabay !! Modern Driver !! Old Driver&lt;br /&gt;
|-&lt;br /&gt;
| {{A20m}}, {{A20p}}, {{A21e}}, {{A21m}}, {{A21p}}, {{A22e}}, {{A22m}}, {{A22p}}, {{A30}}, {{A30p}}, {{A31}}, {{A31p}} || Legacy 2.5&amp;quot; IDE (PATA) || Legacy IDE (PATA) || ata_piix || piix + ide-disk&lt;br /&gt;
|-&lt;br /&gt;
| {{R30}}, {{R31}}, {{R32}}, {{R40}}, {{R50}}, {{R50e}}, {{R50p}}, {{R51}} || Legacy 2.5&amp;quot; IDE (PATA) || Legacy IDE (PATA) || ata_piix || piix + ide-disk&lt;br /&gt;
|-&lt;br /&gt;
| {{R52}} || Legacy 2.5&amp;quot; PATA HDD with conversion to SATA || Legacy IDE (PATA) || ahci + ata_piix || -&lt;br /&gt;
|-&lt;br /&gt;
| {{R60}}, {{R61}} || 2.5&amp;quot; SATA || Legacy IDE (PATA)  || ahci + ata_piix || -&lt;br /&gt;
|-&lt;br /&gt;
| {{R400}}, {{R500}} ||2.5&amp;quot; SATA || SATA || ahci || -&lt;br /&gt;
|-&lt;br /&gt;
| {{T20}}, {{T21}}, {{T22}}, {{T23}}, {{T30}}, {{T40}}, {{T40p}}, {{T41}}, {{T41p}}, {{T42}}, {{T42p}} || Legacy 2.5&amp;quot; IDE (PATA) || Legacy IDE (PATA) || ata_piix || piix + ide-disk&lt;br /&gt;
|-&lt;br /&gt;
| {{T43}}, {{T43p}} || Legacy 2.5&amp;quot; PATA HDD with conversion to SATA || Legacy IDE (PATA) || ahci + ata_piix || -&lt;br /&gt;
|-&lt;br /&gt;
| {{T60}}, {{T60p}}, {{T61}}, {{T61p}} || 2.5&amp;quot; SATA || Legacy IDE (PATA)  || ahci + ata_piix || -&lt;br /&gt;
|-&lt;br /&gt;
| {{T400}}, {{T500}} ||2.5&amp;quot; SATA || SATA || ahci || -&lt;br /&gt;
|-&lt;br /&gt;
| {{X20}}, {{X21}}, {{X22}}, {{X23}}, {{X24}}, {{X30}}, {{X31}}, {{X32}} || Legacy 2.5&amp;quot; IDE (PATA) || Legacy IDE (PATA) || ata_piix || piix + ide-disk&lt;br /&gt;
|-&lt;br /&gt;
| {{X40}} || Legacy 1.8&amp;quot; IDE (PATA) || Legacy IDE (PATA) || ata_piix || piix + ide-disk&lt;br /&gt;
|-&lt;br /&gt;
| {{X41}}, {{X41t}} || Legacy 1.8&amp;quot; PATA HDD with conversion to SATA || Legacy IDE (PATA) || ahci + ata_piix || -&lt;br /&gt;
|-&lt;br /&gt;
| {{X60}}, {{X60s}}, {{x60t}}, {{x61}}, {{x61s}}, {{x61t}} || 2.5&amp;quot; HDD is SATA, 1.8&amp;quot; HDD is PATA with SATA conversion || Legacy IDE (PATA) || ahci + ata_piix || -&lt;br /&gt;
|-&lt;br /&gt;
| {{X300}} ||2.5&amp;quot; SATA || Legacy IDE (PATA) || ahci + ata_piix || -&lt;br /&gt;
|-&lt;br /&gt;
| {{X200}}, {{X200 Tablet}}, {{X301}} ||2.5&amp;quot; SATA || SATA || ahci || -&lt;br /&gt;
|-&lt;br /&gt;
| {{W500}}, {{W700}} ||2.5&amp;quot; SATA || SATA || ahci || -&lt;br /&gt;
|-&lt;br /&gt;
| {{Z60m}}, {{Z60t}}, {{Z61e}}, {{Z61m}}, {{Z61p}}, {{Z61t}} || 2.5&amp;quot; SATA || Legacy IDE (PATA) || ahci + ata_piix || -&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{NOTE|Debian users: at least up the the kernel released with Lenny, Debian applies a patch in the Debian kernel sources which prevents the use of &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; with PATA devices (like the IDE bus for the Ultrabay). You will have to either use an upstream kernel or (re)patch the Debian kernel sources. &lt;br /&gt;
You may want to have a look at the following Debian bug reports as well: [http://bugs.debian.org/444182 #444182], [http://bugs.debian.org/463833 #463833].}}&lt;br /&gt;
&lt;br /&gt;
==Modern systems (using the &amp;lt;tt&amp;gt;ahci&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; drivers)==&lt;br /&gt;
The following applies when using the &amp;lt;tt&amp;gt;ahci&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; driver (which supercedes the old &amp;lt;tt&amp;gt;ide_disk&amp;lt;/tt&amp;gt; driver).&lt;br /&gt;
&lt;br /&gt;
You should at least be using a distribution with kernel 2.6.23. If you have a distribution with an older kernel, please update your distribution, as in addition to a newer kernel, you will need some of the newer userland software.&lt;br /&gt;
&lt;br /&gt;
===Using libata-acpi and udev===&lt;br /&gt;
&lt;br /&gt;
Starting from kernel 2.6.26-rc5, it's possible to use &amp;lt;tt&amp;gt;libata-acpi&amp;lt;/tt&amp;gt; in combination with udev to hotswap. Please check if CONFIG_ATA_ACPI is enabled in your kernel configuration.&lt;br /&gt;
&lt;br /&gt;
For 2.6.25, you need two patches which can be easily backported ([http://article.gmane.org/gmane.linux.acpi.devel/31159],[http://article.gmane.org/gmane.linux.acpi.devel/31369]).&lt;br /&gt;
&lt;br /&gt;
Create a file {{path|/etc/udev/rules.d/50-thinkpad-ultrabay.rules}} with the following contents:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ENV{BAY_EVENT}==&amp;quot;3&amp;quot;, ACTION==&amp;quot;change&amp;quot;, SUBSYSTEM==&amp;quot;scsi&amp;quot;, RUN+=&amp;quot;/usr/local/sbin/ultrabay_eject&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Then ensure it has the right permissions&lt;br /&gt;
 chown root:root /etc/udev/rules.d/50-thinkpad-ultrabay.rules&lt;br /&gt;
 chmod 644 /etc/udev/rules.d/50-thinkpad-ultrabay.rules&lt;br /&gt;
For Red Hat/Fedora and other systems with selinux, you also need to set the security context:&lt;br /&gt;
 chcon system_u:object_r:etc_runtime_t:s0 /etc/udev/rules.d/50-thinkpad-ultrabay.rules&lt;br /&gt;
&lt;br /&gt;
Now create the below ultrabay-eject script&lt;br /&gt;
&lt;br /&gt;
===Script for Ultrabay eject===&lt;br /&gt;
&lt;br /&gt;
The following script does the following:&lt;br /&gt;
* Automatically unmounts the relevant filesystems and power off the Ultrabay when the Ultrabay eject lever is released. Screams if some filesystem can't be unmounted.&lt;br /&gt;
&lt;br /&gt;
Create a executable file {{path|/usr/local/sbin/ultrabay_eject}} with the following content. Note if you want to be able to run it directly (not by the UDEV eject script), then you need to manually edit the DEVPATH variable near the top of the script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
# Change the following DEVPATH= to match your system, if you want to run this directly instead of having it called by the udev eject script&lt;br /&gt;
# To find the right value, insert the UltraBay optical drive and run:&lt;br /&gt;
# udevadm info --query=path --name=/dev/sr0 | perl -pe 's!/block/...$!!'&lt;br /&gt;
&lt;br /&gt;
# Try to guess DEVPATH. It works with optical drive or Hard disk (or SSD)&lt;br /&gt;
if [ &amp;quot;$DEVPATH&amp;quot; = &amp;quot;&amp;quot; ]; then&lt;br /&gt;
        # try to guess for CD&lt;br /&gt;
        DEVPATH=$(udevadm info --query=path --name=/dev/sr0 | perl -pe 's!/block/...$!!')&lt;br /&gt;
        if [ &amp;quot;$DEVPATH&amp;quot; = &amp;quot;&amp;quot; ]; then&lt;br /&gt;
                echo &amp;quot;No optical device attached?&amp;quot;&lt;br /&gt;
                echo &amp;quot;Try for harddisk&amp;quot;&lt;br /&gt;
                # try to guess for sdb&lt;br /&gt;
                DEVPATH=$(udevadm info --query=path --name=/dev/sdb | perl -pe 's!/block/...$!!')&lt;br /&gt;
        fi&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
shopt -s nullglob&lt;br /&gt;
export DISPLAY=:0.0 # required for notify-send&lt;br /&gt;
ULTRABAY_SYSDIR=/sys$DEVPATH&lt;br /&gt;
&lt;br /&gt;
# Find generic dock interface for UltraBay&lt;br /&gt;
dock=$( /bin/grep -l ata_bay /sys/devices/platform/dock.?/type )&lt;br /&gt;
dock=${dock%%/type}&lt;br /&gt;
if [ -n &amp;quot;$dock&amp;quot; -a -d &amp;quot;$dock&amp;quot; ]; then&lt;br /&gt;
        logger ultrabay_eject starting eject of $dock&lt;br /&gt;
else&lt;br /&gt;
        logger ultrabay_eject cannot locate bay dock device&lt;br /&gt;
        notify-send -u critical -t 100000 &amp;quot;ThinkPad Ultrabay eject failed&amp;quot; &amp;quot;Cannot locate bay dock device&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# Umount the filesystem(s) backed by the given major:minor device(s)&lt;br /&gt;
unmount_rdev() { perl - &amp;quot;$@&amp;quot; &amp;lt;&amp;lt;'EOPERL'  # let's do it in Perl&lt;br /&gt;
        for $major_minor (@ARGV) {&lt;br /&gt;
                $major_minor =~ m/^(\d+):(\d+)$/ or die;&lt;br /&gt;
                push(@tgt_rdevs, ($1&amp;lt;&amp;lt;8)|$2);&lt;br /&gt;
        }&lt;br /&gt;
        # Sort by reverse length of mount point, to unmount sub-directories first&lt;br /&gt;
        open MOUNTS,&amp;quot;&amp;lt;/proc/mounts&amp;quot; or die &amp;quot;$!&amp;quot;;&lt;br /&gt;
        @mounts=sort { length($b-&amp;gt;[1]) &amp;lt;=&amp;gt; length($a-&amp;gt;[1]) } map { [ split ] } &amp;lt;MOUNTS&amp;gt;;&lt;br /&gt;
        close MOUNTS;&lt;br /&gt;
        foreach $m (@mounts) {&lt;br /&gt;
                ($dev,$dir)=@$m;&lt;br /&gt;
                next unless -b $dev;  $rdev=(stat($dev))[6];&lt;br /&gt;
                next unless grep($_==$rdev, @tgt_rdevs);&lt;br /&gt;
                system(&amp;quot;umount&amp;quot;,&amp;quot;-v&amp;quot;,&amp;quot;$dir&amp;quot;)==0  or  $bad=1;&lt;br /&gt;
                if ($bad == 1) {&lt;br /&gt;
                        system(&amp;quot;logger&amp;quot;,&amp;quot;ultrabay_eject&amp;quot;,&amp;quot;ERROR unmounting&amp;quot;,$dev,$dir);&lt;br /&gt;
                        system(&amp;quot;notify-send -u critical -t 100000 \&amp;quot;Error unmounting $dir\&amp;quot; \&amp;quot;Unmounting of $dir on $dev failed!\&amp;quot;&amp;quot;);&lt;br /&gt;
                } else {&lt;br /&gt;
                        system(&amp;quot;logger&amp;quot;,&amp;quot;ultrabay_eject&amp;quot;,&amp;quot;unmounted&amp;quot;,$dev,$dir);&lt;br /&gt;
                        system(&amp;quot;notify-send -u normal -t 5000 \&amp;quot;Unmounted $dir\&amp;quot;&amp;quot;);&lt;br /&gt;
                };&lt;br /&gt;
        }&lt;br /&gt;
        exit 1 if $bad;&lt;br /&gt;
EOPERL&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
if [ -d $ULTRABAY_SYSDIR ]; then&lt;br /&gt;
	logger ultrabay_eject dock occupied, shutting down storage device $DEVPATH&lt;br /&gt;
	sync&lt;br /&gt;
	# Unmount filesystems backed by this device&lt;br /&gt;
	## This seems to be very inelegant and prone to failure&lt;br /&gt;
	unmount_rdev `cat $ULTRABAY_SYSDIR/block/*/dev     \&lt;br /&gt;
			  $ULTRABAY_SYSDIR/block/*/*/dev`  \&lt;br /&gt;
	|| {&lt;br /&gt;
		logger ultrabay_eject umounting failed&lt;br /&gt;
		echo 2 &amp;gt; /proc/acpi/ibm/beep  # triple error tone&lt;br /&gt;
		notify-send -u critical -t 100000 &amp;quot;ThinkPad Ultrabay eject failed&amp;quot; &amp;quot;Please do not pull the device, doing so could cause file corruption and possibly hang the system. Unmounting of the filesystem on the ThinkPad Ultrabay device failed. Please put the eject leaver back in place, and try to unmount the filesystem manually. If this succeeds you can try the eject again&amp;quot;&lt;br /&gt;
		exit 1;&lt;br /&gt;
	}&lt;br /&gt;
	sync&lt;br /&gt;
	# Let HAL+KDE notice the unmount&lt;br /&gt;
	sleep 0.5&lt;br /&gt;
	# Unregister this SCSI device:&lt;br /&gt;
	sync&lt;br /&gt;
	echo 1 &amp;gt; $ULTRABAY_SYSDIR/delete&lt;br /&gt;
elif [ $( cat $dock/docked ) == 0 ]; then&lt;br /&gt;
        logger ultrabay_eject dock reports empty&lt;br /&gt;
else&lt;br /&gt;
	logger ultrabay_eject bay occupied but incorrect device path $DEVPATH&lt;br /&gt;
	notify-send -u critical -t 100000 &amp;quot;ThinkPad Ultrabay eject failed&amp;quot; &amp;quot;Bay occupied but incorrect device path&amp;quot;&lt;br /&gt;
	echo 2 &amp;gt; /proc/acpi/ibm/beep  # triple error tone&lt;br /&gt;
	exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# We need sleep here so someone can disconnect the bay and the drive&lt;br /&gt;
sleep 1&lt;br /&gt;
&lt;br /&gt;
# Turn off power to the UltraBay&lt;br /&gt;
logger ultrabay_eject undocking $dock&lt;br /&gt;
echo 1 &amp;gt; $dock/undock&lt;br /&gt;
&lt;br /&gt;
# Tell the user we're OK&lt;br /&gt;
logger ultrabay_eject done&lt;br /&gt;
echo 12 &amp;gt; /proc/acpi/ibm/beep&lt;br /&gt;
notify-send -u normal -t 10000 &amp;quot;Safe to remove device&amp;quot; &amp;quot;The ThinkPad Ultrabay device can now safely be removed&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
a possible fix for the notify not working thing is here [[Talk:How_to_hotswap_Ultrabay_devices#get_notify-send_working]]&lt;br /&gt;
&lt;br /&gt;
Then make sure ownership and permissions are set correct&lt;br /&gt;
 chown root:root /usr/local/sbin/ultrabay_eject&lt;br /&gt;
 chmod 555 /usr/local/sbin/ultrabay_eject&lt;br /&gt;
&lt;br /&gt;
If the &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; driver is built in the kernel, it will catch bay events and you will see the&lt;br /&gt;
following message in your system log:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
thinkpad_acpi: another device driver is already handling bay events&lt;br /&gt;
thinkpad_acpi: disabling subdriver bay&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
You should load &amp;lt;tt&amp;gt;thinkpad_acpi&amp;lt;/tt&amp;gt; before &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; if you want it to handle bay events.&lt;br /&gt;
&lt;br /&gt;
===Script for Ultrabay insert===&lt;br /&gt;
{{WARN|Only needed for kernels prior to 2.6.26}}&lt;br /&gt;
Create {{path|/usr/local/sbin/ultrabay_insert}} with the following content:&lt;br /&gt;
 #!/bin/bash&lt;br /&gt;
 echo 12 &amp;gt; /proc/acpi/ibm/beep&lt;br /&gt;
 sync&lt;br /&gt;
 echo 0 0 0 &amp;gt; /sys/class/scsi_host/host1/scan&lt;br /&gt;
&lt;br /&gt;
and set the right permissions&lt;br /&gt;
 chown root:root /usr/local/sbin/ultrabay_insert&lt;br /&gt;
 chmod 555 /usr/local/sbin/ultrabay_insert&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Using the generic bay driver and udev===&lt;br /&gt;
{{WARN|If you have kernel 2.6.26 or newer, please use the above [[#Using libata-acpi and udev]] method instead}}&lt;br /&gt;
Starting from kernel 2.6.23-rc3, it's possible to use the generic &amp;lt;tt&amp;gt;bay&amp;lt;/tt&amp;gt; driver in combination with udev to hotswap. Please check if CONFIG_ACPI_BAY is enabled (module or built-in) in your kernel configuration.&lt;br /&gt;
&lt;br /&gt;
Create {{path|/etc/udev/rules.d/ibm-ultrabay.rules}}:&lt;br /&gt;
 ENV{BAY_EVENT}==&amp;quot;3&amp;quot;, KERNEL==&amp;quot;bay.0&amp;quot;, ACTION==&amp;quot;change&amp;quot;, SUBSYSTEM==&amp;quot;platform&amp;quot;, RUN+=&amp;quot;/usr/local/sbin/ultrabay_eject&amp;quot;&lt;br /&gt;
 ENV{BAY_EVENT}==&amp;quot;1&amp;quot;, KERNEL==&amp;quot;bay.0&amp;quot;, ACTION==&amp;quot;change&amp;quot;, SUBSYSTEM==&amp;quot;platform&amp;quot;, RUN+=&amp;quot;/usr/local/sbin/ultrabay_insert&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Starting with kernel 2.6.28, the &amp;lt;tt&amp;gt;bay&amp;lt;/tt&amp;gt; driver was removed from the mainline kernel. The &amp;lt;tt&amp;gt;dock&amp;lt;/tt&amp;gt; driver replaced it completely. Make sure CONFIG_ACPI_DOCK is enabled in the kernel, and use the following udev rules:&lt;br /&gt;
&lt;br /&gt;
 ENV{EVENT}==&amp;quot;undock&amp;quot;, KERNEL==&amp;quot;dock.2&amp;quot;, ACTION==&amp;quot;change&amp;quot;, SUBSYSTEM==&amp;quot;platform&amp;quot;, RUN+=&amp;quot;/usr/local/sbin/ultrabay_eject&amp;quot;&lt;br /&gt;
 ENV{EVENT}==&amp;quot;dock&amp;quot;, KERNEL==&amp;quot;dock.2&amp;quot;, ACTION==&amp;quot;change&amp;quot;, SUBSYSTEM==&amp;quot;platform&amp;quot;, RUN+=&amp;quot;/usr/local/sbin/ultrabay_insert&amp;quot;&lt;br /&gt;
&lt;br /&gt;
However, the ultra_eject script needs to be changed, otherwise udev goes into an infinite event loop. It will send undock events every few seconds forever. That means as soon as the ultrabay is plugged in again, it will be immediately ejected. For kernels 2.6.28 and higher, the bay cannot be powered off using this method, so change the end of the script to read:&lt;br /&gt;
 # Turn off power to the UltraBay:&lt;br /&gt;
 if [ -d /sys/devices/platform/bay.0 ]; then&lt;br /&gt;
 	echo 1 &amp;gt; /sys/devices/platform/bay.0/eject&lt;br /&gt;
 elif [ -e /proc/acpi/ibm/bay ]; then&lt;br /&gt;
 	echo eject &amp;gt; /proc/acpi/ibm/bay&lt;br /&gt;
 fi&lt;br /&gt;
 # Tell the user we're OK&lt;br /&gt;
 echo 12 &amp;gt; /proc/acpi/ibm/beep&lt;br /&gt;
&lt;br /&gt;
Alternatively, instead of modifying the script, use the libata-acpi method below.&lt;br /&gt;
This was tested on a T61p running Gentoo with tuxonice 2.6.28-r8 without any issues.&lt;br /&gt;
&lt;br /&gt;
===udisks support===&lt;br /&gt;
Just like the HAL support mentioned below this is only about marking the device as hotpluggable.&lt;br /&gt;
&lt;br /&gt;
Recently distributions do not use HAL anymore. On these systems Gnome, KDE, etc. use udisks instead to discover installed disks. So today most people will have to tell udisks that the ultrabay device is a removeable device. The HAL configuration described below does not work anymore.&lt;br /&gt;
&lt;br /&gt;
Udisks reads device properties from udev. In order to force a device to be considered &amp;quot;removeable&amp;quot; we have to set the udev property &amp;quot;UDISKS_SYSTEM_INTERNAL&amp;quot; to &amp;quot;0&amp;quot;. (man 7 udisks)&lt;br /&gt;
In order for this to work you need at least version 1.0.3 of udisks.&lt;br /&gt;
&lt;br /&gt;
Here is an example of a udev rule that adds the property. You can add it to the file that contains the other utrabay rules (i.e. {{path|/etc/udev/rules.d/50-thinkpad-ultrabay.rules}}). You may have to adjust the DEVPATH.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SUBSYSTEMS==&amp;quot;block&amp;quot;, DEVPATH==&amp;quot;/devices/pci0000:00/0000:00:1f.1/host4/*&amp;quot;, ENV{UDISKS_SYSTEM_INTERNAL}=&amp;quot;0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now tell udev to reread the rules:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
udevadm control --reload-rules&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now your window manager should give you a notification when you plug in a disk into the ultrabay.&lt;br /&gt;
&lt;br /&gt;
===HAL support===&lt;br /&gt;
{{HELP| If the script below does not work, please provide your lshal output on the [[Talk:How_to_hotswap_Ultrabay_devices]] page}}&lt;br /&gt;
{{NOTE| If your HAL version is older then 0.5.11, you need to replace &amp;quot;info.parent&amp;quot; with &amp;quot;storage.physical_device&amp;quot;.}}&lt;br /&gt;
&lt;br /&gt;
HAL support is only needed for proper notification to your desktop applications, such as Gnome and KDE. You will still require the udev script to handle the proper removal.&lt;br /&gt;
&lt;br /&gt;
To tell HAL that devices connected to the UltraBay port are hotpluggable, you need to create a file {{path|/etc/hal/fdi/information/10-thinkpad-ultrabay.fdi}} with the following content:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;ISO-8859-1&amp;quot;?&amp;gt; &amp;lt;!-- -*- SGML -*- --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
HAL config file to set ThinkPad Ultrabay eject capability flag.&lt;br /&gt;
Note that ThinkPad model matching is done on a partial match, so T40 will also match T40p, which is what we want.&lt;br /&gt;
&lt;br /&gt;
If your ThinkPad model is not listed, please check with lspci what PCI ID your disk controller is&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;deviceinfo version=&amp;quot;0.2&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;device&amp;gt;&lt;br /&gt;
    &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; prefix=&amp;quot;ThinkPad&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.vendor&amp;quot; string=&amp;quot;IBM&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- IBM ThinkPad A20m, A20p, A21e, A21m, A21p, A22e, A22m, A22p, T20, T21, T22, X20 and X21 --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;A20;A21;A22;T20;T21;T22;X20;X21&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_7111_scsi_host_0_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- IBM ThinkPad T23, T30, X22, X23, X24 and X30 --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;T23;T30;X22;X23;X24;X30&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_248a_scsi_host_0_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- IBM ThinkPad A30, A30p, A31 and A31p - 2 Ultrabay devices--&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;A30;A31&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_248a_scsi_host_scsi_device_lun0_0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_248a_scsi_host_0_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- IBM ThinkPad R50, R51, T40, T40p, T41, T41p, X31, X32 and X40 --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;R50;R51;T40;T41;T42;X31;X32;X40&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_24ca_scsi_host_0_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- IBM ThinkPad R52, T43, T43p, X41, Z60m and Z60p --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;R52;T43;X41;Z60&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_2653_scsi_host_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
      &amp;lt;/match&amp;gt;&lt;br /&gt;
      &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.vendor&amp;quot; string=&amp;quot;LENOVO&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- Lenovo ThinkPad T60, T60p, Z61m, Z61t and Z61p --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;T60;Z61&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_27df_scsi_host_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- Lenovo ThinkPad R60 and X60 --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;R60;X60&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_27c4_scsi_host_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- Lenovo ThinkPad R61, T61, T61p and X300 --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;R61;T61;X300&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_2850_scsi_host_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- Lenovo ThinkPad R400, R500, T400, T500, W500, W700, X200 and X301 --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;R400;R500;T400;T500;W500;W700;X200;X301&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_2929_scsi_host_0_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;!-- Lenovo ThinkPad T410, T510 --&amp;gt;&lt;br /&gt;
        &amp;lt;match key=&amp;quot;/org/freedesktop/Hal/devices/computer:system.hardware.version&amp;quot; contains_outof=&amp;quot;T410;T510&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string_outof=&amp;quot;pci;scsi&amp;quot;&amp;gt;&lt;br /&gt;
            &amp;lt;match key=&amp;quot;info.parent&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_3b2f_scsi_host_0_scsi_device_lun0&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
            &amp;lt;/match&amp;gt;&lt;br /&gt;
          &amp;lt;/match&amp;gt;&lt;br /&gt;
        &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
      &amp;lt;/match&amp;gt;&lt;br /&gt;
    &amp;lt;/match&amp;gt;&lt;br /&gt;
  &amp;lt;/device&amp;gt;&lt;br /&gt;
&amp;lt;/deviceinfo&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then ensure it has the right permissions&lt;br /&gt;
&lt;br /&gt;
 chown root:root /etc/hal/fdi/information/10-thinkpad-ultrabay.fdi&lt;br /&gt;
 chmod 644 /etc/hal/fdi/information/10-thinkpad-ultrabay.fdi&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To check the effect, look at your lshal output, the section for your optical disk (/dev/sr0 typically) or your 2nd hdd (/dev/sdb typically) should have storage.hotpluggable = true after restarting your hal deamon or rebooting.&lt;br /&gt;
&lt;br /&gt;
===Disable ultrabay at boot time===&lt;br /&gt;
To save some energy you can create an init.d start script to automatically &amp;quot;eject&amp;quot; the ultrabay at boot time&amp;lt;br /&amp;gt;&lt;br /&gt;
vim /etc/init.d/stop-ultrabay&lt;br /&gt;
 &lt;br /&gt;
 #! /bin/sh &lt;br /&gt;
 ### BEGIN INIT INFO&lt;br /&gt;
 # Provides:          stop-ultrabay&lt;br /&gt;
 # Required-Start:    $remote_fs $syslog&lt;br /&gt;
 # Required-Stop:     $remote_fs $syslog&lt;br /&gt;
 # Default-Start:     2 3 4 5&lt;br /&gt;
 # Default-Stop:      0 1 6&lt;br /&gt;
 # Short-Description: stops the ultrabay&lt;br /&gt;
 ### END INIT INFO&lt;br /&gt;
 &lt;br /&gt;
 # Script to shutdown ultrabay at boot time. To reenable, simply push the ultrabay eject lever&lt;br /&gt;
 # and put it in again.&lt;br /&gt;
 # By Frank Doelitzscher, 2010-08-04&lt;br /&gt;
 #&lt;br /&gt;
 &lt;br /&gt;
 # This things will always run&lt;br /&gt;
 /usr/local/sbin/ultrabay_eject&lt;br /&gt;
 &lt;br /&gt;
 # Carry out specific functions when asked to by the system&lt;br /&gt;
 case &amp;quot;$1&amp;quot; in&lt;br /&gt;
 *)&lt;br /&gt;
    echo &amp;quot;This script runs automatically at boot time.&amp;quot;&lt;br /&gt;
    echo &amp;quot;It does not need any switches like start|stop&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
    ;;&lt;br /&gt;
 esac &lt;br /&gt;
 exit 0&lt;br /&gt;
Then ensure it has the right permissions&amp;lt;br /&amp;gt;&lt;br /&gt;
 chmod 755 /etc/init.d/stop-ultrabay&lt;br /&gt;
 &lt;br /&gt;
And make it known to the init subsystem&amp;lt;br /&amp;gt;&lt;br /&gt;
 update-rc.d -f stop-ultrabay start 90 2 3 4 5 .&lt;br /&gt;
&lt;br /&gt;
It just gets a start script since it does not make sense to execute it at a shutdown or restart.&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was tested on a T60 running Debian Squeeze with standard 2.6.32-5-686 #1 SMP without any issues.&lt;br /&gt;
&lt;br /&gt;
==When using the &amp;lt;tt&amp;gt;ide-disk&amp;lt;/tt&amp;gt; driver==&lt;br /&gt;
The following applies if you use the &amp;lt;tt&amp;gt;ide-disk&amp;lt;/tt&amp;gt; driver for the UltraBay device.&amp;lt;BR&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note that essentially, you shouldn't be using this driver, and use ata_piix instead unless you're running an older kernel where ata_piix won't work for you&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Hotswapping is supposed to be supported as well, using either hdparm/[http://packages.debian.org/unstable/admin/hotswap Debian hotswap] or [[lt_hotswap]] to (un)register IDE devices. The latter is the recommended method with kernels from 2.6, since it will leave DMA working. However, for recent models (R52, T43, X41, Z60 and later) no method is known to work while maintaining DMA support; see [[Problems with SATA and Linux]].&lt;br /&gt;
&lt;br /&gt;
Only IDE devices (HDD's, optical drives, zip drives) require special treatment - batteries, floppies and other devices can just be pulled from the bay, provided they are not mounted or in use at the time. However, you should still power them down first using the [[thinkpad-acpi]] eject function.&lt;br /&gt;
&lt;br /&gt;
The [[thinkpad-acpi]] kernel module has an eject function ({{cmdroot|echo eject &amp;gt; /proc/acpi/ibm/bay}}). This only manages the ACPI calls to power down the device and the bay. It does not actually unregister the device from the IDE driver. {{cmdroot|cat /proc/acpi/ibm/bay}} shows &amp;quot;unoccupied&amp;quot; unless an IDE device is present, but the eject function still works and should still be used.&lt;br /&gt;
&lt;br /&gt;
To unregister the device, you can either use the [http://packages.debian.org/unstable/admin/hotswap Debian hotswap] package, or [[lt_hotswap]]. Note that lt_hotswap doesn't seem to even build on recent (at 2.6.22 or newer, although it probably broke before 2.6.22) and on newer kernels, you should not build/load the old IDE PIIX (CONFIG_BLK_DEV_PIIX) and use the natively hotswapping ata_piix (CONFIG_ATA_PIIX) as explained on the top of this page.&lt;br /&gt;
&lt;br /&gt;
[http://packages.debian.org/unstable/admin/hotswap Debian hotswap] also allows the drive to be swapped as a normal user by default, which is useful. You should use &amp;lt;tt&amp;gt;hotswap&amp;lt;/tt&amp;gt; to unregister the device and then {{cmdroot|echo eject &amp;gt; /proc/acpi/ibm/bay}}. However, if you use this method on a 2.6 kernel, you will lose DMA support for the reinserted drive. This is due to kernel issues. This method was reported to work on a ThinkPad {{T23}} (kernels 2.6.8.1, 2.6.14.2 and 2.6.15-arch) and {{T42}} (kernel 2.6.13), but fails on a ThinkPad {{T43}} (kernel 2.6.14.3).&lt;br /&gt;
&lt;br /&gt;
[[lt_hotswap]] is now the recommended method to un- and reregister the IDE device. It installs as a kernel module and has support for automatically unregistering (if loaded with the auto_eject=1 option) the device when the eject event is generated by [[thinkpad-acpi]]. It will leave DMA support intact. It has supported to work on a ThinkPad {{T22}} and {{T40}} and should work with many other models (but not recent models which require the &amp;lt;tt&amp;gt;ata_piix&amp;lt;/tt&amp;gt; driver for disk DMA support). With the [[lt_hotswap]] kernel module loaded, run: {{cmdroot|modprobe -r ide_cd &amp;amp;&amp;amp; modprobe -r cdrom &amp;amp;&amp;amp; echo &amp;quot;MSTR eject&amp;quot; &amp;gt; /proc/acpi/lths}}&lt;br /&gt;
&lt;br /&gt;
===HAL support===&lt;br /&gt;
&lt;br /&gt;
HAL support also can also be configured To do so, create the file {{path|/etc/hal/fdi/information/10-ultrabay.fdi}} as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt; &amp;lt;!-- -*- SGML -*- --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;deviceinfo version=&amp;quot;0.2&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;device&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;!-- UltraBay Devices --&amp;gt;&lt;br /&gt;
    &amp;lt;match key=&amp;quot;storage.bus&amp;quot; string=&amp;quot;ide&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;match key=&amp;quot;storage.physical_device&amp;quot; string=&amp;quot;/org/freedesktop/Hal/devices/pci_8086_24ca_ide_1_0&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;merge key=&amp;quot;storage.hotpluggable&amp;quot; type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/merge&amp;gt;&lt;br /&gt;
      &amp;lt;/match&amp;gt;&lt;br /&gt;
    &amp;lt;/match&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/device&amp;gt;&lt;br /&gt;
&amp;lt;/deviceinfo&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
For more details see HAL section for ata driver.&lt;br /&gt;
&lt;br /&gt;
==Password protected HDD==&lt;br /&gt;
{{WARN|Do not attempt to set a new HDD password with hdparm - if you succeed, it is likely that the drive will not unlock and it will not be possible to remove the password either.}}&lt;br /&gt;
There are multiple issues with hotplugging a password protected HDD. In short, it does not work from within the operating system. You will need to reboot, or use the suspend/wakeup procedure below, and let the BIOS do the unlock.&lt;br /&gt;
===hdparm===&lt;br /&gt;
While in theory you should be a able to use hdparm to unlock a drive, or set or remove a password. In practice none of it works the way it should.&lt;br /&gt;
&lt;br /&gt;
First of all, by default the BIOS during POST will freeze the security settings of any drives that are present, preventing you from making changes until the drive is power cycled. You can see this by running the following command&lt;br /&gt;
 # hdparm -I /dev/sdb|grep frozen&lt;br /&gt;
 	not	frozen&lt;br /&gt;
If the above command simply returns 'frozen' any hdparm security commands will fail with an IO error. If this is an Ultrabay HDD you can simply remove the drive and hotplug it again to reset the drive.&lt;br /&gt;
&lt;br /&gt;
If your drive has a PW set by the BIOS, any attempt to unlock it will result in an IO error.&lt;br /&gt;
&lt;br /&gt;
But a fatal flaw is to use hdparm to actually set a password, if you do you will find the following issues&lt;br /&gt;
* setting a Master password will appear to succeed, but in fact does nothing&lt;br /&gt;
* setting a User password does succeed, but you will no longer be able to unlock or remove the password using either hdparm or the BIOS. hdparm will just give IO errors, and the BIOS will report the password being wrong. It is speculated that the BIOS applies some kind of hashing to the password, which is why setting the PW from the BIOS and setting the PW with hdparm is incompatible.&lt;br /&gt;
&lt;br /&gt;
 # hdparm --verbose --user-master u --security-disable test /dev/sdb&lt;br /&gt;
 security_password=&amp;quot;test&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 /dev/sdb:&lt;br /&gt;
  Issuing SECURITY_DISABLE command, password=&amp;quot;test&amp;quot;, user=user&lt;br /&gt;
 oflags.lob_all=0x82, flags={ feat command }&lt;br /&gt;
 oflags.hob_all=0x82, flags={ feat }&lt;br /&gt;
 using LBA48 taskfile&lt;br /&gt;
 outgoing cdb:  85 0b 26 00 00 00 00 00 00 00 00 00 00 40 f2 00&lt;br /&gt;
 data:  00 00 74 65 73 74 00 00 00 00 00 00 00 00 00 00&lt;br /&gt;
 SG_IO: ATA_16 status=0x2, host_status=0x0, driver_status=0x8&lt;br /&gt;
 SG_IO: sb[]:  72 0b 00 00 00 00 00 0e 09 0c 01 04 00 00 00 00 00 00 00 00 e0 51 00 00 00 00 00 00 00 00 00 00&lt;br /&gt;
 SG_IO: desc[]:  09 0c 01 04 00 00 00 00 00 00 00 00&lt;br /&gt;
       ATA_16 stat=51 err=04 nsect=00 lbal=00 lbam=00 lbah=00 dev=e0&lt;br /&gt;
 I/O error, ata_op=0xf2 ata_status=0x51 ata_error=0x04&lt;br /&gt;
 SECURITY_UNLOCK: Input/output error&lt;br /&gt;
&lt;br /&gt;
*[https://bugzilla.redhat.com/show_bug.cgi?id=603018 bug report against hdparm]&lt;br /&gt;
&lt;br /&gt;
===Letting the BIOS unlock the disk by suspending the computer===&lt;br /&gt;
&lt;br /&gt;
A password protected disk can be unlocked by ensuring the laptop has been suspended '''before''' inserting the disk into the Ultrabay.  The device being removed should still be ejected before suspending the laptop.&lt;br /&gt;
&lt;br /&gt;
Upon waking up (resuming) the computer the BIOS should prompt for the password, and provided you enter it correctly, will unlock the disk.  Once Linux regains control it may be necessary to re-scan the SCSI bus to find the disk and make it available, using the command &amp;quot;sudo rescan-scsi-bus.sh&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
This is confirmed to work on a T61 running Ubuntu 8.04, (kernel 2.6.24) with the scsitools package installed.&lt;br /&gt;
&lt;br /&gt;
===libata EH going crazy===&lt;br /&gt;
hotplugging a password protected HDD causes the libata error handler to go crazy&lt;br /&gt;
&lt;br /&gt;
 ACPI: \_SB_.PCI0.IDE0.SCND.MSTR - docking&lt;br /&gt;
 ata2: exception Emask 0x10 SAct 0x0 SErr 0x0 action 0xe frozen&lt;br /&gt;
 ata2: ACPI event&lt;br /&gt;
 ata2: soft resetting link&lt;br /&gt;
 ata2.00: ATA-6: HTS726060M9AT00, MH4OA6DA, max UDMA/100&lt;br /&gt;
 ata2.00: 117210240 sectors, multi 0: LBA &lt;br /&gt;
 ata2.00: limited to UDMA/33 due to 40-wire cable&lt;br /&gt;
 ata2.00: configured for UDMA/33&lt;br /&gt;
 ata2: EH complete&lt;br /&gt;
 scsi 1:0:0:0: Direct-Access     ATA      HTS726060M9AT00  MH4O PQ: 0 ANSI: 5&lt;br /&gt;
 sd 1:0:0:0: Attached scsi generic sg1 type 0&lt;br /&gt;
 sd 1:0:0:0: [sdb] 117210240 512-byte logical blocks: (60.0 GB/55.8 GiB)&lt;br /&gt;
 sd 1:0:0:0: [sdb] Write Protect is off&lt;br /&gt;
 sd 1:0:0:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA&lt;br /&gt;
 sdb:&lt;br /&gt;
&lt;br /&gt;
After which there are hundreds of errors such as these...&lt;br /&gt;
 ata2.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x0&lt;br /&gt;
 ata2.00: BMDMA stat 0x5&lt;br /&gt;
 ata2.00: failed command: READ DMA&lt;br /&gt;
 ata2.00: cmd c8/00:08:00:00:00/00:00:00:00:00/e0 tag 0 dma 4096 in&lt;br /&gt;
         res 51/04:08:00:00:00/00:00:00:00:00/e0 Emask 0x1 (device error)&lt;br /&gt;
 ata2.00: status: { DRDY ERR }&lt;br /&gt;
 ata2.00: error: { ABRT }&lt;br /&gt;
 ata2.00: configured for UDMA/33&lt;br /&gt;
 ata2: EH complete&lt;br /&gt;
&lt;br /&gt;
Basically what is happening is that libata is ignoring the ATA IDENTIFY data, that reports that the drive is locked, and just tries to scan for every partition type possible.&lt;br /&gt;
*[https://bugzilla.kernel.org/show_bug.cgi?id=16181 Bug report against libata]&lt;br /&gt;
&lt;br /&gt;
===udisks===&lt;br /&gt;
lastly, there should be some userland support to detect the password protected HDD and prompt you for a password or retrieve the password from gnome-keyring. But that will require hdparm to be able to unlock the HDD first, and to figure out if the BIOS is doing some kind of hashing and how.&lt;br /&gt;
&lt;br /&gt;
*[https://bugs.freedesktop.org/show_bug.cgi?id=23110 bug report against udisks]&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripts]]&lt;br /&gt;
[[Category:HOWTOs]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=How_to_reduce_power_consumption&amp;diff=62687</id>
		<title>How to reduce power consumption</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=How_to_reduce_power_consumption&amp;diff=62687"/>
		<updated>2025-10-27T02:37:23Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: If there's a single Wi-Fi card, it's generally wlan0, not eth1. Grammar. 1000BASE-T require auto-negotiation and most networks are 1000BASE-T now - with the exception of now rare 100BASE-TX networks.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Reducing system power consumption will extend battery life, reduce system&lt;br /&gt;
temperature and (on some models) reduce system fan noise.&lt;br /&gt;
Power consumption can be greatly improved from a stock distribution configuration&lt;br /&gt;
to a fine tuned system. The general rules are :&lt;br /&gt;
* Unload drivers for unused devices (ie. USB 1.1, Yenta/PCMCIA, Wireless, IRDA, Bluetooth, ...)&lt;br /&gt;
* Reduce polling on devices (drives, USB subsystem, nvram, use SATA AN, ...)&lt;br /&gt;
* Reduce hard drive activity&lt;br /&gt;
* Reduce LCD brightness to the minimum you can stand&lt;br /&gt;
* Reduce CPU wakeups, so it can stay longer in deep power saving c-states&lt;br /&gt;
* Make use of every hardware devices availables power saving features (AHCI ALPM, USB autosuspend, Alsa and Wireless powersaving modes, HPET timers, ...)&lt;br /&gt;
&lt;br /&gt;
==Tools==&lt;br /&gt;
Arjan van de Ven's [[PowerTOP]] utility&lt;br /&gt;
is a gold mine to improve energy efficiency, but is almost only CPU-oriented. This tool helps to easily detect&lt;br /&gt;
the top power offenders, both userland and kernel modules, which prevent the use of CPU power saving mechanisms and sometime suggest &lt;br /&gt;
fixes accordingly.&lt;br /&gt;
PowerTOP users collected some [http://www.lesswatts.org/projects/powertop/known.php tips &amp;amp; tricks]&lt;br /&gt;
and an informative [http://www.lesswatts.org/projects/powertop/faq.php faq].&lt;br /&gt;
&lt;br /&gt;
Alternatively (or complementary) to PowerTOP, running &amp;lt;code&amp;gt;strace -p $(pidof yourapp)&amp;lt;/code&amp;gt; &lt;br /&gt;
for all your favorite or background running applications while they are expected to be &lt;br /&gt;
idle, will show the misbehaviors.&lt;br /&gt;
&lt;br /&gt;
Beside CPU wakeups, disks spins are also power hungry. To detect what make your disk spinning,&lt;br /&gt;
&lt;br /&gt;
 sysctl vm.block_dump=1&lt;br /&gt;
&lt;br /&gt;
will list all applications causing disks wakeups on the kernel's dmesg.&lt;br /&gt;
Other useful tools for this purpose are blktrace, iostat and lm-profiler&lt;br /&gt;
(from laptop-mode-tools suite).&lt;br /&gt;
&lt;br /&gt;
See also [[#Misbehaving Userland]].&lt;br /&gt;
&lt;br /&gt;
==BIOS settings==&lt;br /&gt;
===Enabling Power Management===&lt;br /&gt;
Some Thinkpad BIOS (like 2.08 BIOS on {{X40}}) offer two very lame options,&lt;br /&gt;
with a very misleading online help (saying &amp;quot;Usually not needed&amp;quot;). That's&lt;br /&gt;
&lt;br /&gt;
 CPU power management: (default disabled)&lt;br /&gt;
 PCI bus power management: (default disabled)&lt;br /&gt;
&lt;br /&gt;
You should indeed ''enable'' them, else the deepest C3 and C4 ACPI C-states&lt;br /&gt;
are disabled.&lt;br /&gt;
&lt;br /&gt;
===Disabling I/O Ports===&lt;br /&gt;
The BIOS (at least version 3.11 on {{X200}}) can also be used to disable I/O ports, like PCMCIA/CardBus.  Although this requires a reboot to change settings, using the BIOS rather than a configuration file will survive distribution changes and may make it easier to remember how to re-enable a port.  Disabling these devices can reduce power consumption by several watts.&lt;br /&gt;
&lt;br /&gt;
==CPU==&lt;br /&gt;
Look at:&lt;br /&gt;
* [[How to make use of Dynamic Frequency Scaling]]&lt;br /&gt;
* [[Pentium M undervolting and underclocking]]&lt;br /&gt;
&lt;br /&gt;
A good thing to keep in mind is that every CPU wakeup, even if it's for&lt;br /&gt;
a trivial light job, reduce the time the CPU stays on a deep power&lt;br /&gt;
saving C-state (like C3 or C4). Therefore you should ensure your applications&lt;br /&gt;
stay really idle when they meant to be idle (track shorts select timeouts&lt;br /&gt;
in loop, etc. with [[PowerTOP]]).&lt;br /&gt;
&lt;br /&gt;
Also note that manually locking the CPU in the lowest P-state (frequency) &lt;br /&gt;
available is '''not''' an efficient way to improve battery lifetime. This will&lt;br /&gt;
cause the CPU to stay longer in C0 (power hungry C-state) doing hard work when &lt;br /&gt;
there is something to do, while it could have done this work faster by augmenting&lt;br /&gt;
the CPU freq, and returned back faster to a deeper, economic, C-state and to a&lt;br /&gt;
lower frequency (P-state).&lt;br /&gt;
The best is to let the kernel select the appropriates CPU frequencies by itself&lt;br /&gt;
with the help of in kernel CPU governors.&lt;br /&gt;
Have a look at [http://www.bughost.org/pipermail/power/2007-May/000166.html this explanation]&lt;br /&gt;
from Intel's kernel developer Arjan van de Ven.&lt;br /&gt;
&lt;br /&gt;
==Kernel settings and patches==&lt;br /&gt;
&lt;br /&gt;
===General settings===&lt;br /&gt;
The 2.6.21 kernel brought some very effective changes (like [[dynticks]]). &lt;br /&gt;
Later, 2.6.24-rc2 brought a lot of other power efficiency improvements. &lt;br /&gt;
If it's not already on your distribution and you value power efficiency, &lt;br /&gt;
you may think about compiling a recent kernel yourself. &lt;br /&gt;
&lt;br /&gt;
Here are a few options (beside the ACPI and APM related one) that matter to &lt;br /&gt;
reduce power consumption or to help diagnosing consumers:&lt;br /&gt;
&lt;br /&gt;
 # From PowerTOP's FAQ:&lt;br /&gt;
 CONFIG_NO_HZ&lt;br /&gt;
 CONFIG_HIGH_RES_TIMERS&lt;br /&gt;
 CONFIG_HPET&lt;br /&gt;
 CONFIG_HPET_TIMER&lt;br /&gt;
 CONFIG_CPU_FREQ_GOV_ONDEMAND&lt;br /&gt;
 CONFIG_USB_SUSPEND&lt;br /&gt;
 CONFIG_SND_AC97_POWER_SAVE&lt;br /&gt;
 CONFIG_SND_HDA_POWER_SAVE&lt;br /&gt;
 CONFIG_SND_HDA_POWER_SAVE_DEFAULT=3&lt;br /&gt;
 CONFIG_TIMER_STATS&lt;br /&gt;
 CONFIG_ACPI_BATTERY&lt;br /&gt;
 CONFIG_CPU_FREQ_STAT&lt;br /&gt;
 CONFIG_INOTIFY&lt;br /&gt;
&lt;br /&gt;
 # Not from the PowerTOP FAQ:&lt;br /&gt;
 CONFIG_BLK_DEV_IO_TRACE&lt;br /&gt;
 CONFIG_X86_ACPI_CPUFREQ&lt;br /&gt;
 CONFIG_X86_SPEEDSTEP_CENTRINO depreciated as of kernel 2.6.24, use CONFIG_X86_ACPI_CPUFREQ&lt;br /&gt;
 CONFIG_X86_SPEEDSTEP_ICH&lt;br /&gt;
 CONFIG_X86_SPEEDSTEP_SMI&lt;br /&gt;
 CONFIG_CPU_IDLE&lt;br /&gt;
 CONFIG_CPU_IDLE_GOV_LADDER&lt;br /&gt;
 CONFIG_CPU_IDLE_GOV_MENU&lt;br /&gt;
&lt;br /&gt;
Those options are already in Fedora Core 7 and Ubuntu Gutsy (not Feisty) default i686 kernels.&lt;br /&gt;
PowerTOP FAQ also suggest to '''disable'''&lt;br /&gt;
CONFIG_IRQBALANCE and CONFIG_ACPI_DEBUG.&lt;br /&gt;
&lt;br /&gt;
Also, you need to properly set APM and ACPI. Look at:&lt;br /&gt;
* [[Power Management]]&lt;br /&gt;
* [[How to make use of Power Management features]]&lt;br /&gt;
&lt;br /&gt;
=== Kernel boot and module loading options ===&lt;br /&gt;
If you have an Intel chipset ICH5 or later (cf. lspci output), as in most modern Thinkpads, you should&lt;br /&gt;
be using the integrated HPET timer (saves about 30 CPU wake ups per second). To see if&lt;br /&gt;
hpet is enabled on your laptop:&lt;br /&gt;
&lt;br /&gt;
 grep hpet /proc/timer_list&lt;br /&gt;
&lt;br /&gt;
If this does not display &amp;quot;Clock Event Device: hpet&amp;quot;, then add &lt;br /&gt;
&lt;br /&gt;
 hpet=force&lt;br /&gt;
&lt;br /&gt;
{{WARN|The ICH4 does have an HPET, but it is disabled for a good reason: Intel didn't test/validade it!  Use of the ICH4 HPET is '''not''' recommended}}&lt;br /&gt;
&lt;br /&gt;
to your kernel boot options (usualy in /boot/grub/menu.lst or lilo.conf). &lt;br /&gt;
Note that &amp;quot;hpet=force&amp;quot; is only available by default in 2.6.24-rc2 and above &lt;br /&gt;
(or as a separated patch for 2.6.22 and 2.6.23, see below).&lt;br /&gt;
&lt;br /&gt;
On modern ThinkPads the HPET timer is automatically detected and enabled. On certain older machines hpet=force is required such as on the following machines:&lt;br /&gt;
* {{T30}}, {{T40}}, {{T40p}}, {{T41}}, {{T41p}}, {{T42}}&lt;br /&gt;
* {{X22}}, {{X23}}, {{X24}}, {{X30}}, {{X31}}, {{X40}}&lt;br /&gt;
* {{A31}}&lt;br /&gt;
* {{SL500}}&lt;br /&gt;
&lt;br /&gt;
{{HELP|please add your ThinkPad to the above list, if &amp;lt;nowiki&amp;gt;hpet=force&amp;lt;/nowiki&amp;gt; was required}}&lt;br /&gt;
&lt;br /&gt;
===Useful Patches===&lt;br /&gt;
&lt;br /&gt;
Thomas Gleixner High Resolution Timers (hrt) patchset brings many improvements,&lt;br /&gt;
like the cpuidle work and Udo A. Steinberg and Venki Pallipadi &amp;quot;force&lt;br /&gt;
enable HPET&amp;quot; patches (non HPET timers causes about 20-40 CPU wakeups/second, but&lt;br /&gt;
HPET is often hidden by the BIOS due to Windows XP deficiencies). Those are &lt;br /&gt;
fully merged in 2.6.24-rc1 vanilla kernel.&lt;br /&gt;
See http://www.tglx.de/projects/hrtimers/&lt;br /&gt;
&lt;br /&gt;
Kristen Carlson Accardi from Intel has a patchset to turn on &amp;quot;Aggressive&lt;br /&gt;
Link Power Management&amp;quot; (ALPM) for the AHCI driver (for SATA bus). Also from&lt;br /&gt;
Accardi, SATA Asynchronous Notification (SATA AN), alows SATA link to notify&lt;br /&gt;
media insertions (thus avoid hal polling the cdrom). Those patches were merged &lt;br /&gt;
in 2.6.24-rc2 kernel (AN needs also support in hal to be used).&lt;br /&gt;
See: http://www.kernel.org/pub/linux/kernel/people/kristen/patches/SATA/alpm/&lt;br /&gt;
&lt;br /&gt;
As of now (2.6.24-rc8), the linux kernel doesn't support PCI Express power &lt;br /&gt;
management (aka PCIe ASPM, aka PCIe LPM). Shaohua Li from Intel submited a &lt;br /&gt;
patch on LKML (http://lkml.org/lkml/2008/1/17/544 ) though, and reported it &lt;br /&gt;
to reduce power consumption by 1.3 watts for a system with three PCIe links.&lt;br /&gt;
&lt;br /&gt;
The [[HDAPS]] disk protection systems can reduce battery life. &lt;br /&gt;
Matthew Garrett provides [http://www.linuxpowertop.org/patches/hdaps.patch a patch]&lt;br /&gt;
that prevents hdaps kernel module to generate interrupts when&lt;br /&gt;
this feature isn't used.&lt;br /&gt;
&lt;br /&gt;
===Useful sysctls===&lt;br /&gt;
The meaning of those settings is explained case by case on the relevant &lt;br /&gt;
sections of this document. But for convenience sake, we group them here too.&lt;br /&gt;
&lt;br /&gt;
Note that the &amp;quot;ondemand&amp;quot; scaling governor is recommended by Intel developers&lt;br /&gt;
for energy efficiency: it's expected to be more efficient than the &amp;quot;powersave&amp;quot;&lt;br /&gt;
governor, or than userspace daemons (like cpufreq-utils, cpufreqd, powernowd...).&lt;br /&gt;
Look [http://www.bughost.org/pipermail/power/2007-May/000071.html here],&lt;br /&gt;
[http://www.bughost.org/pipermail/power/2007-May/000073.html here], or&lt;br /&gt;
[http://www.bughost.org/pipermail/power/2007-May/000166.html here] for a&lt;br /&gt;
kernel developer explanation about &amp;quot;ondemand&amp;quot; being better on modern Intel CPUs.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;link_power_management_policy&amp;quot; tunable won't be available unless you&lt;br /&gt;
run a 2.6.24-rc2 or more kernel, or applied Kirsten patchset, have an Intel &lt;br /&gt;
AHCI compatible chipset, and use SATA drives.&lt;br /&gt;
&lt;br /&gt;
 echo 5 &amp;gt; /proc/sys/vm/laptop_mode&lt;br /&gt;
 echo 0 &amp;gt; /proc/sys/kernel/nmi_watchdog&lt;br /&gt;
 echo Y &amp;gt; /sys/module/snd_ac97_codec/parameters/power_save&lt;br /&gt;
 echo 1 &amp;gt; /sys/devices/system/cpu/sched_mc_power_savings&lt;br /&gt;
 echo ondemand &amp;gt; /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor&lt;br /&gt;
 echo 1500 &amp;gt; /proc/sys/vm/dirty_writeback_centisecs&lt;br /&gt;
 for i in /sys/bus/usb/devices/*/power/autosuspend; do echo 1 &amp;gt; $i; done&lt;br /&gt;
 # those sysctl's are only available if you have an AHCI compatible SATA &lt;br /&gt;
 # controler and use kernel &amp;gt; 2.6.24-rc2 (or use Kristen ALPM patchset) : &lt;br /&gt;
 echo min_power &amp;gt; /sys/class/scsi_host/host0/link_power_management_policy&lt;br /&gt;
 echo min_power &amp;gt; /sys/class/scsi_host/host1/link_power_management_policy&lt;br /&gt;
 echo min_power &amp;gt; /sys/class/scsi_host/host2/link_power_management_policy&lt;br /&gt;
&lt;br /&gt;
If you're running a kernel older than 2.6.22 do this. Not needed for kernels 2.6.22 onward:&lt;br /&gt;
&lt;br /&gt;
 cd /sys/devices/system/cpu/cpu0/cpufreq&lt;br /&gt;
 cat ondemand/sampling_rate_max &amp;gt; ondemand/sampling_rate&lt;br /&gt;
&lt;br /&gt;
==ATA drives==&lt;br /&gt;
Hard drives and CDRom drives spinning is very costly. To improve battery&lt;br /&gt;
lifetime, you should reduce disks access (or devices polling) the more you&lt;br /&gt;
can.  &lt;br /&gt;
&lt;br /&gt;
===Hard Drives===&lt;br /&gt;
&lt;br /&gt;
The files access time update, while mandated by POSIX, is causing lots of&lt;br /&gt;
disk write access; even accessing files on disk cache may wake the ATA or USB&lt;br /&gt;
bus. If you don't use this feature, disable it by adding the &amp;lt;tt&amp;gt;relatime&amp;lt;/tt&amp;gt;&lt;br /&gt;
option to all relevant lines in the /etc/fstab, for example:&lt;br /&gt;
 /dev/sda1 / ext3 relatime,errors=remount-ro 0 1&lt;br /&gt;
&lt;br /&gt;
(On older kernels you may need to use &amp;lt;tt&amp;gt;noatime&amp;lt;/tt&amp;gt; instead of &amp;lt;tt&amp;gt;relatime&amp;lt;/tt&amp;gt;.)&lt;br /&gt;
&lt;br /&gt;
Also consider merely using a larger value for the &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; option. This defines how often changed data is written to the disk (it is cached until then). The default value is 5 seconds.&lt;br /&gt;
&lt;br /&gt;
See man mount(8) for details on how the &amp;lt;tt&amp;gt;rel/noatime&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; options work.&lt;br /&gt;
&lt;br /&gt;
Use laptop_mode to reduce disk usage by delaying and grouping writes. You should enable&lt;br /&gt;
it, at least while on battery. See [[Laptop-mode]] for more details:&lt;br /&gt;
&lt;br /&gt;
 echo 5 &amp;gt; /proc/sys/vm/laptop_mode&lt;br /&gt;
&lt;br /&gt;
The default kernel dirty page writeback frequency is very conservative. On&lt;br /&gt;
a laptop running on battery, one might find more appropriate to reduce it:&lt;br /&gt;
&lt;br /&gt;
 echo 1500 &amp;gt; /proc/sys/vm/dirty_writeback_centisecs&lt;br /&gt;
&lt;br /&gt;
Some power saving hard drives features can be activated with hdparm (beware&lt;br /&gt;
that &amp;quot;-B 1&amp;quot; may reduce your drive lifetime, if you have lot of intermittent&lt;br /&gt;
disk activity causing lots of heads load/unloads: so reduce I/O activity first,&lt;br /&gt;
as explained above, in order to get longer disks idling periods).&lt;br /&gt;
For more details look at [[How to make use of Power Management features]] :&lt;br /&gt;
&lt;br /&gt;
 hdparm -B 1 -S 12 /dev/sda # and/or any other disk device&lt;br /&gt;
&lt;br /&gt;
====SATA Link Power Management====&lt;br /&gt;
On kernels 2.6.24 and new this enables SATA Link Power Management:&lt;br /&gt;
 echo min_power &amp;gt; /sys/class/scsi_host/host0/link_power_management_policy&lt;br /&gt;
 echo min_power &amp;gt; /sys/class/scsi_host/host1/link_power_management_policy&lt;br /&gt;
 echo min_power &amp;gt; /sys/class/scsi_host/host2/link_power_management_policy&lt;br /&gt;
&lt;br /&gt;
Disable it by replacing &amp;lt;code&amp;gt;min_power&amp;lt;/code&amp;gt; with &amp;lt;code&amp;gt;max_performance&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Which host-number to use depends on your laptop.  It is typically 0 for the main drive, but for example on the T61 the 0 and 1 are for the pata interface used for the optical drive, and the main hard-disk is on host2.&lt;br /&gt;
&lt;br /&gt;
On Ubuntu Hardy Heron with a 2.6.24-16 kernel, a suspend/resume cycle is much quicker if you disable SATA Link Power Management before initiating the suspend. As of Intrepid Ibex and kernel 2.6.27, this should be fixed. ([https://bugs.launchpad.net/linux/+bug/234047 Launchpad bug 234047], [http://bugzilla.kernel.org/show_bug.cgi?id=10817 Kernel bug 10817])&lt;br /&gt;
&lt;br /&gt;
====Laptop Mode Tools====&lt;br /&gt;
&lt;br /&gt;
The [http://samwel.tk/laptop_mode/ Laptop Mode Tools] utility implements many of the above power-saving measures from disks, and some others.&lt;br /&gt;
&lt;br /&gt;
===Optical drive===&lt;br /&gt;
The optical drive is reported to consume power even when not accessed. See &lt;br /&gt;
&lt;br /&gt;
* [[How to hotswap UltraBay devices|Eject the UltraBay optical drive]], or just turn off its power supply (i.e., run the appropriate eject script but leave the drive inserted).&lt;br /&gt;
* [[How to set optical drive speed|Reduce the spinning speed of the optical drive]].&lt;br /&gt;
&lt;br /&gt;
The hald daemon polling tends to maintain the ATA buses out of power saving&lt;br /&gt;
modes, and to wakeup CDROM drive (except if you have a kernel &amp;gt;= 2.6.24, hal &amp;gt;= 0.5.10,&lt;br /&gt;
and SATA AN compatible devices). If you have a recent hald version, you&lt;br /&gt;
can stop this polling when on battery:&lt;br /&gt;
&lt;br /&gt;
 hal-disable-polling --device /dev/scd0 # or whatever your CD drive is&lt;br /&gt;
&lt;br /&gt;
start polling again when on ac:&lt;br /&gt;
&lt;br /&gt;
 hal-disable-polling --enable-polling --device /dev/scd0 # or whatever your CD drive is&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If your hald is not recent enough, consider suspending it when running on battery. Some moderns SATA buses and drivers supports a notification mechanism (SATA AN - Asynchronous Events Notifications) that obsolete the need for polling on modern hardware; support for this feature had been merged in Linux 2.6.24-rc1 and HAL 0.5.10.&lt;br /&gt;
&lt;br /&gt;
==LCD Backlight/Brightness==&lt;br /&gt;
The LCD backlight is one of the very major power drain. &lt;br /&gt;
Reducing brightness to the lowest readable&lt;br /&gt;
level will save a lot of battery lifetime. Also, don't forget to configure&lt;br /&gt;
your screen saver to shutdown the screen backlight (rather than displaying some&lt;br /&gt;
eye candy), when no activity for a few minutes.&lt;br /&gt;
&lt;br /&gt;
You can also let the system [[automatically reduce brightness]] after a &lt;br /&gt;
period of inactivity.&lt;br /&gt;
&lt;br /&gt;
If you're choosing your Thinkpad laptop model, keep in mind that the screen&lt;br /&gt;
size affect the battery time greatly: more power needed for larger screens.&lt;br /&gt;
&lt;br /&gt;
The very recent, but xorg standard way to control backlight from CLI is&lt;br /&gt;
using xbacklight. ie. to set backlight at half the brightness:&lt;br /&gt;
&lt;br /&gt;
 xbacklight -set 50&lt;br /&gt;
&lt;br /&gt;
You should configure the DPMS to shutdown the screen when idle (rather than&lt;br /&gt;
displaying a fancy but power consuming screensaver). ie. to turn off the&lt;br /&gt;
display after 5 minutes of idling:&lt;br /&gt;
&lt;br /&gt;
 xset +dpms&lt;br /&gt;
 xset dpms 0 0 300&lt;br /&gt;
&lt;br /&gt;
===Screensaver method===&lt;br /&gt;
Alternatively, you can add a screensaver that does nothing but blank the screen and turn off the display. In this example, I'm using Linux Mint MATE 17.2, please adjust the keywords below accordingly. Also, you will need to enable DPMS as above, or as in [[How to make ACPI work#Screen blanking (Standby)]].&lt;br /&gt;
&lt;br /&gt;
We need to create 2 files, the first one is &amp;lt;code&amp;gt;/usr/share/applications/screensavers/screenoff.desktop&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
 [Desktop Entry]&lt;br /&gt;
 Name=Screen off&lt;br /&gt;
 Comment=Turns the screen off&lt;br /&gt;
 Exec=/usr/lib/mate-screensaver/screenoff&lt;br /&gt;
 TryExec=/bin/true&lt;br /&gt;
 StartupNotify=false&lt;br /&gt;
 Terminal=false&lt;br /&gt;
 Type=Application&lt;br /&gt;
 Categories=Screensaver;&lt;br /&gt;
 Keywords=MATE;screensaver;dpms;&lt;br /&gt;
 OnlyShowIn=MATE;&lt;br /&gt;
&lt;br /&gt;
The second one is &amp;lt;code&amp;gt;/usr/lib/mate-screensaver/screenoff&amp;lt;/code&amp;gt;, which needs to be executable:&lt;br /&gt;
&lt;br /&gt;
 #!/bin/sh&lt;br /&gt;
 pidof mate-screensaver-preferences | grep -w $PPID &amp;amp;&amp;amp; exit 0&lt;br /&gt;
 xset q | grep -q &amp;quot;Monitor is On&amp;quot; &amp;amp;&amp;amp; xset dpms force off&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;code&amp;gt;Keywords&amp;lt;/code&amp;gt; section and the &amp;lt;code&amp;gt;mate-screensaver-preferences&amp;lt;/code&amp;gt; should be customized according to your desktop (like Cinnamon, or GNOME, etc).&lt;br /&gt;
&lt;br /&gt;
After creating those files, open the Screensaver preferences dialog and choose the screensaver with the name &amp;quot;Screen off&amp;quot;. Now, when the screensaver is activated, the screen will fade to black and backlight will be turned off by DPMS.&lt;br /&gt;
&lt;br /&gt;
==Graphic controllers==&lt;br /&gt;
All xorg Thinkpad graphics chipsets drivers (ati, radeon, fglrx, i810) have&lt;br /&gt;
the same bug causing very frequent CPU wakeups when DRI is activated, even&lt;br /&gt;
when you don't use any 3D application.&lt;br /&gt;
This problem is partly fixed on xorg git tree but not released as of xorg&lt;br /&gt;
7.2. If you value more battery than 3D, you should disable DRI: put this on&lt;br /&gt;
the /etc/X11/xorg.conf &amp;quot;Device&amp;quot; of you graphic controller:&lt;br /&gt;
&lt;br /&gt;
 Option          &amp;quot;NoDRI&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Also be sure that DPMS is working: &amp;lt;code&amp;gt;grep DPMS /var/log/Xorg.0.log&amp;lt;/code&amp;gt;&lt;br /&gt;
should output &amp;quot;DPMS enabled&amp;quot;. If not, put &amp;lt;code&amp;gt;Option &amp;quot;DPMS&amp;quot;&amp;lt;/code&amp;gt; in your config.&lt;br /&gt;
See the section above about how to enable dpms driven display power saving.&lt;br /&gt;
&lt;br /&gt;
On recent xrandr/xorg versions, you can disable the TV output (or any other detected&lt;br /&gt;
as connected but not used outputs) when you're not using it: it's known to consume power. &lt;br /&gt;
&lt;br /&gt;
 xrandr # see all displays listed here, but that you don't actually use and disable them. &lt;br /&gt;
 xrandr --output TV --off # for instance (if &amp;quot;xrandr&amp;quot; above listed a connected output named &amp;quot;TV&amp;quot; that you don't use)&lt;br /&gt;
&lt;br /&gt;
When you don't have an external monitor plugged, disable CRT and DVI output &lt;br /&gt;
(for some, this can make a difference in power usage) : &lt;br /&gt;
&lt;br /&gt;
 echo crt_disable &amp;gt; /proc/acpi/ibm/video&lt;br /&gt;
 echo dvi_disable &amp;gt; /proc/acpi/ibm/video&lt;br /&gt;
&lt;br /&gt;
Some drivers have specials power saving mode, and/or allows underclocking the GPU. See also:&lt;br /&gt;
* [[How to make use of Graphics Chips Power Management features]], or with [[Rovclock]] on ATI.&lt;br /&gt;
* [[Problem with high power drain in ACPI sleep]]&lt;br /&gt;
&lt;br /&gt;
==USB Subsystem==&lt;br /&gt;
The kernel support an efficient USB 2.0 power saving feature if you enabled&lt;br /&gt;
CONFIG_USB_SUSPEND. This may not trigger in when you have an USB device&lt;br /&gt;
plugged (and beside, USB devices tends to suck power on their own), so avoid&lt;br /&gt;
using such devices when on battery. To enable it by default, you must add the line &lt;br /&gt;
&lt;br /&gt;
 options usbcore autosuspend=1&lt;br /&gt;
&lt;br /&gt;
to your &amp;lt;tt&amp;gt;/etc/modprobe.conf&amp;lt;/tt&amp;gt; or add it to (and create if necessary) the file &amp;lt;tt&amp;gt;/etc/modprobe.d/usbcore&amp;lt;/tt&amp;gt; depending on how your distribution organises modprobe configuration. &lt;br /&gt;
&lt;br /&gt;
If on the other hand, you have &amp;lt;tt&amp;gt;usbcore&amp;lt;/tt&amp;gt; built into your kernel, you can add this in the kernel boot options (ie. in grub's menu.lst):&lt;br /&gt;
&lt;br /&gt;
 usbcore.autosuspend=1&lt;br /&gt;
&lt;br /&gt;
or at runtime, per device, with:&lt;br /&gt;
&lt;br /&gt;
 for i in /sys/bus/usb/devices/*/power/autosuspend; do echo 1 &amp;gt; $i; done &lt;br /&gt;
 for i in /sys/bus/usb/devices/*/power/level; do echo auto &amp;gt; $i; done&lt;br /&gt;
&lt;br /&gt;
USB 1.1 is worst. It needs polling the bus frequently, hence can't really go&lt;br /&gt;
in a low power mode when you enabled it, even if you don't have any device&lt;br /&gt;
plugged. You'd better remove it when you don't use a 1.1 device:&lt;br /&gt;
&lt;br /&gt;
 rmmod uhci_hcd&lt;br /&gt;
&lt;br /&gt;
If you don't intend to use any device needing USB 1.1 (unfortunately, the built-in bluetooth and fingerprint-reader are USB 1.1 devices), the USB 1.1 support can also be totally avoided. On Debian and derivatives, just do:&lt;br /&gt;
&lt;br /&gt;
 echo &amp;quot;blacklist uhci_hcd&amp;quot; &amp;gt;&amp;gt; /etc/modprobe.d/blacklist&lt;br /&gt;
&lt;br /&gt;
==PCMCIA/CardBus==&lt;br /&gt;
Same for PCMCIA/CardBus. Some users experiences interrupts clouds (sometime up to &lt;br /&gt;
several thousands interrupts/second) causing CPU wakeups, thus totally preventing &lt;br /&gt;
the CPU to reach lower C-states. &lt;br /&gt;
If you don't use PCMCIA, you may disable it the same way (unloading seems insufficient&lt;br /&gt;
to restore the system properly, you have to boot without it):&lt;br /&gt;
&lt;br /&gt;
 echo &amp;quot;blacklist pcmcia&amp;quot; &amp;gt;&amp;gt; /etc/modprobe.d/blacklist&lt;br /&gt;
 echo &amp;quot;blacklist yenta_socket&amp;quot; &amp;gt;&amp;gt; /etc/modprobe.d/blacklist&lt;br /&gt;
&lt;br /&gt;
==Sound==&lt;br /&gt;
&lt;br /&gt;
ALSA has a power saving feature that should be enabled on your kernel&lt;br /&gt;
(CONFIG_SND_AC97_POWER_SAVE). Note that this low power mode won't trigger in&lt;br /&gt;
unless you muted all sound inputs (micro, line in etc.). This feature has&lt;br /&gt;
to be activated with:&lt;br /&gt;
&lt;br /&gt;
 amixer set Line mute nocap&lt;br /&gt;
 amixer set Mic mute nocap&lt;br /&gt;
 echo Y &amp;gt; /sys/module/snd_ac97_codec/parameters/power_save&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Intel HD Audio===&lt;br /&gt;
&lt;br /&gt;
If you have Intel HD audio as your onboard sound controller, substitute the following for the last line in the above sequence:&lt;br /&gt;
&lt;br /&gt;
echo Y &amp;gt; /sys/module/snd_hda_intel/parameters/power_save_controller&lt;br /&gt;
&lt;br /&gt;
You also may wish to decrease the sound poweroff timeout to something shorter, like 1 second after last playback:&lt;br /&gt;
&lt;br /&gt;
echo 1 &amp;gt; /sys/module/snd_hda_intel/parameters/power_save&lt;br /&gt;
&lt;br /&gt;
===Additional Tweaks===&lt;br /&gt;
&lt;br /&gt;
You can unload all sound related modules when you are on &lt;br /&gt;
battery, or mute the sound system (echo mute &amp;gt; /proc/acpi/ibm/volume).&lt;br /&gt;
&lt;br /&gt;
See also [[How to enable audio codec power saving]].&lt;br /&gt;
&lt;br /&gt;
==Wireless Interface==&lt;br /&gt;
===intel wireless===&lt;br /&gt;
Wireless network consume a lot of power.&lt;br /&gt;
To save power, you can kill the Wi-Fi radio when it's not in use:&lt;br /&gt;
&lt;br /&gt;
 echo 1 &amp;gt; /sys/bus/pci/devices/*/rf_kill&lt;br /&gt;
&lt;br /&gt;
If you need Wi-Fi, you can also reduce power consumption (at the price of&lt;br /&gt;
performances) by activating the power saving modes:&lt;br /&gt;
&lt;br /&gt;
 iwpriv wlan0 set_power 5&lt;br /&gt;
&lt;br /&gt;
For drivers using the new Wi-Fi kernel framework (mac80211/cfg80211), &lt;br /&gt;
the canonical way to do this is now:&lt;br /&gt;
&lt;br /&gt;
 for i in /sys/bus/pci/devices/*/power_level ; do echo 5 &amp;gt; $i ; done&lt;br /&gt;
&lt;br /&gt;
Most drivers, like ipw2200, that don't use the new mac80211 framework place the&lt;br /&gt;
interfaces in aggressive scanning mode when they are not associated with any &lt;br /&gt;
Access Point, even when the interface is down (more info about this on Intel's&lt;br /&gt;
[http://www.lesswatts.org/tips/wireless.php LessWatts] website).&lt;br /&gt;
This behavior consumes a lot of power, even more than when the interface&lt;br /&gt;
is plain active and in use. But this can disabled at module's load time :&lt;br /&gt;
&lt;br /&gt;
 rmmod ipw2200&lt;br /&gt;
 modprobe ipw2200 associate=0&lt;br /&gt;
&lt;br /&gt;
You can fix this setting by placing the following in /etc/modprobe.d/options &lt;br /&gt;
(Debian/Ubuntu) or in /etc/modprobe.conf (Red Hat/Fedora):&lt;br /&gt;
&lt;br /&gt;
 options ipw2200 associate=0&lt;br /&gt;
&lt;br /&gt;
Reducing beacon intervals on your Access Point to 1 per second will also&lt;br /&gt;
reduce network card interrupts, therefore power savings. This shouldn't have&lt;br /&gt;
negatives side effects.&lt;br /&gt;
&lt;br /&gt;
In recent kernels, the powersaving on the intel ipw3945 has been disabled, as&lt;br /&gt;
for some it is unstable. For others it worked just fine.&lt;br /&gt;
&lt;br /&gt;
See [http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.33.y.git;a=blobdiff;f=drivers/net/wireless/iwlwifi/iwl-3945.c;h=e413bd35bc411a1113177f1576538eb0ac26f00c;hp=4609323d8436dc9e22c74be2f1f3cf5e97785cb2;hb=bc45a67079c916a9bd0a95b0b879cc0f259bac6e;hpb=b7bb1756cb6a610cdbac8cfdad9e79bb5670b63b this patch]. You may wish to try changing '.broken_powersave=true' to false, in /usr/src/linux/drivers/net/wireless/iwlwifi/iwl-3945.c if you wish to enable powersave.&lt;br /&gt;
&lt;br /&gt;
See also, to activate power saving on the wireless network card:&lt;br /&gt;
* For [[Intel PRO/Wireless 2200BG Mini-PCI Adapter]] and [[Intel PRO/Wireless 2915ABG Mini-PCI Adapter]], see instructions for the [[ipw2200]] driver.&lt;br /&gt;
* For [[Intel PRO/Wireless 3945ABG Mini-PCI Express Adapter]], see the [http://ipw3945.sourceforge.net/README.ipw3945 ipw3945 driver README]&lt;br /&gt;
&lt;br /&gt;
==Ethernet Controler==&lt;br /&gt;
If you don't use Wake-on-LAN, you should disable it for your network card,&lt;br /&gt;
because it sucks a lot of power:&lt;br /&gt;
&lt;br /&gt;
 ethtool -s eth0 wol d&lt;br /&gt;
&lt;br /&gt;
If you can, try to reduce useless network activity on your ethernet&lt;br /&gt;
segment, coming to your NIC (ie. uneeded broadcasts), those cause &lt;br /&gt;
interrupts and CPU wakeups.&lt;br /&gt;
&lt;br /&gt;
Forcing 100Mbps full-duplex speed on a gigabit ethernet NIC can also save a lot of power (~1W) on most network workloads. This also reduces component temperatures (e.g., [[Thermal Sensors|thermal sensor]] 0xC0 on the {{T43}} cools down by 5 degrees between 1000Mbps and 100Mbps, and another 1 degree for 10Mbps).&lt;br /&gt;
&lt;br /&gt;
  ethtool -s eth0 autoneg off speed 100&lt;br /&gt;
&lt;br /&gt;
Note, however, that if the network device on the other side has auto-negotiation enabled (which is almost guaranteed) and you turn auto-negotiation off, the other side will assume half-duplex mode and you will experience a significant loss of performance.&lt;br /&gt;
&lt;br /&gt;
==Bluetooth==&lt;br /&gt;
When you don't need bluetooth, disable it. Because of its radio, &lt;br /&gt;
bluetooth is not power friendly.&lt;br /&gt;
&lt;br /&gt;
 hciconfig hci0 down ; rmmod hci_usb&lt;br /&gt;
 echo disable &amp;gt; /proc/acpi/ibm/bluetooth&lt;br /&gt;
&lt;br /&gt;
==Modem==&lt;br /&gt;
When was the last time you used your analog modem? If you can't remember, you probably just don't need it. If it is on a separate module in your laptop, simply remove it. Store it in a ESD safe place (like the bag in which your last addon card or hard drive was packed), in case you should need it again. This won't save you a lot of power and weight, but why carry something around you never use.&lt;br /&gt;
&lt;br /&gt;
==System Fans==&lt;br /&gt;
Fans consumes power when running, so you may look at the [[ACPI fan control script]].&lt;br /&gt;
&lt;br /&gt;
==Misbehaving Userland==&lt;br /&gt;
You should avoid using Beagle, Compiz, Beryl, XMMS, gnome-power-manager&lt;br /&gt;
and Evolution while on battery.&lt;br /&gt;
Look at the PowerTOP's [http://www.linuxpowertop.org/known.php known problems]&lt;br /&gt;
list.&lt;br /&gt;
&lt;br /&gt;
Deactivate desktop animations (blinking cursor on the terms, animated wallpapers, ...): they cause regular X (therefore kernel and CPU) wakeups.&lt;br /&gt;
&lt;br /&gt;
In short, while on battery, you should stop all applications that don't really stay idle when you're not using them. This means applications that:&lt;br /&gt;
* Wakes up the CPU too often (by polling something, because of too short select() timeouts, ...)&lt;br /&gt;
* Access the disks at regular intervals&lt;br /&gt;
* Access an hardware bus (USB, ATA, ...) at regular intervals&lt;br /&gt;
To find those offenders run:&lt;br /&gt;
* &amp;lt;code&amp;gt;strace -p $(pidof yourapp)&amp;lt;/code&amp;gt; # for all your running applications&lt;br /&gt;
* &amp;lt;code&amp;gt;powertop&amp;lt;/code&amp;gt;&lt;br /&gt;
* &amp;lt;code&amp;gt;dstat -t -c --power --top-cpu --top-io --top-bio --top-latency --top-cputime&amp;lt;/code&amp;gt;&lt;br /&gt;
* &amp;lt;code&amp;gt;sysctl vm.block_dump=1&amp;lt;/code&amp;gt; # and look at dmesg&lt;br /&gt;
* &amp;lt;code&amp;gt;ps aux | awk '{print$10,$11}' | sort -n&amp;lt;/code&amp;gt; # will list all running softs sorted by used cpu time&lt;br /&gt;
Please consider filling a bug if you identify such misbehaving software.&lt;br /&gt;
{{NOTE|Not all software is evil, buggy or badly written. Some produce regular activity as it is required to provide the intended functionality.  Think twice before filling bugs about this.}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
* [[How to measure power consumption]]&lt;br /&gt;
* [[Script for monitoring power consumption]]&lt;br /&gt;
* Battery [[maintenance]]&lt;br /&gt;
&lt;br /&gt;
==External resources==&lt;br /&gt;
* [http://www.free-it.de/archiv/talks_2005/paper-11017/paper-11017.html ''Current trends in Linux Kernel Power Management''], Dominik Brodowski, 2005&lt;br /&gt;
* [http://www.linuxpowertop.org PowerTOP] website&lt;br /&gt;
* [http://www.gentoo.org/doc/en/power-management-guide.xml Power Management Guide] from the Gentoo Linux documentation&lt;br /&gt;
* [http://mailman.linux-thinkpad.org/pipermail/linux-thinkpad/2005-November/030478.html When/where/what for low power consumption?] (thread on Linux-Thinkpad)&lt;br /&gt;
* Intel's [http://www.lesswatts.org/ LessWatts] &amp;quot;''Saving power on Linux''&amp;quot; website&lt;br /&gt;
* ''8 hours of battery life on your lap(top)'' ([http://atrey.karlin.mff.cuni.cz/~pavel/swsusp/8hours.odp ODP]/[http://atrey.karlin.mff.cuni.cz/~pavel/swsusp/8hours.pdf PDF]), a presentation by Pavel Machek&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:600X]] [[Category:A20m]] [[Category:A20p]] [[Category:A21e]] [[Category:A21m]] [[Category:A21p]] [[Category:A22e]] [[Category:A22m]] [[Category:A22p]] [[Category:A30]] [[Category:A30p]] [[Category:A31]] [[Category:A31p]] [[Category:i1200]] [[Category:i1300]] [[Category:i1620]] [[Category:G40]] [[Category:G41]] [[Category:R30]] [[Category:R31]] [[Category:R32]] [[Category:R40]] [[Category:R40e]] [[Category:R50]] [[Category:R50e]] [[Category:R50p]] [[Category:R51]] [[Category:R52]] [[Category:R60]] [[Category:R60e]] [[Category:T20]] [[Category:T21]] [[Category:T22]] [[Category:T23]] [[Category:T30]] [[Category:T40]] [[Category:T40p]] [[Category:T41]] [[Category:T41p]] [[Category:T42]] [[Category:T42p]] [[Category:T43]] [[Category:T43p]] [[Category:T60]] [[Category:T60p]] [[Category:T61]] [[Category:X20]] [[Category:X21]] [[Category:X22]] [[Category:X23]] [[Category:X24]] [[Category:X30]] [[Category:X31]] [[Category:X32]] [[Category:X40]] [[Category:X41]] [[Category:X41 Tablet]] [[Category:X60]] [[Category:X60s]] [[Category:X61]] [[Category:X61s]]  [[Category:Z60m]] [[Category:Z60t]] [[Category:Z61t]] [[Category:Z61e]] [[Category:TransNote]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Maintenance&amp;diff=62682</id>
		<title>Maintenance</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Maintenance&amp;diff=62682"/>
		<updated>2025-10-09T02:44:23Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Added hinge lubrication instructions.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top;padding-right:20px;width:10px;white-space:nowrap;&amp;quot; | __TOC__&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
Here you can find general hints about keeping your ThinkPad in good shape. Look at your [[:Category:Models|models category page]] for IBMs official maintenance guide for that model.&lt;br /&gt;
|}&lt;br /&gt;
==Assembly/Disassembly instructions==&lt;br /&gt;
Lenovo has a website dedicated to servicing ThinkPads, but it only covers the more recent models. For older models check the HMM (Hardware Maintenance Manual) for your ThinkPad.&lt;br /&gt;
* http://www.lenovoservicetraining.com/&lt;br /&gt;
&lt;br /&gt;
==Battery treatment==&lt;br /&gt;
{| border=1 cellspacing=0 cellpadding=2 style=&amp;quot;vertical-align:top;&amp;quot;&lt;br /&gt;
|+Battery life expanding guide&lt;br /&gt;
|- style=&amp;quot;background:#efefef;white-space:nowrap;&amp;quot;&lt;br /&gt;
! style=&amp;quot;background:#ffdead;&amp;quot; | Battery Type !! NiCd !! NiMH !! Lithium ion&lt;br /&gt;
|- style=&amp;quot;vertical-align:top;&amp;quot;&lt;br /&gt;
! style=&amp;quot;background:#ffdead;&amp;quot; | General&lt;br /&gt;
|&lt;br /&gt;
*always do complete discharge/charge cycles&lt;br /&gt;
*avoid exposing the battery (or notebook) to excessive heat&lt;br /&gt;
|&lt;br /&gt;
*always do complete discharge/charge cycles&lt;br /&gt;
*avoid exposing the battery (or notebook) to excessive heat&lt;br /&gt;
|&lt;br /&gt;
*avoid deep discharges except when resetting fuel gauge or reconditioning a battery;  partial dis-/recharges are better for the battery lifetime (note: fuel gauge will slowly get inaccurate over time)&lt;br /&gt;
*remove battery when on AC (due to heat)&lt;br /&gt;
*avoid exposing the battery (or notebook) to excessive heat&lt;br /&gt;
|- style=&amp;quot;vertical-align:top;&amp;quot;&lt;br /&gt;
! style=&amp;quot;background:#ffdead;&amp;quot; | Charging&lt;br /&gt;
|&lt;br /&gt;
*discharge before charging&lt;br /&gt;
|&lt;br /&gt;
*discharge before charging&lt;br /&gt;
|&lt;br /&gt;
*avoid charging if battery is nearly full, unless you will need its full capacity soon; keep it on the 30%-85% charged range&lt;br /&gt;
*keep notebook off while charging due to heat&lt;br /&gt;
*fully discharge, then fully charge battery when needed to recalibrate fuel gauge;  newer battery pack models require this less often, old ones might need it as often as every 30 cycles&lt;br /&gt;
|- style=&amp;quot;vertical-align:top;&amp;quot;&lt;br /&gt;
! style=&amp;quot;background:#ffdead;&amp;quot; | Storage&lt;br /&gt;
| &lt;br /&gt;
*almost discharged&lt;br /&gt;
*cool and dry&lt;br /&gt;
|&lt;br /&gt;
*almost discharged&lt;br /&gt;
*cool and dry&lt;br /&gt;
|&lt;br /&gt;
*never fully charged or discharged, ideally at about 40%&lt;br /&gt;
*cool and dry, but '''do not freeze''' them: 10-15C is recommended&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Battery health===&lt;br /&gt;
Batteries, especially of the modern Li-Ion type, wear out quicker when they hold a large charge or are subject to higher temperatures (see above).&lt;br /&gt;
&lt;br /&gt;
If you use your laptop at a desk, reduce battery wear by maintaining an appropriate charge level.  When  possible, remove Li-ion batteries while operating from AC as the notebook gets hot enough inside for that to damage the battery in the long run, even if charging is stopped.&lt;br /&gt;
&lt;br /&gt;
On recent ThinkPads, charging thresholds can be configured in the bundled software.  Under Linux, this is supported on recent models by the [[tp_smapi]] driver (and even without &amp;lt;tt&amp;gt;tp_smapi&amp;lt;/tt&amp;gt;, if you have a dual-boot setup, you can set the thresholds under Windows and they will be remembered as long as you don't power off your machine with AC disconnected; suspend to RAM is OK). Have a look at [[How to use UltraBay batteries]].&lt;br /&gt;
&lt;br /&gt;
If you have spare Li-ion battery packs, store them at 40% charge in a cool place (15C being a recommended temperature, do not let the batteries freeze).  If storing inside a refrigerator, beware of humidity, and be careful with cold spots that can easily freeze the battery if anything goes wrong.&lt;br /&gt;
&lt;br /&gt;
===The problem with 600 series batteries===&lt;br /&gt;
ThinkPad 600 power management causes batteries to die before they should. Read more about this on the [[Problem with ThinkPad 600 batteries|associated problem page]].&lt;br /&gt;
&lt;br /&gt;
===Reviving batteries===&lt;br /&gt;
Some people experience sudden drops in their batteries capacity.  A way to get these batteries back to full capacity is to run the &amp;quot;Battery Rundown&amp;quot; function of IBMs &amp;quot;PC Doctor for DOS&amp;quot;.  The program is downloadable from IBMs support site as three floppy disk images.  Make sure you get the specific version of program made for your ThinkPad model.  For those who do not have a floppy, David Smith prepared a [http://www.mypchelp.com/~dsmith/ibmutil/ibm_t22_pcdiag.iso bootable CD image] (dead link, a copy is also available [http://server6.org/~marker/software/ibm_t22_pcdiag.iso here]) from the T22 floppy images. For newer ThinkPads there is an official [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-56222 bootable CD image]. (Although the instructions on this page (as of May 2008) include details for Linux and refer to a CD image, it is actually provided as a Windows executable. On Linux systems, [http://winehq.org Wine] can execute this file and extract the CD image.) Once extracted, you must mount the iso as a loop device (as root) like so:&lt;br /&gt;
&lt;br /&gt;
:{{cmdroot|mount -o loop 1ety48ww.iso /mnt/floppy}}&lt;br /&gt;
&lt;br /&gt;
Then copy the .IMA file out of that mounted iso:&lt;br /&gt;
&lt;br /&gt;
:{{cmdroot|cd /mnt/floppy}}&lt;br /&gt;
:{{cmdroot|cp 1ETY48WW.IMA /boot}}&lt;br /&gt;
&lt;br /&gt;
(Or to some other suitable directory.) After this, you can follow the same directions that apply for [[BIOS Upgrade|BIOS upgrade]]s.&lt;br /&gt;
&lt;br /&gt;
{{NOTE|This will do nothing to improve the performance of a dying battery. It serves only to recalibrate the battery charge controller. The &amp;quot;Battery Rundown&amp;quot; function of IBMs &amp;quot;PC Doctor for DOS&amp;quot; has no intelligence. It merely runs a series of dumb operations to consume battery power, and it cannot detect whether a battery is present or not. If you leave the mains connected while running &amp;quot;Battery Rundown&amp;quot;, it will have no effect, as the battery will simply keep charging. The [[tp_smapi]] module, if installed, will report the number of charge cycles the battery has had since it was manufactured. If that number is high, the battery's poor performance is almost certainly due to its age.}}&lt;br /&gt;
&lt;br /&gt;
I have recently made an interesting discovery, I have an R40 with two main batteries, both of them have aproximately about under 200 cycles and are nowadays 4 years old, projected capacity for R40/R32 main battery is 57Wh, and both my batteries were about 30Wh, then I left my notebook with one of them about a day in a standby mode, as long as it powered off itself because of low battery power, when I turned it on I saw the battery capacity at about 42Wh, then, I did this too for the second battery and I got even about 46Wh, I think I could go even higher with letting the battery discharge completely from 100% in standby, I think this has something to do with low power consumption in standby mode, it may work for you too.&lt;br /&gt;
&lt;br /&gt;
===See also===&lt;br /&gt;
* [[Battery safety]]&lt;br /&gt;
&lt;br /&gt;
===External sources===&lt;br /&gt;
* [http://www-307.ibm.com/pc/support/site.wss/document.do?lndocid=PFAN-3QNQJN IBM Support - Extending battery life]&lt;br /&gt;
* [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=ibm&amp;amp;lndocid=MIGR-51038 IBM Support - Battery troubleshooting]&lt;br /&gt;
* [http://www.pc.ibm.com/ww/thinkpad/batterylife/ IBM Benchmark]&lt;br /&gt;
* [http://batteryuniversity.com Battery University]&lt;br /&gt;
* [http://www.batteryuniversity.com/parttwo-34.htm Battery University's info about prolonging lithium ion batteries]&lt;br /&gt;
* [http://www.buchmann.ca/Chap10-page6.asp prolonging lithium ion batteries in Buchmanns Battery FAQ]&lt;br /&gt;
* [http://www.electronics-lab.com/articles/Li_Ion_reconstruct Electronics Labs information about lithium ion batteries]&lt;br /&gt;
&lt;br /&gt;
==Cleaning the Display==&lt;br /&gt;
If you discover markings that look like they originate from the TrackPoint or keyboard, or for information on how to avoid these, look at [[Problem with key and trackpoint markings on the display|this page]].&lt;br /&gt;
&lt;br /&gt;
===External Sources===&lt;br /&gt;
* [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-4A2P54 Lenovo Support - LCD care and cleaning instructions]&lt;br /&gt;
* [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-52190 Lenovo Support - System cleaning instructions]&lt;br /&gt;
&lt;br /&gt;
==Cleaning the Interior==&lt;br /&gt;
{{WARN|The following instructions are not appropriate for all ThinkPad models. Please consult the hardware maintenance guide or on-line disassembly instructions for your model.}}&lt;br /&gt;
Most ThinkPad models (particularly the A-series and the T-series) tend to accumulate a lot of interior dust which they draw from their ventilation fan.  A good dusting every few months is advised. The procedure is as follows.&lt;br /&gt;
&lt;br /&gt;
===ThinkPad T4x series===&lt;br /&gt;
See IBM's keyboard removal [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-46515 instructions] and [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-50227 movie].&lt;br /&gt;
&lt;br /&gt;
===ThinkPad T6x series===&lt;br /&gt;
See IBM's keyboard removal&lt;br /&gt;
[http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-62800 instructions] and&lt;br /&gt;
[http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-63912 movie].&lt;br /&gt;
&lt;br /&gt;
===Other models (which?)===&lt;br /&gt;
#Unplug the computer.&lt;br /&gt;
#Remove the battery.&lt;br /&gt;
#Turn the ThinkPad over and find two to three screws with upraised double-arrows pointing to them.&lt;br /&gt;
#Unscrew these screws and set them aside.&lt;br /&gt;
#Press the silver area underneath where the battery used to be.  The front of the keyboard will pop up.&lt;br /&gt;
#Turn the ThinkPad right side up and gently remove the keyboard, pulling it toward you.&lt;br /&gt;
#There is one connector between the ThinkPad and the keyboard.  Disconnect it, and set the keyboard aside.&lt;br /&gt;
#If there is a small black plastic separator under the keyboard, remove it and set it aside.&lt;br /&gt;
#The fan should be visible in the upper left.  That entire area will likely be dusty.  With a can of compressed air (and ''only'' with a can of compressed air), dust that area and the surrounding area.&lt;br /&gt;
#Replace the small black plastic separator, then reconnect the keyboard.&lt;br /&gt;
#Slide the keyboard back into place, then press down on the Fn and right-arrow keys until it pops into place.&lt;br /&gt;
#Replace the keyboard screws and battery.&lt;br /&gt;
&lt;br /&gt;
==Dealing with spilling accidents==&lt;br /&gt;
#Don't panic.&lt;br /&gt;
#Don't flip or tilt the computer to prevent the liquid from spreading all over the inside of the case.&lt;br /&gt;
#Shut down the OS and turn off the power:&lt;br /&gt;
##Unplug the computer.&lt;br /&gt;
##Remove the battery.&lt;br /&gt;
#Tilt the computer so that everything that leaked into the case can flow out the same way.&lt;br /&gt;
#Allow the computer to dry before switching it on again.&lt;br /&gt;
#For minor accidents this might already be sufficient. For major flooding you should either bring the computer to a dealer who knows how to open and clean it from inside. Or you can read the Hardware Maintenance Manual, open, clean, and dry the computer yourself. &lt;br /&gt;
&lt;br /&gt;
See also [http://www.moneysense.ca/spending/technology/columnist.jsp?content=986628 Act quickly, carefully if you spill on laptops] on MoneySense.ca (link broken as of 2006-09-18, the article is still available via [http://web.archive.org/web/20050221034011/http://www.moneysense.ca/spending/technology/columnist.jsp?content=986628 web.archive.org]).&lt;br /&gt;
&lt;br /&gt;
==Fan Lubrication==&lt;br /&gt;
Older ThinkPads, like the Core/Core 2 Duo line can have issues with the bearing lubrication drying out, resulting in the fan rattling without spinning and only spinning slowly at 100% fanspeed. Even if the fan is working fine at the moment, the lubrication may fail in a few years, thus it is recommended that fan lubrication is done as well if you ever deassemble such ThinkPads for repasting or GNUbooting;&lt;br /&gt;
* Unscrew heatsink+fan housing and carefully deassemble, removing screws and tape and moving wiring as needed - avoid bending the housing, otherwise the fan will rattle until it is bent back.&lt;br /&gt;
* Pull out the magnet-retained fan blades and clean the dust from the blades and housing (it's easiest to wash the blades in water - but complete drying with paper towel etc will be required afterwards).&lt;br /&gt;
* Put a drop of 3-in-1 or sewing machine oil into the motor bearing and re-insert the fan - it should spin freely if manually spun a bit (if gunk near or in the bearing, oil, use paper towel to remove it, then re-oil).&lt;br /&gt;
* Reinstall housing - old tape can be replaced with any moderately heat-resistant tape, like rubber electrical tape (the temperature shouldn't ever exceed 60°C, but to avoid melted or burning plastic, tape with heat resistance of at least 105°C should be used).&lt;br /&gt;
&lt;br /&gt;
==Hinge Lubrication==&lt;br /&gt;
Older ThinkPads, like the Core/Core 2 Duo line can develop very stiff hinges as the lubrication dries out, requiring excessive force to move the screen, which can lead to the screen mount breaking off. Lubricating the hinges fixes the problem;&lt;br /&gt;
* Deassemble the ThinkPad, removing/unplugging the keyboard, top cover, LCD connector, Wi-Fi antenna and screen screws so you can remove the screen assembly (moving the screen to the 90° position, so the hinges are 180° on removal is recommended).&lt;br /&gt;
* Take off the black screen screw covers with your fingernails or a plastic tool and unscrew the screen cover screws and gently unclip the screen cover all around until it comes off (very difficult to do without cosmetic damage).&lt;br /&gt;
* Unscrew the hinges and take them out (the antennas may need to be unscrewed and the screen may need to be partially pulled out before the hinges can be unscrewed and removed - if there is a webcam, unplug it, or be extremely gentle when manipulating the screen, otherwise the ribbon cable will tear).&lt;br /&gt;
* Place the bottom end of the hinge into a vice with the insertion side of the hinge joint facing up (the other end usually has a tiny circlip on it).&lt;br /&gt;
* Place 3-in-1 or sewing machine oil onto the joint and move the hinge back and forth with pliers to work oil into the joint - add more oil and work it into the joint until the hinge is no longer excessively stiff (the hinges need to be quite stiff, otherwise the screen will flop around).&lt;br /&gt;
* Clean off excess oil external to the joint and oil the other hinge - both hinges should have similar stiffness to avoid uneven forces.&lt;br /&gt;
* Reassemble the screen assembly - a glue stick of paper glue is good for re-attaching the screen screw covers, while also ensuring those can be easily removed later.&lt;br /&gt;
* On re-insertation into the base, the screen should move with a reasonable amount of force.&lt;br /&gt;
&lt;br /&gt;
==Harddisk Backup / Upgrade==&lt;br /&gt;
*[[How to copy a Linux installation]]&lt;br /&gt;
*[[Harddrive Upgrade|How to upgrade your Thinkpad hard drive]]&lt;br /&gt;
*[[How to copy a Windows installation]]&lt;br /&gt;
===External Sources===&lt;br /&gt;
*[http://gamma.nic.fi/~point/win2copy.htm Guide on copying Windows 2000/XP to another partition]&lt;br /&gt;
&lt;br /&gt;
==Recovering BIOS passwords.==&lt;br /&gt;
Password recovery procedure for IBM ThinkPads using R24RF08 and IBMpass.&lt;br /&gt;
&lt;br /&gt;
(Note: An updated tutorial can always be found [http://www.allservice.ro/forum/viewtopic.php?t=47&amp;amp;start=0 HERE])&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''1. Introduction.'''&lt;br /&gt;
&lt;br /&gt;
The IBM ThinkPad uses a small eeprom ([[AT24RF08|ATMEL 24RF08]]) to store different OEM&lt;br /&gt;
issues like serial number, UUID, etc. The supervisor password (SVP) is also stored in this eeprom.&lt;br /&gt;
The 24RF08 is not an ordinary eeprom: it features read protection, which the BIOS uses to lock down&lt;br /&gt;
access to the eeprom contents.  Also, the password is written in a special scan code, which needs to&lt;br /&gt;
be translated to ASCII to be of any use.&lt;br /&gt;
&lt;br /&gt;
To recover the password, one can use two different programs: R24RF08 (eeprom reader) and IBMpass&lt;br /&gt;
(password revealer) available at [http://www.allservice.ro/store/utils http://www.allservice.ro/store/utils]. Diagrams are included in the reader kit.&lt;br /&gt;
&lt;br /&gt;
Models for which R24RF08 and IBMpass are enough to recover the password: 240, 240X, 390E, 390X, 570, 570E,&lt;br /&gt;
600e, 600X, 770Z, A20m, A21e, A21m, a22m, A30, A30p, A31, A31p, G40, G41, R30, R31, R32, R40, R50, R51, &lt;br /&gt;
Transnote, T20, T21, T22, T23, T30, T40, T40p, T41, T41p, T42, T42p, X20, X21, X22, X23, X24, X30, X31, X40, X41, X61.&lt;br /&gt;
&lt;br /&gt;
ThinkPads featuring TPCA technology (i.e. a [[Tpm|TPM trusted platform module chip]]), especially T4x, X3x, X4x, X61 and X61T need the W24RF08 eeprom writer program to complete the password recovery procedure, if the passphrase function is enabled in BIOS setup.&lt;br /&gt;
&lt;br /&gt;
Other models such as the 380XD or 600 use 24C01 or 93C46 eeproms, which can be read without special tools.&lt;br /&gt;
The method is the same like for the models based on 24RF08, only the software to dump the eeprom is different. &lt;br /&gt;
&lt;br /&gt;
Newer T43/T43p, R52, R60, T60/p, X60 and Z60 ThinkPads can be unlocked using PC8394 programming tools that consist in RPC8394 and WPC8394 (reader and writer for TPM chips). &lt;br /&gt;
The software is available as well at [http://www.allservice.ro/forum/viewtopic.php?p=1061#1061 www.allservice.ro]. IBMpass 2.0 works for any TP model without exceptions.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''2. Locating the ATMEL 24RF08 eeprom. Soldering.'''&lt;br /&gt;
&lt;br /&gt;
No need to unsolder the 24RF08 eeprom, just solder 3 wires to SDA, SCL and GND pins of the&lt;br /&gt;
eeprom. There are two eeprom layouts (see interface schematics described bellow), corresponding to 8 pin or 14 pin eeproms. Locate the eeprom first according to your model (E.g. T20-23 and T30 have the eeprom underneath TP, and can be accessed by removing the RAM modules cover, no need to dismantle the laptop.) and solder the wires using a soldering iron with a fine tip. Also, you can use 0.15 -0.20 mm enamel coated wires or similar small diameter insulated wires. These wires will be connected later to the interface.&lt;br /&gt;
Tip: You can use clips to connect the wires or you can solder on the PCB traces leading to the&lt;br /&gt;
eeprom pins. Once again, be careful and double, triple check the soldering if necessary till you are positively sure you have done the right job. In case of applying too much solder, use flux-impregnated copper-braid &amp;quot;desoldering wick&amp;quot; - this works exceptionally well.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''3. Choose and build the interface.'''&lt;br /&gt;
&lt;br /&gt;
Since version 2.0, R24RF08 and W24RF08 (eeprom writer) are compatible with a wide range of eeprom programmers. By default, both programs set the COM port signals to use direct logic level to access I2C bus. We provide here 2 schematics that are relevant for direct logic signals and for inverse logic signals (simple-i2cprog.pdf and driven-i2cprog.pdf). Also, depending of the interface you build, you can invert the logics for SDA-In, SDA-Out, and SCL COM port signals by some command line parameters described later in this document.&lt;br /&gt;
a) The file simple-i2cprog.pdf contains the schematic diagram of a simple interface (known as SIPROG)based on 2 zeners and 2 resistors. This is a classic, easy to build circuit and works with soldered or unsoldered eeproms. The purpose of the 2 zeners is to convert RS232 levels (+/- 5V) to TTL levels, needed by the eeprom. It uses direct logic signals to I2C eeprom and is powered by the COM port. However, this interface works with in-system eeproms but is dependant on COM port current and eeprom bus impedance. R24RF08 works natively with this circuit, no need to change the lines signals with command line parameters. This circuit works pretty well with almost all ThinkPads series.&lt;br /&gt;
b) The second interface is described in driven-i2cprog.pdf. The circuit uses MAX 232 as a RS232 to TTL driver and its main purpose is to work with soldered eeproms. The advantage of MAX232 is the TTL outputs that are more reliable and more powerful when work with soldered, in-system eeproms (dependency free from the COM port current). Due of the internal inverters of MAX232 the interface responds to an inverse signal logic level. R24RF08 needs /x, /d, /i switches to be specified in the command line.&lt;br /&gt;
&lt;br /&gt;
What these switches mean:&lt;br /&gt;
/x - invert serial clock, also known as SCL;&lt;br /&gt;
/d - invert serial data output, also known as SDA-Out;&lt;br /&gt;
/i - invert serial data input, also known as SDA-In.&lt;br /&gt;
All those can be used in any combination to meet any interface specification.&lt;br /&gt;
&lt;br /&gt;
Note that the &amp;quot;standard&amp;quot; serial port programmer probably won't work with a USB-Serial adapter, but requires the full nominal voltage of a hardware serial port. [Example: the A22p's serial port works fine here.]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''4. Dump the EEPROM:'''&lt;br /&gt;
&lt;br /&gt;
Prepare your technician PC by connecting the interface to the COM1 port (donâ€™t connect the wires to eeprom yet). Turn on the ThinkPad and press F1 to enter BIOS Setup. When you are prompted for the password and thereâ€™s no other activity like HDD access or so, connect the wires (GND first!, SDA, SCL) to the corresponding wires from the interface (attached before to COM1) and execute R24RF08:&lt;br /&gt;
&lt;br /&gt;
-for SI-PROG interface (as described in 3.a above):&lt;br /&gt;
r24rf08.exe &amp;lt;filename.ext&amp;gt;. where filename.ext is the file where eeprom content will be stored.&lt;br /&gt;
Example: r24rf08 mytp.bin&lt;br /&gt;
&lt;br /&gt;
-for MAX232 driven I2C interface (as described in 3.b above):&lt;br /&gt;
r24rf08.exe &amp;lt;filename.ext&amp;gt; /x /d /i. where /x /d /i are command line parameters (switches) for this kind of interface.&lt;br /&gt;
Example: r24rf08 mytp2.bin /x /d /i&lt;br /&gt;
&lt;br /&gt;
Use exactly the instructed switches to avoid possible damages to your eeprom data!&lt;br /&gt;
The file should be created in the same folder. Finally, disconnect the wires (GND last!) and turn off the ThinkPad by pressing on/off switch.&lt;br /&gt;
&lt;br /&gt;
Dump the EEPROM data at least twice, and do a bytewise compare with `cmp`. Both files should be identical, and 1024 bytes long. Otherwise, you probably have a serial port problem.&lt;br /&gt;
&lt;br /&gt;
Note: the r24rf08.exe program automatically sets the serial port parameters. It also works fine with Wine under Linux - provided that a symlink (com1) exists in the .wine/dos_devices directory, and points to the /dev/ttySX for the actual serial port.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''5. Reveal the password.'''&lt;br /&gt;
&lt;br /&gt;
Now, you have the .bin file but you need to dump in scan code to retrieve the password. IBMpass 2.1 Lite is a free tool that will do the job. Just open the eeprom dump youâ€™ve created before and search for 0x330, 0x340 lines. The password is located on 0x338 (and 0x340 depending on model) in scan code. For 24C01 eeproms the password is located at 0x38, 0x40. If the password won't work for the very first time then your eeprom may use newer IBM scancodes. In this case switch to alternate scan codes to find it. For those who want quick answers the recommended version is IBMpass 1.1. Usage for IBMpass 1.1 (command line only):&lt;br /&gt;
&lt;br /&gt;
ibmpass mytp.bin â€“ use â€œ/aâ€ switch to see in alternate scan code if needed:&lt;br /&gt;
ibmpass mytp.bin /a&lt;br /&gt;
&lt;br /&gt;
For some old models like 570 or 770Z you need to execute the eeprom patcher first. This will reset the read protection on the password offset. To do that just execute patcher.exe before the reading operation, without rebooting the laptop:&lt;br /&gt;
&lt;br /&gt;
-for SI-PROG:&lt;br /&gt;
patcher.exe , then immediately&lt;br /&gt;
r24rf08.exe &amp;lt;filename.ext&amp;gt;&lt;br /&gt;
&lt;br /&gt;
-for Driven-I2C (Max232) you must insert the switches:&lt;br /&gt;
patcher.exe /x /d /i, then immediately&lt;br /&gt;
r24rf08.exe &amp;lt;filename.ext&amp;gt; /x /d /i&lt;br /&gt;
&lt;br /&gt;
W24RF08, the writer version, has included the complete APP reset operation you donâ€™t need to use patcher.&lt;br /&gt;
&lt;br /&gt;
Moreover, there are a new encrypting algos used with some new security chips (AT97SC3201, AT97SC3203) that are very secured. The password is not in scancode and in some cases not even in the eeprom. To unlock the machine, the dump should suffer some changes and the eeprom must be reprogrammed using W24RF08. This operation works for all IBM TCG/TCPA secured laptops w/o exceptions. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Remember, use 3 wires from the interface and 3 wires from eeprom! Connect them after your&lt;br /&gt;
ThinkPad is powered and disconnect them right after you read the content, before you switch off the laptop.&lt;br /&gt;
&lt;br /&gt;
'''6. Password format'''&lt;br /&gt;
&lt;br /&gt;
The thinkpad power-on/supervisor passwords are a maximum of 7 characters, and are NOT case-sensitive. The allowed characters are restricted to A-Z, 0-9, semicolon, _, - (and perhaps a few others).&lt;br /&gt;
If  PassPhrase is enabled then the password can be longer than 7 characters. &lt;br /&gt;
Models like T43/R52/T60/R60/T60/X60/Z60/Z61 need the TPM chip dumped with [http://www.allservice.ro/forum/viewtopic.php?p=1061#1061 PC8394 programming tools] in order to find password/reset the TCPA lock.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===External Sources===&lt;br /&gt;
* [http://www.allservice.ro/forum R24RF08/W24RF08, PC8394 programming tools &amp;amp; IBMpass author's forums]&lt;br /&gt;
* {{IBMDOCURL|MIGR-59377|IBM/Lenovo Support - Lost or forgotten password}}&lt;br /&gt;
* [http://www.allservice.ro/forum/viewforum.php?f=12 Full Service of all ThinkPad models including free password recovery]&lt;br /&gt;
* [http://sodoityourself.com/hacking-ibm-thinkpad-bios-password/ A tutorial on how to do this]&lt;br /&gt;
&lt;br /&gt;
[[Category:HOWTOs]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Maintenance&amp;diff=62681</id>
		<title>Maintenance</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Maintenance&amp;diff=62681"/>
		<updated>2025-10-09T01:59:37Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Added fan lube instructions.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top;padding-right:20px;width:10px;white-space:nowrap;&amp;quot; | __TOC__&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
Here you can find general hints about keeping your ThinkPad in good shape. Look at your [[:Category:Models|models category page]] for IBMs official maintenance guide for that model.&lt;br /&gt;
|}&lt;br /&gt;
==Assembly/Disassembly instructions==&lt;br /&gt;
Lenovo has a website dedicated to servicing ThinkPads, but it only covers the more recent models. For older models check the HMM (Hardware Maintenance Manual) for your ThinkPad.&lt;br /&gt;
* http://www.lenovoservicetraining.com/&lt;br /&gt;
&lt;br /&gt;
==Battery treatment==&lt;br /&gt;
{| border=1 cellspacing=0 cellpadding=2 style=&amp;quot;vertical-align:top;&amp;quot;&lt;br /&gt;
|+Battery life expanding guide&lt;br /&gt;
|- style=&amp;quot;background:#efefef;white-space:nowrap;&amp;quot;&lt;br /&gt;
! style=&amp;quot;background:#ffdead;&amp;quot; | Battery Type !! NiCd !! NiMH !! Lithium ion&lt;br /&gt;
|- style=&amp;quot;vertical-align:top;&amp;quot;&lt;br /&gt;
! style=&amp;quot;background:#ffdead;&amp;quot; | General&lt;br /&gt;
|&lt;br /&gt;
*always do complete discharge/charge cycles&lt;br /&gt;
*avoid exposing the battery (or notebook) to excessive heat&lt;br /&gt;
|&lt;br /&gt;
*always do complete discharge/charge cycles&lt;br /&gt;
*avoid exposing the battery (or notebook) to excessive heat&lt;br /&gt;
|&lt;br /&gt;
*avoid deep discharges except when resetting fuel gauge or reconditioning a battery;  partial dis-/recharges are better for the battery lifetime (note: fuel gauge will slowly get inaccurate over time)&lt;br /&gt;
*remove battery when on AC (due to heat)&lt;br /&gt;
*avoid exposing the battery (or notebook) to excessive heat&lt;br /&gt;
|- style=&amp;quot;vertical-align:top;&amp;quot;&lt;br /&gt;
! style=&amp;quot;background:#ffdead;&amp;quot; | Charging&lt;br /&gt;
|&lt;br /&gt;
*discharge before charging&lt;br /&gt;
|&lt;br /&gt;
*discharge before charging&lt;br /&gt;
|&lt;br /&gt;
*avoid charging if battery is nearly full, unless you will need its full capacity soon; keep it on the 30%-85% charged range&lt;br /&gt;
*keep notebook off while charging due to heat&lt;br /&gt;
*fully discharge, then fully charge battery when needed to recalibrate fuel gauge;  newer battery pack models require this less often, old ones might need it as often as every 30 cycles&lt;br /&gt;
|- style=&amp;quot;vertical-align:top;&amp;quot;&lt;br /&gt;
! style=&amp;quot;background:#ffdead;&amp;quot; | Storage&lt;br /&gt;
| &lt;br /&gt;
*almost discharged&lt;br /&gt;
*cool and dry&lt;br /&gt;
|&lt;br /&gt;
*almost discharged&lt;br /&gt;
*cool and dry&lt;br /&gt;
|&lt;br /&gt;
*never fully charged or discharged, ideally at about 40%&lt;br /&gt;
*cool and dry, but '''do not freeze''' them: 10-15C is recommended&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Battery health===&lt;br /&gt;
Batteries, especially of the modern Li-Ion type, wear out quicker when they hold a large charge or are subject to higher temperatures (see above).&lt;br /&gt;
&lt;br /&gt;
If you use your laptop at a desk, reduce battery wear by maintaining an appropriate charge level.  When  possible, remove Li-ion batteries while operating from AC as the notebook gets hot enough inside for that to damage the battery in the long run, even if charging is stopped.&lt;br /&gt;
&lt;br /&gt;
On recent ThinkPads, charging thresholds can be configured in the bundled software.  Under Linux, this is supported on recent models by the [[tp_smapi]] driver (and even without &amp;lt;tt&amp;gt;tp_smapi&amp;lt;/tt&amp;gt;, if you have a dual-boot setup, you can set the thresholds under Windows and they will be remembered as long as you don't power off your machine with AC disconnected; suspend to RAM is OK). Have a look at [[How to use UltraBay batteries]].&lt;br /&gt;
&lt;br /&gt;
If you have spare Li-ion battery packs, store them at 40% charge in a cool place (15C being a recommended temperature, do not let the batteries freeze).  If storing inside a refrigerator, beware of humidity, and be careful with cold spots that can easily freeze the battery if anything goes wrong.&lt;br /&gt;
&lt;br /&gt;
===The problem with 600 series batteries===&lt;br /&gt;
ThinkPad 600 power management causes batteries to die before they should. Read more about this on the [[Problem with ThinkPad 600 batteries|associated problem page]].&lt;br /&gt;
&lt;br /&gt;
===Reviving batteries===&lt;br /&gt;
Some people experience sudden drops in their batteries capacity.  A way to get these batteries back to full capacity is to run the &amp;quot;Battery Rundown&amp;quot; function of IBMs &amp;quot;PC Doctor for DOS&amp;quot;.  The program is downloadable from IBMs support site as three floppy disk images.  Make sure you get the specific version of program made for your ThinkPad model.  For those who do not have a floppy, David Smith prepared a [http://www.mypchelp.com/~dsmith/ibmutil/ibm_t22_pcdiag.iso bootable CD image] (dead link, a copy is also available [http://server6.org/~marker/software/ibm_t22_pcdiag.iso here]) from the T22 floppy images. For newer ThinkPads there is an official [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-56222 bootable CD image]. (Although the instructions on this page (as of May 2008) include details for Linux and refer to a CD image, it is actually provided as a Windows executable. On Linux systems, [http://winehq.org Wine] can execute this file and extract the CD image.) Once extracted, you must mount the iso as a loop device (as root) like so:&lt;br /&gt;
&lt;br /&gt;
:{{cmdroot|mount -o loop 1ety48ww.iso /mnt/floppy}}&lt;br /&gt;
&lt;br /&gt;
Then copy the .IMA file out of that mounted iso:&lt;br /&gt;
&lt;br /&gt;
:{{cmdroot|cd /mnt/floppy}}&lt;br /&gt;
:{{cmdroot|cp 1ETY48WW.IMA /boot}}&lt;br /&gt;
&lt;br /&gt;
(Or to some other suitable directory.) After this, you can follow the same directions that apply for [[BIOS Upgrade|BIOS upgrade]]s.&lt;br /&gt;
&lt;br /&gt;
{{NOTE|This will do nothing to improve the performance of a dying battery. It serves only to recalibrate the battery charge controller. The &amp;quot;Battery Rundown&amp;quot; function of IBMs &amp;quot;PC Doctor for DOS&amp;quot; has no intelligence. It merely runs a series of dumb operations to consume battery power, and it cannot detect whether a battery is present or not. If you leave the mains connected while running &amp;quot;Battery Rundown&amp;quot;, it will have no effect, as the battery will simply keep charging. The [[tp_smapi]] module, if installed, will report the number of charge cycles the battery has had since it was manufactured. If that number is high, the battery's poor performance is almost certainly due to its age.}}&lt;br /&gt;
&lt;br /&gt;
I have recently made an interesting discovery, I have an R40 with two main batteries, both of them have aproximately about under 200 cycles and are nowadays 4 years old, projected capacity for R40/R32 main battery is 57Wh, and both my batteries were about 30Wh, then I left my notebook with one of them about a day in a standby mode, as long as it powered off itself because of low battery power, when I turned it on I saw the battery capacity at about 42Wh, then, I did this too for the second battery and I got even about 46Wh, I think I could go even higher with letting the battery discharge completely from 100% in standby, I think this has something to do with low power consumption in standby mode, it may work for you too.&lt;br /&gt;
&lt;br /&gt;
===See also===&lt;br /&gt;
* [[Battery safety]]&lt;br /&gt;
&lt;br /&gt;
===External sources===&lt;br /&gt;
* [http://www-307.ibm.com/pc/support/site.wss/document.do?lndocid=PFAN-3QNQJN IBM Support - Extending battery life]&lt;br /&gt;
* [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=ibm&amp;amp;lndocid=MIGR-51038 IBM Support - Battery troubleshooting]&lt;br /&gt;
* [http://www.pc.ibm.com/ww/thinkpad/batterylife/ IBM Benchmark]&lt;br /&gt;
* [http://batteryuniversity.com Battery University]&lt;br /&gt;
* [http://www.batteryuniversity.com/parttwo-34.htm Battery University's info about prolonging lithium ion batteries]&lt;br /&gt;
* [http://www.buchmann.ca/Chap10-page6.asp prolonging lithium ion batteries in Buchmanns Battery FAQ]&lt;br /&gt;
* [http://www.electronics-lab.com/articles/Li_Ion_reconstruct Electronics Labs information about lithium ion batteries]&lt;br /&gt;
&lt;br /&gt;
==Cleaning the Display==&lt;br /&gt;
If you discover markings that look like they originate from the TrackPoint or keyboard, or for information on how to avoid these, look at [[Problem with key and trackpoint markings on the display|this page]].&lt;br /&gt;
&lt;br /&gt;
===External Sources===&lt;br /&gt;
* [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-4A2P54 Lenovo Support - LCD care and cleaning instructions]&lt;br /&gt;
* [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-52190 Lenovo Support - System cleaning instructions]&lt;br /&gt;
&lt;br /&gt;
==Cleaning the Interior==&lt;br /&gt;
{{WARN|The following instructions are not appropriate for all ThinkPad models. Please consult the hardware maintenance guide or on-line disassembly instructions for your model.}}&lt;br /&gt;
Most ThinkPad models (particularly the A-series and the T-series) tend to accumulate a lot of interior dust which they draw from their ventilation fan.  A good dusting every few months is advised. The procedure is as follows.&lt;br /&gt;
&lt;br /&gt;
===ThinkPad T4x series===&lt;br /&gt;
See IBM's keyboard removal [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-46515 instructions] and [http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-50227 movie].&lt;br /&gt;
&lt;br /&gt;
===ThinkPad T6x series===&lt;br /&gt;
See IBM's keyboard removal&lt;br /&gt;
[http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-62800 instructions] and&lt;br /&gt;
[http://www-307.ibm.com/pc/support/site.wss/document.do?sitestyle=lenovo&amp;amp;lndocid=MIGR-63912 movie].&lt;br /&gt;
&lt;br /&gt;
===Other models (which?)===&lt;br /&gt;
#Unplug the computer.&lt;br /&gt;
#Remove the battery.&lt;br /&gt;
#Turn the ThinkPad over and find two to three screws with upraised double-arrows pointing to them.&lt;br /&gt;
#Unscrew these screws and set them aside.&lt;br /&gt;
#Press the silver area underneath where the battery used to be.  The front of the keyboard will pop up.&lt;br /&gt;
#Turn the ThinkPad right side up and gently remove the keyboard, pulling it toward you.&lt;br /&gt;
#There is one connector between the ThinkPad and the keyboard.  Disconnect it, and set the keyboard aside.&lt;br /&gt;
#If there is a small black plastic separator under the keyboard, remove it and set it aside.&lt;br /&gt;
#The fan should be visible in the upper left.  That entire area will likely be dusty.  With a can of compressed air (and ''only'' with a can of compressed air), dust that area and the surrounding area.&lt;br /&gt;
#Replace the small black plastic separator, then reconnect the keyboard.&lt;br /&gt;
#Slide the keyboard back into place, then press down on the Fn and right-arrow keys until it pops into place.&lt;br /&gt;
#Replace the keyboard screws and battery.&lt;br /&gt;
&lt;br /&gt;
==Dealing with spilling accidents==&lt;br /&gt;
#Don't panic.&lt;br /&gt;
#Don't flip or tilt the computer to prevent the liquid from spreading all over the inside of the case.&lt;br /&gt;
#Shut down the OS and turn off the power:&lt;br /&gt;
##Unplug the computer.&lt;br /&gt;
##Remove the battery.&lt;br /&gt;
#Tilt the computer so that everything that leaked into the case can flow out the same way.&lt;br /&gt;
#Allow the computer to dry before switching it on again.&lt;br /&gt;
#For minor accidents this might already be sufficient. For major flooding you should either bring the computer to a dealer who knows how to open and clean it from inside. Or you can read the Hardware Maintenance Manual, open, clean, and dry the computer yourself. &lt;br /&gt;
&lt;br /&gt;
See also [http://www.moneysense.ca/spending/technology/columnist.jsp?content=986628 Act quickly, carefully if you spill on laptops] on MoneySense.ca (link broken as of 2006-09-18, the article is still available via [http://web.archive.org/web/20050221034011/http://www.moneysense.ca/spending/technology/columnist.jsp?content=986628 web.archive.org]).&lt;br /&gt;
&lt;br /&gt;
==Fan Lubrication==&lt;br /&gt;
Older ThinkPads, like the Core/Core 2 Duo line can have issues with the bearing lubrication drying out, resulting in the fan rattling without spinning and only spinning slowly at 100% fanspeed. Even if the fan is working fine at the moment, the lubrication may fail in a few years, thus it is recommended that fan lubrication is done as well if you ever deassemble such ThinkPads for repasting or GNUbooting;&lt;br /&gt;
* Unscrew heatsink+fan housing and carefully deassemble, removing screws and tape and moving wiring as needed - avoid bending the housing, otherwise the fan will rattle until it is bent back.&lt;br /&gt;
* Pull out the magnet-retained fan blades and clean the dust from the blades and housing (it's easiest to wash the blades in water - but complete drying with paper towel etc will be required afterwards).&lt;br /&gt;
* Put a drop of 3-in-1 or sewing machine oil into the motor bearing and re-insert the fan - it should spin freely if manually spun a bit (if gunk near or in the bearing, oil, use paper towel to remove it, then re-oil).&lt;br /&gt;
* Reinstall housing - old tape can be replaced with any moderately heat-resistant tape, like rubber electrical tape (the temperature shouldn't ever exceed 60°C, but to avoid melted or burning plastic, tape with heat resistance of at least 105°C should be used).&lt;br /&gt;
&lt;br /&gt;
==Harddisk Backup / Upgrade==&lt;br /&gt;
*[[How to copy a Linux installation]]&lt;br /&gt;
*[[Harddrive Upgrade|How to upgrade your Thinkpad hard drive]]&lt;br /&gt;
*[[How to copy a Windows installation]]&lt;br /&gt;
===External Sources===&lt;br /&gt;
*[http://gamma.nic.fi/~point/win2copy.htm Guide on copying Windows 2000/XP to another partition]&lt;br /&gt;
&lt;br /&gt;
==Recovering BIOS passwords.==&lt;br /&gt;
Password recovery procedure for IBM ThinkPads using R24RF08 and IBMpass.&lt;br /&gt;
&lt;br /&gt;
(Note: An updated tutorial can always be found [http://www.allservice.ro/forum/viewtopic.php?t=47&amp;amp;start=0 HERE])&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''1. Introduction.'''&lt;br /&gt;
&lt;br /&gt;
The IBM ThinkPad uses a small eeprom ([[AT24RF08|ATMEL 24RF08]]) to store different OEM&lt;br /&gt;
issues like serial number, UUID, etc. The supervisor password (SVP) is also stored in this eeprom.&lt;br /&gt;
The 24RF08 is not an ordinary eeprom: it features read protection, which the BIOS uses to lock down&lt;br /&gt;
access to the eeprom contents.  Also, the password is written in a special scan code, which needs to&lt;br /&gt;
be translated to ASCII to be of any use.&lt;br /&gt;
&lt;br /&gt;
To recover the password, one can use two different programs: R24RF08 (eeprom reader) and IBMpass&lt;br /&gt;
(password revealer) available at [http://www.allservice.ro/store/utils http://www.allservice.ro/store/utils]. Diagrams are included in the reader kit.&lt;br /&gt;
&lt;br /&gt;
Models for which R24RF08 and IBMpass are enough to recover the password: 240, 240X, 390E, 390X, 570, 570E,&lt;br /&gt;
600e, 600X, 770Z, A20m, A21e, A21m, a22m, A30, A30p, A31, A31p, G40, G41, R30, R31, R32, R40, R50, R51, &lt;br /&gt;
Transnote, T20, T21, T22, T23, T30, T40, T40p, T41, T41p, T42, T42p, X20, X21, X22, X23, X24, X30, X31, X40, X41, X61.&lt;br /&gt;
&lt;br /&gt;
ThinkPads featuring TPCA technology (i.e. a [[Tpm|TPM trusted platform module chip]]), especially T4x, X3x, X4x, X61 and X61T need the W24RF08 eeprom writer program to complete the password recovery procedure, if the passphrase function is enabled in BIOS setup.&lt;br /&gt;
&lt;br /&gt;
Other models such as the 380XD or 600 use 24C01 or 93C46 eeproms, which can be read without special tools.&lt;br /&gt;
The method is the same like for the models based on 24RF08, only the software to dump the eeprom is different. &lt;br /&gt;
&lt;br /&gt;
Newer T43/T43p, R52, R60, T60/p, X60 and Z60 ThinkPads can be unlocked using PC8394 programming tools that consist in RPC8394 and WPC8394 (reader and writer for TPM chips). &lt;br /&gt;
The software is available as well at [http://www.allservice.ro/forum/viewtopic.php?p=1061#1061 www.allservice.ro]. IBMpass 2.0 works for any TP model without exceptions.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''2. Locating the ATMEL 24RF08 eeprom. Soldering.'''&lt;br /&gt;
&lt;br /&gt;
No need to unsolder the 24RF08 eeprom, just solder 3 wires to SDA, SCL and GND pins of the&lt;br /&gt;
eeprom. There are two eeprom layouts (see interface schematics described bellow), corresponding to 8 pin or 14 pin eeproms. Locate the eeprom first according to your model (E.g. T20-23 and T30 have the eeprom underneath TP, and can be accessed by removing the RAM modules cover, no need to dismantle the laptop.) and solder the wires using a soldering iron with a fine tip. Also, you can use 0.15 -0.20 mm enamel coated wires or similar small diameter insulated wires. These wires will be connected later to the interface.&lt;br /&gt;
Tip: You can use clips to connect the wires or you can solder on the PCB traces leading to the&lt;br /&gt;
eeprom pins. Once again, be careful and double, triple check the soldering if necessary till you are positively sure you have done the right job. In case of applying too much solder, use flux-impregnated copper-braid &amp;quot;desoldering wick&amp;quot; - this works exceptionally well.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''3. Choose and build the interface.'''&lt;br /&gt;
&lt;br /&gt;
Since version 2.0, R24RF08 and W24RF08 (eeprom writer) are compatible with a wide range of eeprom programmers. By default, both programs set the COM port signals to use direct logic level to access I2C bus. We provide here 2 schematics that are relevant for direct logic signals and for inverse logic signals (simple-i2cprog.pdf and driven-i2cprog.pdf). Also, depending of the interface you build, you can invert the logics for SDA-In, SDA-Out, and SCL COM port signals by some command line parameters described later in this document.&lt;br /&gt;
a) The file simple-i2cprog.pdf contains the schematic diagram of a simple interface (known as SIPROG)based on 2 zeners and 2 resistors. This is a classic, easy to build circuit and works with soldered or unsoldered eeproms. The purpose of the 2 zeners is to convert RS232 levels (+/- 5V) to TTL levels, needed by the eeprom. It uses direct logic signals to I2C eeprom and is powered by the COM port. However, this interface works with in-system eeproms but is dependant on COM port current and eeprom bus impedance. R24RF08 works natively with this circuit, no need to change the lines signals with command line parameters. This circuit works pretty well with almost all ThinkPads series.&lt;br /&gt;
b) The second interface is described in driven-i2cprog.pdf. The circuit uses MAX 232 as a RS232 to TTL driver and its main purpose is to work with soldered eeproms. The advantage of MAX232 is the TTL outputs that are more reliable and more powerful when work with soldered, in-system eeproms (dependency free from the COM port current). Due of the internal inverters of MAX232 the interface responds to an inverse signal logic level. R24RF08 needs /x, /d, /i switches to be specified in the command line.&lt;br /&gt;
&lt;br /&gt;
What these switches mean:&lt;br /&gt;
/x - invert serial clock, also known as SCL;&lt;br /&gt;
/d - invert serial data output, also known as SDA-Out;&lt;br /&gt;
/i - invert serial data input, also known as SDA-In.&lt;br /&gt;
All those can be used in any combination to meet any interface specification.&lt;br /&gt;
&lt;br /&gt;
Note that the &amp;quot;standard&amp;quot; serial port programmer probably won't work with a USB-Serial adapter, but requires the full nominal voltage of a hardware serial port. [Example: the A22p's serial port works fine here.]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''4. Dump the EEPROM:'''&lt;br /&gt;
&lt;br /&gt;
Prepare your technician PC by connecting the interface to the COM1 port (donâ€™t connect the wires to eeprom yet). Turn on the ThinkPad and press F1 to enter BIOS Setup. When you are prompted for the password and thereâ€™s no other activity like HDD access or so, connect the wires (GND first!, SDA, SCL) to the corresponding wires from the interface (attached before to COM1) and execute R24RF08:&lt;br /&gt;
&lt;br /&gt;
-for SI-PROG interface (as described in 3.a above):&lt;br /&gt;
r24rf08.exe &amp;lt;filename.ext&amp;gt;. where filename.ext is the file where eeprom content will be stored.&lt;br /&gt;
Example: r24rf08 mytp.bin&lt;br /&gt;
&lt;br /&gt;
-for MAX232 driven I2C interface (as described in 3.b above):&lt;br /&gt;
r24rf08.exe &amp;lt;filename.ext&amp;gt; /x /d /i. where /x /d /i are command line parameters (switches) for this kind of interface.&lt;br /&gt;
Example: r24rf08 mytp2.bin /x /d /i&lt;br /&gt;
&lt;br /&gt;
Use exactly the instructed switches to avoid possible damages to your eeprom data!&lt;br /&gt;
The file should be created in the same folder. Finally, disconnect the wires (GND last!) and turn off the ThinkPad by pressing on/off switch.&lt;br /&gt;
&lt;br /&gt;
Dump the EEPROM data at least twice, and do a bytewise compare with `cmp`. Both files should be identical, and 1024 bytes long. Otherwise, you probably have a serial port problem.&lt;br /&gt;
&lt;br /&gt;
Note: the r24rf08.exe program automatically sets the serial port parameters. It also works fine with Wine under Linux - provided that a symlink (com1) exists in the .wine/dos_devices directory, and points to the /dev/ttySX for the actual serial port.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''5. Reveal the password.'''&lt;br /&gt;
&lt;br /&gt;
Now, you have the .bin file but you need to dump in scan code to retrieve the password. IBMpass 2.1 Lite is a free tool that will do the job. Just open the eeprom dump youâ€™ve created before and search for 0x330, 0x340 lines. The password is located on 0x338 (and 0x340 depending on model) in scan code. For 24C01 eeproms the password is located at 0x38, 0x40. If the password won't work for the very first time then your eeprom may use newer IBM scancodes. In this case switch to alternate scan codes to find it. For those who want quick answers the recommended version is IBMpass 1.1. Usage for IBMpass 1.1 (command line only):&lt;br /&gt;
&lt;br /&gt;
ibmpass mytp.bin â€“ use â€œ/aâ€ switch to see in alternate scan code if needed:&lt;br /&gt;
ibmpass mytp.bin /a&lt;br /&gt;
&lt;br /&gt;
For some old models like 570 or 770Z you need to execute the eeprom patcher first. This will reset the read protection on the password offset. To do that just execute patcher.exe before the reading operation, without rebooting the laptop:&lt;br /&gt;
&lt;br /&gt;
-for SI-PROG:&lt;br /&gt;
patcher.exe , then immediately&lt;br /&gt;
r24rf08.exe &amp;lt;filename.ext&amp;gt;&lt;br /&gt;
&lt;br /&gt;
-for Driven-I2C (Max232) you must insert the switches:&lt;br /&gt;
patcher.exe /x /d /i, then immediately&lt;br /&gt;
r24rf08.exe &amp;lt;filename.ext&amp;gt; /x /d /i&lt;br /&gt;
&lt;br /&gt;
W24RF08, the writer version, has included the complete APP reset operation you donâ€™t need to use patcher.&lt;br /&gt;
&lt;br /&gt;
Moreover, there are a new encrypting algos used with some new security chips (AT97SC3201, AT97SC3203) that are very secured. The password is not in scancode and in some cases not even in the eeprom. To unlock the machine, the dump should suffer some changes and the eeprom must be reprogrammed using W24RF08. This operation works for all IBM TCG/TCPA secured laptops w/o exceptions. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Remember, use 3 wires from the interface and 3 wires from eeprom! Connect them after your&lt;br /&gt;
ThinkPad is powered and disconnect them right after you read the content, before you switch off the laptop.&lt;br /&gt;
&lt;br /&gt;
'''6. Password format'''&lt;br /&gt;
&lt;br /&gt;
The thinkpad power-on/supervisor passwords are a maximum of 7 characters, and are NOT case-sensitive. The allowed characters are restricted to A-Z, 0-9, semicolon, _, - (and perhaps a few others).&lt;br /&gt;
If  PassPhrase is enabled then the password can be longer than 7 characters. &lt;br /&gt;
Models like T43/R52/T60/R60/T60/X60/Z60/Z61 need the TPM chip dumped with [http://www.allservice.ro/forum/viewtopic.php?p=1061#1061 PC8394 programming tools] in order to find password/reset the TCPA lock.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===External Sources===&lt;br /&gt;
* [http://www.allservice.ro/forum R24RF08/W24RF08, PC8394 programming tools &amp;amp; IBMpass author's forums]&lt;br /&gt;
* {{IBMDOCURL|MIGR-59377|IBM/Lenovo Support - Lost or forgotten password}}&lt;br /&gt;
* [http://www.allservice.ro/forum/viewforum.php?f=12 Full Service of all ThinkPad models including free password recovery]&lt;br /&gt;
* [http://sodoityourself.com/hacking-ibm-thinkpad-bios-password/ A tutorial on how to do this]&lt;br /&gt;
&lt;br /&gt;
[[Category:HOWTOs]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Fan_error&amp;diff=62680</id>
		<title>Fan error</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Fan_error&amp;diff=62680"/>
		<updated>2025-10-09T01:31:44Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Added fan lube instructions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==&amp;quot;fan error&amp;quot; occurs, as reported, after an excessive use of the fan.==&lt;br /&gt;
You can skip this by pressing the ESC key. Or you can try to solve this problem by cleaning the fan.&lt;br /&gt;
&lt;br /&gt;
===Known affected models:===&lt;br /&gt;
T series:&lt;br /&gt;
* [[:Category:T23|T23]]&lt;br /&gt;
* [[:Category:T40|T40]]&lt;br /&gt;
* [[:Category:T41|T41]]&lt;br /&gt;
* [[:Category:T42|T42]]&lt;br /&gt;
* [[:Category:T43|T43]]&lt;br /&gt;
&lt;br /&gt;
==&amp;quot;Fan error&amp;quot; also occurs on bootup if the fan fails to spin up at boot.==&lt;br /&gt;
It can be skipped with the ESC key. On the Core/Core 2 Duo line of ThinkPads, the problem is usually a lubrication failure, which can be solved by oiling the fan;&lt;br /&gt;
* Unscrew heatsink+fan housing and carefully deassemble, removing screws and tape as needed - avoid bending the housing, otherwise the fan will rattle until you bend it back.&lt;br /&gt;
* Pull out the magnet-retained fan blades and clean the dust from the blades and housing (it's easiest to wash the blades in water - but you'll need to completely dry it with paper towel etc afterwards).&lt;br /&gt;
* Put a drop of 3-in-one or sewing machine oil into the motor bearing and re-insert the fan - it should spin freely if you spin it a bit (if there's gunk near/in the bearing, oil, then use paper towel to remove it, then re-oil).&lt;br /&gt;
* Reinstall housing - old tape can be replaced with any moderately heat-resistant tape, like rubber electrical tape (the temperature shouldn't ever exceed 60°C, but you want heat resistance of at least 105°C, so you don't end up with melted or burning plastic).&lt;br /&gt;
* Repasting the CPU while you're at it is recommended.&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Wireless_USB_(UWB)&amp;diff=62679</id>
		<title>Wireless USB (UWB)</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Wireless_USB_(UWB)&amp;diff=62679"/>
		<updated>2025-10-09T00:41:17Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: According to https://www.phoronix.com/news/Linux-5.7-Dropping-UWB-WUSB support was removed in Linux 5.7.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== Wireless USB (UWB) ===&lt;br /&gt;
Select ThinkPads have the option for a Mini PCIe Wireless USB (WUSB) adapter&lt;br /&gt;
&lt;br /&gt;
=== Features ===&lt;br /&gt;
* PCI ID: 8086:??&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
=== Lenovo Partnumbers ===&lt;br /&gt;
* FRU PN: 42T0885 (US for T61p)&lt;br /&gt;
* FRU PN: 42T0887 (Japan for T61p)&lt;br /&gt;
* FRU PN: 43Y6501 (US)&lt;br /&gt;
* FRU PN: 43Y6503 (Japan)&lt;br /&gt;
&lt;br /&gt;
=== Linux support ===&lt;br /&gt;
Support for this technology was merged in the 2.6.28 kernel and removed in kernel 5.7&lt;br /&gt;
&lt;br /&gt;
{{HELP|How to actually make use of it?}}&lt;br /&gt;
=== Links ===&lt;br /&gt;
* [http://www.linuxuwb.org/ Linux UWB and Wireless USB]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Wireless_USB WikipediA article on Wireless USB]&lt;br /&gt;
&lt;br /&gt;
=== ThinkPads which may have this feature ===&lt;br /&gt;
* {{R400}}&lt;br /&gt;
* {{T61p}}, {{T400}}, {{T500}}&lt;br /&gt;
* {{X300}}, {{X301}}&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Category:X200&amp;diff=62678</id>
		<title>Category:X200</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Category:X200&amp;diff=62678"/>
		<updated>2025-10-09T00:35:47Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: 8GB works fine in my X200. From experience, everything but Kingston sticks work with GM45.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== ThinkPad X200 ===&lt;br /&gt;
This page gives an overview of the ThinkPad X200.&lt;br /&gt;
&lt;br /&gt;
==== Standard Features ====&lt;br /&gt;
* One of the following [[Intel Core 2 Duo (Penryn)]] processors:&lt;br /&gt;
** Intel Core 2 Duo P8400, 2.26GHz, 3MB L2, 1066MHz FSB&lt;br /&gt;
** Intel Core 2 Duo P8600, 2.40GHz, 3MB L2, 1066MHz FSB&lt;br /&gt;
** Intel Core 2 Duo P8700, 2.53GHz, 3MB L2, 1066MHz FSB&lt;br /&gt;
** Intel Core 2 Duo P8800, 2.66GHz, 3MB L2, 1066MHz FSB&lt;br /&gt;
* [[Intel Graphics Media Accelerator 4500MHD]] graphics&lt;br /&gt;
* One of the following [[TFT display|TFT displays]]:&lt;br /&gt;
** 12&amp;quot; TFT display with 1280x800 (WXGA) resolution&lt;br /&gt;
** 12&amp;quot; TFT display with 1280x800 (WXGA) resolution with LED backlight&lt;br /&gt;
* 1, 2, 3 or 4GB [[PC3-8500]] memory standard, upgradable to 4GB, 8GB is not officially supported but generally works&lt;br /&gt;
* One of the following hard drives:&lt;br /&gt;
** 80GB SSD 1.8&amp;quot; SATA&lt;br /&gt;
** 128GB SSD 1.8&amp;quot; SATA&lt;br /&gt;
** 160GB 5400RPM 2.5&amp;quot; SATA&lt;br /&gt;
** 160GB 7200RPM 2.5&amp;quot; SATA&lt;br /&gt;
** 250GB 5400RPM 2.5&amp;quot; SATA&lt;br /&gt;
* 5-1 (MMC/SD/SDHC and MS/MS Pro) Media card Reader&lt;br /&gt;
* [[Intel Gigabit Ethernet (10/100/1000) PCI-Express]]&lt;br /&gt;
* Intel HD Audio with a [[CX20561]] codec&lt;br /&gt;
* [[ThinkPad Modem (MDC-3.0, 56kbps HDA)]]&lt;br /&gt;
* [[MiniPCI Express slot]] 1 with one of the following:&lt;br /&gt;
** [[Intel Wifi Link 5100 (AGN)]]&lt;br /&gt;
** [[Intel Wifi Link 5300 (AGN)]]&lt;br /&gt;
** [[Intel WiMAX/WiFi Link 5150]]&lt;br /&gt;
** [[Intel WiMAX/WiFi Link 5350]]&lt;br /&gt;
* [[MiniPCI Express slot]] 2 with one of the following:&lt;br /&gt;
** none (empty)&lt;br /&gt;
** none (WWAN upgradable)&lt;br /&gt;
** [[Sierra Wireless MC5725|Verizon Mobile Broadband with GPS]]&lt;br /&gt;
** [[Ericsson F3507g Mobile Broadband Module|AT&amp;amp;T Mobile Broadband with GPS]]&lt;br /&gt;
*  [[MiniPCI Express slot]] 3 with one of the following:&lt;br /&gt;
** none (empty)&lt;br /&gt;
** [[Intel® Turbo Memory hard drive cache]] 2GB&lt;br /&gt;
* 1.3MP [[Integrated camera]] on select models&lt;br /&gt;
* [[Integrated Fingerprint Reader]] on select models&lt;br /&gt;
* [[ThinkPad_Bluetooth_with_Enhanced_Data_Rate_(BDC-2.1)|Bluetooth]] on select models&lt;br /&gt;
* [[Embedded Security Subsystem|Trusted Computing Group TPM 1.2]]&lt;br /&gt;
* [[Active Protection System]]&lt;br /&gt;
* One [[ExpressCard_slot|ExpressCard/54 Slot]]&lt;br /&gt;
* One of the following batteries&lt;br /&gt;
** 4-cell battery, 29 Wh (14.4 V, 2.0 Ah).  up to 3.3 hr, 1.34kg&lt;br /&gt;
** 4-cell *tablet, 29 Wh (14.4 V, 2.0 Ah).&lt;br /&gt;
** 6-cell battery, 56 Wh (10.8 V, 5.2 Ah).  up to 6.5 hr, 1.47kg (slightly elevates the back)&lt;br /&gt;
** 8-cell *tablet, 66 Wh (14.4 V, 4.6 Ah)&lt;br /&gt;
** 9-cell battery, 85 Wh (10.8 V, 7.8 Ah).  up to 9.8 hr, 1.63kg (protrudes out back 22.8mm/.9in)&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
[[Image:ThinkPadX200.jpg|ThinkPad X200|300px]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Resources ====&lt;br /&gt;
* [http://shop.lenovo.com/ISS_Static/merchandising/US/PDFs/x200_datasheet.pdf X200 Technical Specifications (x200_datasheet.pdf 1138738 octet)]&lt;br /&gt;
*{{IBMDOCURL|MIGR-70149|Hardware Maintenance Manual (HMM) - ThinkPad X200, Twelfth Edition (November 2014) (x200_x200s_x200si_x201_x201i_x201s_hmm_en_43y6632_11.pdf 16338562 octet)}}&lt;br /&gt;
&lt;br /&gt;
==== Reviews ====&lt;br /&gt;
* [http://www.notebookreview.com/default.asp?newsID=4497 Notebookreview.com] 2008-07-15&lt;br /&gt;
* [http://www.laptopmag.com/review/laptops/lenovo-thinkpad-x200.aspx Laptopmag.com] 2007-07-14&lt;br /&gt;
* [http://reviews.cnet.com/laptops/lenovo-thinkpad-x200/4505-3121_7-33184078.html Cnet.com] 2008-08-14&lt;br /&gt;
&lt;br /&gt;
==== Notes ====&lt;br /&gt;
Sometimes even basic information is hard to find.  Here's a place for it.&lt;br /&gt;
&lt;br /&gt;
* [[GPS]] - If you have an optional WWAN card (AT&amp;amp;T or Verizon), you have GPS.  ''unconfirmed''&lt;br /&gt;
* The 5300 normally has 3 x 3 antennas.  Adding the webcam reduces this to 2 x 2.  ''unconfirmed''&lt;br /&gt;
*: Any other conflicts?  Bluetooth, etc?&lt;br /&gt;
* X200 configured with SSD include the [[Active Protection System]] accelerometer (at least 7454-CTO models shipped in Q4 2008). [[User:Vminko|Vminko]] 02:41, 30 December 2008 (CET)&lt;br /&gt;
* The X200 does not have a touchpad.  For folks who really want one, a somewhat messy possibility ''might'' be [http://www.ergonomictouchpad.com/ergonomic_touchpad.php www.ergonomictouchpad.com] (never used - no endorsement) which looks vaguely like a [http://www.cirque.com/cpages/?page=17 Cirque TSM9925 Touchpad] with velcro and wire added.&lt;br /&gt;
* There can be a ''big'' cost difference between preconfigured units from VARs, and custom configured units from shop.lenovo.com, as of 2008-10-31 ([http://alltp.blogspot.com/2008/10/heckuva-deal-on-lenovo-x200-tablet-pc.html examples]).&lt;br /&gt;
&lt;br /&gt;
[[Category:X Series]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Fix_for_suspend_problems_on_T410s_with_touchscreen&amp;diff=62657</id>
		<title>Fix for suspend problems on T410s with touchscreen</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Fix_for_suspend_problems_on_T410s_with_touchscreen&amp;diff=62657"/>
		<updated>2025-05-03T02:11:07Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Linux is only a kernel. The script will work on any distro that has hid_ntrig as a module. Cleaned up.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In {{Ubuntu}} (and a lot of other GNU/Linux distrubutions) the Lenovo {{T410s}} with a [[MultiTouch|touchscreen]] has (had?) the issue that it cannot go into suspend.&lt;br /&gt;
&lt;br /&gt;
It is the kernel module hid_ntrig that seems to be causing the problem. Thus a work around this is to turn off the kernel module hid_ntrig by running the following command:&lt;br /&gt;
 modprobe -r hid_ntrig&lt;br /&gt;
&lt;br /&gt;
This will disable the touch screen, but now suspend works. &lt;br /&gt;
&lt;br /&gt;
If you want to have both your touch screen and suspend, go to the folder: /etc/pm/sleep.d/. You should create a script file in this folder which will then be called when your laptops goes into and awakens from suspend. The script should contain the following and remember to make the file executable (&amp;lt;code&amp;gt;chmod +x disable-enable-hid-ntrig.sh&amp;lt;/code&amp;gt;):&lt;br /&gt;
 #!/bin/sh&lt;br /&gt;
 &lt;br /&gt;
 # Disable ntrig on suspend and enable it when awakening from suspend.&lt;br /&gt;
 # Goal: Make both suspend and touchscreen work on Lenovo ThinkPad T410s.&lt;br /&gt;
 &lt;br /&gt;
 # pm-action(8) - &amp;lt;action&amp;gt; &amp;lt;suspend method&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 case &amp;quot;${1}&amp;quot; in&lt;br /&gt;
         suspend|hibernate)&lt;br /&gt;
                 modprobe -r hid_ntrig       &lt;br /&gt;
                 ;;&lt;br /&gt;
         resume|thaw)&lt;br /&gt;
                 modprobe hid_ntrig &amp;amp;&lt;br /&gt;
                 ;;&lt;br /&gt;
 esac&lt;br /&gt;
&lt;br /&gt;
When your laptop goes into suspend, the touch screen module will be disabled; &amp;lt;code&amp;gt;modprobe -r hid_ntrig&amp;lt;/code&amp;gt; and on awakening the module is enabled; &amp;lt;code&amp;gt;modprobe hid_ntrig &amp;amp;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Ampersand (&amp;amp;) was added when enabling hid_ntrig, because this command is rather slow. By doing so the command in run in the background, and thus it will not make your computer stall on awakening, but it might take 10 seconds before you can use your touch screen.&lt;br /&gt;
&lt;br /&gt;
This has been implemented in Mint 10 but I guess it will also work in a normal {{Ubuntu}} 10.10 installation.&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=MultiTouch&amp;diff=62656</id>
		<title>MultiTouch</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=MultiTouch&amp;diff=62656"/>
		<updated>2025-05-03T02:01:19Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Capitalization, spelling and grammar. It probably has been fixed now, but leave the details in place in case anyone still has problems.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |[[Image:Logo_wacom.gif|Wacom Logo]]&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:0px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== MultiTouch ===&lt;br /&gt;
Some models come with touchscreen abilities, known as MultiTouch.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
MultiTouch is an optional feature on the X60/X61/X200/X201/etc Tablet. It allows you to use any device that can create pressure (such as your finger) instead of the tablet pen. This feature is currently ''experimentally'' supported with linuxwacom. However, the tablet pen will still work on such systems.&lt;br /&gt;
&lt;br /&gt;
With the wacom drivers, it will only support as a single-touch interface and not as real multitouch. &lt;br /&gt;
&lt;br /&gt;
If your tablet pen does not work, try building the linuxwacom modules from source. You can find everything you need [http://linuxwacom.sourceforge.net on their website.]&lt;br /&gt;
&lt;br /&gt;
On the X201 Tablet, it was reported that 2 fingers work on the display without pressure and the pen is working normal (with pressure).&lt;br /&gt;
&lt;br /&gt;
A multitouch screen is an optional upgrade for the (non-tablet) {{T410s}}.  As of January 2011, this is not recommended.  Although it has some support as an input device, it seems to cause significant stability problems.  On Ubuntu it prevents suspend from working; on both Debian and Ubuntu it seems to cause instability in X; and on Debian, while suspend works, wakeup from suspend seems quite unreliable.&lt;br /&gt;
&lt;br /&gt;
If you run into such issues (i.e. you are using Mint 10), you can fix this by disabling the kernel module during suspend. See [[Fix_for_suspend_problems_on_T410s_with_touchscreen|Fix for suspend problems on T410s with touchscreen]].&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Category:X200_Tablet&amp;diff=62655</id>
		<title>Category:X200 Tablet</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Category:X200_Tablet&amp;diff=62655"/>
		<updated>2025-05-03T01:48:23Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: &amp;quot;in linux&amp;quot; is not correct. It's not hypothetical, it's merely a technical and interest matter. grammar. Bluetooth uses an internal antenna, thus that won't be a conflict.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== ThinkPad X200 Tablet ===&lt;br /&gt;
This page gives an overview of the ThinkPad X200 Tablet.&lt;br /&gt;
&lt;br /&gt;
==== Standard Features ====&lt;br /&gt;
*One of the following [[Intel Core 2 Duo (Penryn)]] processors:&lt;br /&gt;
** Intel® Core™ 2 Duo processor SU9300 (1.2GHz, 800MHz FSB, 3MB L2 cache)&lt;br /&gt;
** Intel® Core™ 2 Duo processor SL9300 (1.6Ghz, 1066Mhz FSB, 6MB L2 cache)&lt;br /&gt;
** Intel® Core™ 2 Duo processor SL9400 (1.86Ghz, 1066Mhz FSB, 6MB L2 cache)&lt;br /&gt;
** Intel® Core™ 2 Duo processor SL9600 (2.13Ghz, 1066Mhz FSB, 6MB L2 cache)&lt;br /&gt;
* [[Intel Graphics Media Accelerator 4500MHD]] graphics&lt;br /&gt;
* One of the following [[TFT display|TFT displays]]:&lt;br /&gt;
** 12.1&amp;quot; 1280x800 (CCFL backlight) 190 nit, FFS&lt;br /&gt;
** 12.1&amp;quot; 1280x800 (LED backlight) 285 nit, IPS&lt;br /&gt;
** 12.1&amp;quot; 1280x800 (LED backlight) 200 nit, IPS&lt;br /&gt;
** 12.1&amp;quot; 1280x800 (LED backlight) 230 nit, IPS, MultiView, [[MultiTouch]]&lt;br /&gt;
** 12.1&amp;quot; 1280x800 (LED backlight) 270 nit, IPS, MultiView, [[MultiTouch]]&lt;br /&gt;
** 12.1&amp;quot; 1280x800 (LED backlight) 400 nit, IPS, Outdoor&lt;br /&gt;
* 2 or 4GB [[PC3-8500]] memory standard, upgradable to 8GB&lt;br /&gt;
* One of the following hard drives:&lt;br /&gt;
** 80GB SSD 1.8&amp;quot; SATA&lt;br /&gt;
** 128GB SSD 1.8&amp;quot; SATA&lt;br /&gt;
** 160GB 5400RPM 2.5&amp;quot; SATA&lt;br /&gt;
** 160GB 7200RPM 2.5&amp;quot; SATA&lt;br /&gt;
** 250GB 5400RPM 2.5&amp;quot; SATA&lt;br /&gt;
* 5-in-1 (MMC/SD/SDHC and MS/MS Pro) Media card Reader&lt;br /&gt;
* [[Intel Gigabit Ethernet (10/100/1000) PCI-Express]]&lt;br /&gt;
* [[ThinkPad Modem (MDC-3.0, 56kbps HDA)]]&lt;br /&gt;
* [[MiniPCI Express slot]] 1 with one of the following:&lt;br /&gt;
** [[Intel Wifi Link 5100 (AGN)]]&lt;br /&gt;
** [[Intel Wifi Link 5300 (AGN)]]&lt;br /&gt;
** [[Intel WiMAX/WiFi Link 5350]]&lt;br /&gt;
** [[ThinkPad 11b/g/n Wireless LAN Mini-PCI Express Adapter II]]&lt;br /&gt;
* [[MiniPCI Express slot]] 2 with one of the following:&lt;br /&gt;
** none (empty, not upgradable)&lt;br /&gt;
** none (WWAN upgradable)&lt;br /&gt;
** [[Sierra Wireless MC5725|Verizon Mobile Broadband with GPS]]&lt;br /&gt;
** [[Ericsson F3507g Mobile Broadband Module|AT&amp;amp;T Mobile Broadband with GPS]]&lt;br /&gt;
*  [[MiniPCI Express slot]] 3 with one of the following:&lt;br /&gt;
** none (empty)&lt;br /&gt;
** [[Intel® Turbo Memory hard drive cache]] 2GB&lt;br /&gt;
** Lenovo Wireless USB Module&lt;br /&gt;
* [[ExpressCard slot|ExpressCard/54 slot]]&lt;br /&gt;
* [[ThinkPad_Bluetooth_with_Enhanced_Data_Rate_(BDC-2.1)|Bluetooth]] on select models&lt;br /&gt;
* [[TrackPoint]]&lt;br /&gt;
* Fingerprint reader (Authentec 2810) on select models&lt;br /&gt;
* Intel HD Audio with a [[CX20561]] codec&lt;br /&gt;
* 1.3MP [[Integrated camera]] on select models&lt;br /&gt;
* [[Embedded Security Subsystem|Trusted Computing Group TPM 1.2]]&lt;br /&gt;
* [[Active Protection System]]&lt;br /&gt;
* Battery Sizes - 4 cell, 8 cell (sticks out the back)&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
[[Image:ThinkPadX200_Tablet.jpg|ThinkPad X200 Tablet|300px]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Resources ====&lt;br /&gt;
*{{IBMDOCURL|MIGR-70830|Hardware Maintenance Manual - ThinkPad X200/X201 Tablet (45n3683_04.pdf 15774415 octet)}}&lt;br /&gt;
&lt;br /&gt;
==== Notes ====&lt;br /&gt;
Sometimes even basic information is hard to find.  Here's a place for it.&lt;br /&gt;
&lt;br /&gt;
* The standard '''X200T does ''not'' support [http://en.wikipedia.org/wiki/Multi-touch Multi-touch]!'''.  Only the &amp;quot;Enhanced MultiTouch&amp;quot; supports true MultiTouch.  The standard X200T uses Wacom's no-longer-cutting-edge non-multitouch screen.  Only one contact point is available in hardware.&lt;br /&gt;
** Although, you probably could get two points from a MultiTouch screen, one from finger contact, and one from a stylus hovering over but not touching the screen (available from Linux as separate devices under /sys/class/input), nobody has tried so far and there's a chance the hardware could lock or clear the &amp;quot;hover&amp;quot; position during a touch.&lt;br /&gt;
* [[GPS]] - If you have an optional WWAN card (AT&amp;amp;T or Verizon), you have GPS.  ''unconfirmed''&lt;br /&gt;
* The 5300 normally has 3 x 3 antennas.  Adding the webcam reduces this to 2 x 2.  ''unconfirmed''&lt;br /&gt;
* X200T configured with SSD do '''not''' include the [[Active Protection System]] accelerometer, despite alternate uses (theft deterrence).  Confirmed by Lenovo US sales phone, 2008-10. [[User:Mitchell|Mitchell]] 21:54, 28 October 2008 (CET)&lt;br /&gt;
** My x200t that shipped with an SSD (Feb 2009) *does* include the accelerometer. I suspect that the same accelerometer is the one used to automatically change the screen orientation, so it doesn't make sense that any of the tablets wouldn't include it. There's also only a single part number for the motherboard in the Hardware Maintenance Manual: if there was a revision used for units shipped with SSDs it would likely be listed separately.&lt;br /&gt;
* The [http://www-01.ibm.com/common/ssi/cgi-bin/ssialias?infotype=AN&amp;amp;subtype=CA&amp;amp;htmlfid=897/ENUS108-588&amp;amp;appname=lenovous&amp;amp;language=en X200 Tablet Sleeve] supports 4 and 8 cell batteries, but not 9 cell.  ''from announcement''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:X Series]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Category:R400&amp;diff=62654</id>
		<title>Category:R400</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Category:R400&amp;diff=62654"/>
		<updated>2025-05-01T12:24:01Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Those spaces shouldn't be there.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== ThinkPad R400 ===&lt;br /&gt;
This page gives an overview of the ThinkPad R400.&lt;br /&gt;
&lt;br /&gt;
=== Machine Type ===&lt;br /&gt;
{{HELP|Did switchable Graphics models exist? I cannot find any such hybrid model Machine Types, even though there was talk of it in the press and some Lenovo datasheets seem to suggest they did exist}}&lt;br /&gt;
* 2782, 2783, 2784, 2786, 2787, 2788, 2789 AMD Mobility Radeon HD3470&lt;br /&gt;
* 7438, 7439, 7440, 7443, 7445, 7446, 7447 Intel Graphics GMA 4500MHD&lt;br /&gt;
&lt;br /&gt;
It appears that some models (such as 2784-R1U) were also shipped with nVidia Ge Force 9300M graphics&lt;br /&gt;
&lt;br /&gt;
==== Standard Features ====&lt;br /&gt;
* One of the following processors:&lt;br /&gt;
** [[Intel Core 2 Duo (Merom)]] T5870 and 5670&lt;br /&gt;
** [[Intel Core 2 Duo (Penryn)]] P8400, P8600, T9400 and T9600&lt;br /&gt;
** [[Intel Celeron M| Intel Celeron M (Merom L)]] 575 and 585&lt;br /&gt;
* Chipset&lt;br /&gt;
** Mobile Intel® GM45 Express CS/ICH 9M-E&lt;br /&gt;
** Mobile Intel® GMA X4500 HD&lt;br /&gt;
** Mobile Intel® GL667 MHz (Celeron®)&lt;br /&gt;
* One of the following graphics adapters:&lt;br /&gt;
*  [[nVidia GeForce 9300M]]&lt;br /&gt;
** [[Intel Graphics Media Accelerator 4500MHD]]&lt;br /&gt;
** [[Switchable Graphics]] with [[Intel Graphics Media_Accelerator 4500MHD|Intel GMA 4500MHD]] and [[ATI Mobility Radeon HD 3470]] &lt;br /&gt;
* One of the following displays:&lt;br /&gt;
** 14.1&amp;quot; wide: WXGA (1280 x 800, 107DPI, 185+ nit)&lt;br /&gt;
** 14.1&amp;quot; wide: WXGA+ (1440 x 900, 120DPI, 200+ nit)&lt;br /&gt;
*System Memory&lt;br /&gt;
** Up to 8GB of [[PC3-8500]] 1066MHz DDR3&lt;br /&gt;
*Harddrive&lt;br /&gt;
** 80, 160, 250 or 320GB 5400RPM SATA HDD &lt;br /&gt;
** 160, 200GB (FDE) 7200 RPM SATA HDD &lt;br /&gt;
* [[Intel Gigabit Ethernet (10/100/1000) PCI-Express]]&lt;br /&gt;
* Intel HD Audio with a [[CX20561]] codec&lt;br /&gt;
* [[ThinkPad Modem (MDC-3.0, 56kbps HDA)]]&lt;br /&gt;
* [[MiniPCI Express slot]] 1 with one of the following:&lt;br /&gt;
** [[Intel Wifi Link 5100 (AGN)]] (1x2AGN)&lt;br /&gt;
** [[Intel Wifi Link 5300 (AGN)]] (3x3 AGN)&lt;br /&gt;
** [[ThinkPad 11b/g/n Wireless LAN Mini-PCI Express Adapter II]]&lt;br /&gt;
* [[MiniPCI Express slot]] 2 with one of the following:&lt;br /&gt;
** None (not upgradable)&lt;br /&gt;
** [[Intel® Turbo Memory hard drive cache]] up to 2GB&lt;br /&gt;
** [[Wireless USB (UWB)]]&lt;br /&gt;
* 1 [[CardBus slot]] (Type 2)&lt;br /&gt;
* under which there one of:&lt;br /&gt;
** [[ExpressCard slot|ExpressCard/54 slot]] &lt;br /&gt;
** SmartCard reader&lt;br /&gt;
** [[Ricoh_R5C843|4-in-1 Memory reader]]&lt;br /&gt;
* [[Embedded Security Subsystem|Trusted Computing Group TPM 1.2]]&lt;br /&gt;
* [[Active Protection System]]&lt;br /&gt;
* [[Integrated Fingerprint Reader]] on select models&lt;br /&gt;
* [[ThinkPad_Bluetooth_with_Enhanced_Data_Rate_(BDC-2.1)|Bluetooth]] on select models&lt;br /&gt;
* [[UltraNav]] (TrackPoint / Touchpad combo)&lt;br /&gt;
* 1.3MP [[Integrated camera]] on select models&lt;br /&gt;
* [[Firewire Port|Firewire 400]] (IEEE1394a) on selected models&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
[[image:ThinkPadR400.jpg|ThinkPad R400|300px]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:R Series]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/thinkpad-smapi.sh&amp;diff=62648</id>
		<title>Code/thinkpad-smapi.sh</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/thinkpad-smapi.sh&amp;diff=62648"/>
		<updated>2025-04-13T09:31:59Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: William confirmed via email that; &amp;quot;As for your request, sure, I will license it to you under GPLv3 or later.&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
# Copyright (C) 2007 William Poetra Yoga Hadisoeseno &amp;lt;williampoetra@gmail.com&amp;gt;&lt;br /&gt;
# This file is licensed under the GPL version 3, or (at your option) any later version.&lt;br /&gt;
# E-mail me if you have any ideas of other licenses to use (BSD, Public Domain, etc.), I'm open :)&lt;br /&gt;
&lt;br /&gt;
# IDEAS&lt;br /&gt;
# - make an ncurses interface, and also maybe gtk+ and qt&lt;br /&gt;
# - add option to enable modifying the charge control variables&lt;br /&gt;
&lt;br /&gt;
TP_SMAPI_BASE=/sys/devices/platform/smapi&lt;br /&gt;
&lt;br /&gt;
# function to simplify reading from files&lt;br /&gt;
# syntax: read_file &amp;lt;variable&amp;gt; &amp;lt;filename&amp;gt; &amp;lt;check_return_value 0/1&amp;gt; &amp;lt;translate 0/1&amp;gt; [[value] [translation_string]]&lt;br /&gt;
read_file()&lt;br /&gt;
{&lt;br /&gt;
  local VARIABLE&lt;br /&gt;
  local FILENAME&lt;br /&gt;
  local CHECK_RETURN&lt;br /&gt;
  local TRANSLATE&lt;br /&gt;
  local VAL&lt;br /&gt;
  local RET&lt;br /&gt;
&lt;br /&gt;
  VARIABLE=&amp;quot;$1&amp;quot;; shift&lt;br /&gt;
  FILENAME=&amp;quot;$1&amp;quot;; shift&lt;br /&gt;
  CHECK_RETURN=&amp;quot;$1&amp;quot;; shift&lt;br /&gt;
  TRANSLATE=&amp;quot;$1&amp;quot;; shift&lt;br /&gt;
&lt;br /&gt;
  VAL=`cat &amp;quot;$FILENAME&amp;quot; 2&amp;gt; /dev/null`&lt;br /&gt;
  RET=$?&lt;br /&gt;
&lt;br /&gt;
  if [[ &amp;quot;$CHECK_RETURN&amp;quot; == &amp;quot;1&amp;quot; ]] &amp;amp;&amp;amp; [[ $RET -gt 0 ]]&lt;br /&gt;
  then&lt;br /&gt;
    RESULT=&amp;quot;[unavailable]&amp;quot;&lt;br /&gt;
  elif [ &amp;quot;$TRANSLATE&amp;quot; == &amp;quot;1&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    RESULT=&amp;quot;unknown ($RET)&amp;quot;&lt;br /&gt;
    while [ -n &amp;quot;$1&amp;quot; ]&lt;br /&gt;
    do&lt;br /&gt;
      if [ &amp;quot;$VAL&amp;quot; == &amp;quot;$1&amp;quot; ]&lt;br /&gt;
      then&lt;br /&gt;
        RESULT=&amp;quot;$2&amp;quot;&lt;br /&gt;
        break&lt;br /&gt;
      fi&lt;br /&gt;
      shift 2&lt;br /&gt;
    done&lt;br /&gt;
  else&lt;br /&gt;
    RESULT=&amp;quot;$VAL&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  eval &amp;quot;$VARIABLE=&amp;quot;'&amp;quot;'&amp;quot;$RESULT&amp;quot;'&amp;quot;'&lt;br /&gt;
#  eval &amp;quot;$VARIABLE=$RESULT&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
give_units()&lt;br /&gt;
{&lt;br /&gt;
  local VARIABLE&lt;br /&gt;
  local UNIT&lt;br /&gt;
  local VALUE&lt;br /&gt;
  local RESULT&lt;br /&gt;
&lt;br /&gt;
  VARIABLE=&amp;quot;$1&amp;quot;&lt;br /&gt;
  UNIT=&amp;quot;$2&amp;quot;&lt;br /&gt;
  eval &amp;quot;VALUE=\$$VARIABLE&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  if (echo &amp;quot;$VALUE&amp;quot; | grep -qs &amp;quot;^-\?[0-9]&amp;quot;)&lt;br /&gt;
  then&lt;br /&gt;
    RESULT=&amp;quot;$VALUE $UNIT&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    RESULT=&amp;quot;$VALUE&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  eval &amp;quot;$VARIABLE=&amp;quot;'&amp;quot;'&amp;quot;$RESULT&amp;quot;'&amp;quot;'&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
replace_val()&lt;br /&gt;
{&lt;br /&gt;
  local VARIABLE&lt;br /&gt;
  local OLD_VALUE&lt;br /&gt;
  local NEW_VALUE&lt;br /&gt;
  local VALUE&lt;br /&gt;
  local RESULT&lt;br /&gt;
&lt;br /&gt;
  VARIABLE=&amp;quot;$1&amp;quot;&lt;br /&gt;
  OLD_VALUE=&amp;quot;$2&amp;quot;&lt;br /&gt;
  NEW_VALUE=&amp;quot;$3&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  eval &amp;quot;VALUE=\$$VARIABLE&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  if [ &amp;quot;$VALUE&amp;quot; == &amp;quot;$OLD_VALUE&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    RESULT=&amp;quot;$NEW_VALUE&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    RESULT=&amp;quot;$VALUE&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  eval &amp;quot;$VARIABLE=&amp;quot;'&amp;quot;'&amp;quot;$RESULT&amp;quot;'&amp;quot;'&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
show_help()&lt;br /&gt;
{&lt;br /&gt;
  cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
&lt;br /&gt;
  thinkpad-smapi.sh - Show SMAPI information on ThinkPad laptops, through&lt;br /&gt;
                      the exported SMAPI information by the tp_smapi module.&lt;br /&gt;
&lt;br /&gt;
  -a      Show all available information&lt;br /&gt;
  -b [n]  Show all available information for battery [n]&lt;br /&gt;
  -h      Show this help text&lt;br /&gt;
  -m      Show miscellaneous information&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
show_misc()&lt;br /&gt;
{&lt;br /&gt;
  cd $TP_SMAPI_BASE&lt;br /&gt;
&lt;br /&gt;
  read_file PCI_POWER_SAVINGS &amp;quot;enable_pci_power_saving_on_boot&amp;quot; 1 1 1 &amp;quot;enabled&amp;quot; 0 &amp;quot;disabled&amp;quot;&lt;br /&gt;
  read_file AC_ADAPTER &amp;quot;ac_connected&amp;quot; 1 1 1 &amp;quot;connected&amp;quot; 0 &amp;quot;disconnected&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
MISCELLANEOUS INFORMATION&lt;br /&gt;
=========================&lt;br /&gt;
&lt;br /&gt;
PCI power savings on boot: $PCI_POWER_SAVINGS&lt;br /&gt;
AC adapter status: $AC_ADAPTER&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
show_batt()&lt;br /&gt;
{&lt;br /&gt;
  SLOT=$1&lt;br /&gt;
  cd $TP_SMAPI_BASE/BAT$SLOT&lt;br /&gt;
&lt;br /&gt;
  TMP=`cat installed`&lt;br /&gt;
  if [ $TMP -eq 1 ]&lt;br /&gt;
  then&lt;br /&gt;
    BATT_INSTALLED=&amp;quot;yes&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    BATT_INSTALLED=&amp;quot;no&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  BATT_STATE=`cat state`&lt;br /&gt;
&lt;br /&gt;
  if [ $BATT_INSTALLED == &amp;quot;yes&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
&lt;br /&gt;
    read_file BARCODING &amp;quot;barcoding&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_CHEMISTRY &amp;quot;chemistry&amp;quot; 1 0&lt;br /&gt;
    read_file DESIGN_CAPACITY &amp;quot;design_capacity&amp;quot; 1 0&lt;br /&gt;
    read_file DESIGN_VOLTAGE &amp;quot;design_voltage&amp;quot; 1 0&lt;br /&gt;
    read_file MANUFACTURE_DATE &amp;quot;manufacture_date&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_FRU &amp;quot;model&amp;quot; 1 0&lt;br /&gt;
    read_file MANUFACTURER &amp;quot;manufacturer&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_SERIAL &amp;quot;serial&amp;quot; 1 0&lt;br /&gt;
&lt;br /&gt;
    read_file FIRST_USE_DATE &amp;quot;first_use_date&amp;quot; 1 0&lt;br /&gt;
    read_file CYCLE_COUNT &amp;quot;cycle_count&amp;quot; 1 0&lt;br /&gt;
    read_file LAST_FULL_CAPACITY &amp;quot;last_full_capacity&amp;quot; 1 0&lt;br /&gt;
    read_file CURRENT_1MIN &amp;quot;current_avg&amp;quot; 1 0&lt;br /&gt;
    read_file POWER_1MIN &amp;quot;power_avg&amp;quot; 1 0&lt;br /&gt;
&lt;br /&gt;
    read_file CAPACITY_MWH &amp;quot;remaining_capacity&amp;quot; 1 0&lt;br /&gt;
    read_file CAPACITY_PERCENT &amp;quot;remaining_percent&amp;quot; 1 0&lt;br /&gt;
    read_file REMAINING_RUNNING_TIME &amp;quot;remaining_running_time&amp;quot; 1 0&lt;br /&gt;
    read_file CURRENT_NOW &amp;quot;current_now&amp;quot; 1 0&lt;br /&gt;
    read_file POWER_NOW &amp;quot;power_now&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_TEMPERATURE &amp;quot;temperature&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_VOLTAGE &amp;quot;voltage&amp;quot; 1 0&lt;br /&gt;
    read_file REMAINING_CHARGING_TIME &amp;quot;remaining_charging_time&amp;quot; 1 0&lt;br /&gt;
&lt;br /&gt;
    # fixups&lt;br /&gt;
    give_units DESIGN_CAPACITY &amp;quot;mWh&amp;quot;&lt;br /&gt;
    give_units DESIGN_VOLTAGE &amp;quot;mV&amp;quot;&lt;br /&gt;
    give_units CURRENT_NOW &amp;quot;mA&amp;quot;&lt;br /&gt;
    give_units POWER_NOW &amp;quot;mW&amp;quot;&lt;br /&gt;
    give_units CURRENT_1MIN &amp;quot;mA&amp;quot;&lt;br /&gt;
    give_units POWER_1MIN &amp;quot;mW&amp;quot;&lt;br /&gt;
    give_units LAST_FULL_CAPACITY &amp;quot;mWh&amp;quot;&lt;br /&gt;
    give_units REMAINING_RUNNING_TIME &amp;quot;min&amp;quot;&lt;br /&gt;
    give_units REMAINING_CHARGING_TIME &amp;quot;min&amp;quot;&lt;br /&gt;
    give_units CAPACITY_PERCENT &amp;quot;%&amp;quot;&lt;br /&gt;
    give_units BATT_TEMPERATURE &amp;quot;mC&amp;quot;&lt;br /&gt;
    give_units BATT_VOLTAGE &amp;quot;mV&amp;quot;&lt;br /&gt;
&lt;br /&gt;
    # some more&lt;br /&gt;
    replace_val REMAINING_RUNNING_TIME &amp;quot;not_discharging&amp;quot; &amp;quot;[not discharging]&amp;quot;&lt;br /&gt;
    replace_val REMAINING_CHARGING_TIME &amp;quot;not_charging&amp;quot; &amp;quot;[not charging]&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  else&lt;br /&gt;
&lt;br /&gt;
    BATT_FRU=&lt;br /&gt;
    MANUFACTURER=   &lt;br /&gt;
    BATT_SERIAL=&lt;br /&gt;
    BARCODING=&lt;br /&gt;
    BATT_CHEMISTRY=&lt;br /&gt;
    DESIGN_CAPACITY=&lt;br /&gt;
    DESIGN_VOLTAGE=&lt;br /&gt;
    MANUFACTURE_DATE=&lt;br /&gt;
&lt;br /&gt;
    FIRST_USE_DATE=&lt;br /&gt;
    CYCLE_COUNT=&lt;br /&gt;
    LAST_FULL_CAPACITY=&lt;br /&gt;
    CURRENT_1MIN=&lt;br /&gt;
    POWER_1MIN=&lt;br /&gt;
&lt;br /&gt;
    CAPACITY_MWH=&lt;br /&gt;
    CAPACITY_PERCENT=&lt;br /&gt;
    REMAINING_RUNNING_TIME=&lt;br /&gt;
    CURRENT_NOW=&lt;br /&gt;
    POWER_NOW=&lt;br /&gt;
    BATT_TEMPERATURE=&lt;br /&gt;
    BATT_VOLTAGE=&lt;br /&gt;
    REMAINING_CHARGING_TIME=&lt;br /&gt;
&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  read_file START_CHARGE_THRESH &amp;quot;start_charge_thresh&amp;quot; 1 0&lt;br /&gt;
  read_file STOP_CHARGE_THRESH &amp;quot;stop_charge_thresh&amp;quot; 1 0&lt;br /&gt;
  read_file INHIBIT_CHARGE_MIN &amp;quot;inhibit_charge_minutes&amp;quot; 1 0&lt;br /&gt;
  read_file BATT_FORCE_DISCHARGE &amp;quot;force_discharge&amp;quot; 1 1 1 &amp;quot;yes&amp;quot; 0 &amp;quot;no&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# installed*, state*, dump&lt;br /&gt;
# barcoding, chemistry, design_capacity, design_voltage, manufacture_date, model, manufacturer, serial&lt;br /&gt;
# first_use_date, cycle_count, last_full_capacity, current_avg, power_avg&lt;br /&gt;
# remaining_capacity, remaining_percent, remaining_running_time, current_now, power_now, temperature, voltage, remaining_charging_time&lt;br /&gt;
# start_charge_thresh*, stop_charge_thresh*, inhibit_charge_minutes*, force_discharge*&lt;br /&gt;
&lt;br /&gt;
  cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
BATTERY $SLOT INFORMATION&lt;br /&gt;
=====================&lt;br /&gt;
&lt;br /&gt;
Battery slot:&lt;br /&gt;
  Battery present: $BATT_INSTALLED&lt;br /&gt;
  Battery state: $BATT_STATE&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
&lt;br /&gt;
  if [ &amp;quot;$BATT_INSTALLED&amp;quot; == &amp;quot;yes&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
Embedded info:&lt;br /&gt;
  FRU P/N: $BATT_FRU&lt;br /&gt;
  Barcoding: $BARCODING&lt;br /&gt;
  Serial number: $BATT_SERIAL&lt;br /&gt;
  OEM Manufacturer: $MANUFACTURER&lt;br /&gt;
  Chemistry: $BATT_CHEMISTRY&lt;br /&gt;
  Manufacture date: $MANUFACTURE_DATE&lt;br /&gt;
  Design capacity &amp;amp; voltage: $DESIGN_CAPACITY, $DESIGN_VOLTAGE&lt;br /&gt;
&lt;br /&gt;
Battery health:&lt;br /&gt;
  First use date: $FIRST_USE_DATE&lt;br /&gt;
  Cycle count: $CYCLE_COUNT&lt;br /&gt;
  Last full capacity: $LAST_FULL_CAPACITY&lt;br /&gt;
  Average current / power (past 1 minute): $CURRENT_1MIN, $POWER_1MIN&lt;br /&gt;
&lt;br /&gt;
Battery status:&lt;br /&gt;
  Remaining capacity: $CAPACITY_MWH mWh ($CAPACITY_PERCENT)&lt;br /&gt;
  Remaining running time: $REMAINING_RUNNING_TIME&lt;br /&gt;
  Running current &amp;amp; power: $CURRENT_NOW, $POWER_NOW&lt;br /&gt;
  Temperature: $BATT_TEMPERATURE&lt;br /&gt;
  Voltage: $BATT_VOLTAGE&lt;br /&gt;
  Remaining charging time: $REMAINING_CHARGING_TIME&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
Battery charging control:&lt;br /&gt;
  Start charging at: $START_CHARGE_THRESH %&lt;br /&gt;
  Stop charging at: $STOP_CHARGE_THRESH %&lt;br /&gt;
  Prevent charging for: $INHIBIT_CHARGE_MIN min&lt;br /&gt;
  Force battery discharge: $BATT_FORCE_DISCHARGE&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
SHOW_ALL=&lt;br /&gt;
SHOW_BATT=&lt;br /&gt;
SHOW_MISC=&lt;br /&gt;
GOT_OPTS=&lt;br /&gt;
&lt;br /&gt;
while getopts ab:hm OPT&lt;br /&gt;
do&lt;br /&gt;
  GOT_OPTS=y&lt;br /&gt;
  case ${OPT} in&lt;br /&gt;
  a) SHOW_ALL=y;;&lt;br /&gt;
  b) if [ ${OPTARG} -eq 0 -o ${OPTARG} -eq 1 ]&lt;br /&gt;
     then&lt;br /&gt;
       SHOW_BATT=${OPTARG}&lt;br /&gt;
     else&lt;br /&gt;
       SHOW_BATT=y&lt;br /&gt;
     fi&lt;br /&gt;
     ;;&lt;br /&gt;
  h) show_help&lt;br /&gt;
     exit 0&lt;br /&gt;
     ;;&lt;br /&gt;
  m) SHOW_MISC=y;;&lt;br /&gt;
  \?) show_help&lt;br /&gt;
     exit 1&lt;br /&gt;
     ;;&lt;br /&gt;
  esac&lt;br /&gt;
done&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$GOT_OPTS&amp;quot; != y ]&lt;br /&gt;
then&lt;br /&gt;
  show_help&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$SHOW_ALL&amp;quot; == y ]&lt;br /&gt;
then&lt;br /&gt;
  show_misc&lt;br /&gt;
  show_batt 0&lt;br /&gt;
  show_batt 1&lt;br /&gt;
else&lt;br /&gt;
  if [ -n &amp;quot;$SHOW_MISC&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    show_misc&lt;br /&gt;
  fi&lt;br /&gt;
  if [ -n &amp;quot;$SHOW_BATT&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    show_batt $SHOW_BATT&lt;br /&gt;
  fi&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Switchable_Graphics&amp;diff=62647</id>
		<title>Switchable Graphics</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Switchable_Graphics&amp;diff=62647"/>
		<updated>2025-04-12T02:04:27Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Fixed broken link.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Select ThinkPads feature switchable graphics, where a low power consumption integrated GPU and high performance dedicated GPU is combined and you have the ability to switch between them, sacrificing either performance or battery life.&lt;br /&gt;
&lt;br /&gt;
In Windows XP this switching requires a logout/login, while in Vista and Windows 7 there is support for runtime switching.&lt;br /&gt;
&lt;br /&gt;
Under GNU/Linux, switching can be configured by entering BIOS setup and choosing between the &amp;quot;Internal&amp;quot; (low power, integrated), &amp;quot;External&amp;quot; (high performance, discrete) or &amp;quot;Switchable&amp;quot; (OS selectable) options.&lt;br /&gt;
&lt;br /&gt;
Depending on which GNU/Linux version you use, you could have the following effects&lt;br /&gt;
* On Ubuntu 8.10 (Intrepid) BIOS setting has to be either on Internal or External, not Switchable.&lt;br /&gt;
* On Ubuntu 9.10 (Karmic) the Integrated Intel card works with both Integrated or Switchable set&lt;br /&gt;
* On Ubuntu 13.10 and above, see [http://www.junauza.com/2014/03/how-to-get-nvidia-optimus-working-on-ubuntu-linux.html How to Get NVIDIA Optimus Working on Ubuntu]&lt;br /&gt;
&lt;br /&gt;
== Switchable Graphics and Docks ==&lt;br /&gt;
&lt;br /&gt;
ThinkPads with switchable graphics can only drive DVI or DisplayPort outputs on Docks by using the high-performance discrete graphics card, the integrated GPU is just not attached to the DVI or DisplayPort outputs (though VGA output through the dock is possible).&lt;br /&gt;
&lt;br /&gt;
== Improving Battery-life with Optimus ==&lt;br /&gt;
ThinkPads with NVidia Optimus graphics, have been well known to have significantly better battery-life in Windows than in GNU/Linux, even when GNU/Linux only uses the internal graphics. The reason is that the NVidia GPU is not automatically powered off when it is not used. So to get optimal battery-life in GNU/Linux on ThinkPad with Optimus, you need to switch it off manually (or by a script).&lt;br /&gt;
&lt;br /&gt;
First you need to enable access to vga-switcheroo settings, for that you need to mount the debugfs. You can do that by adding the following line to {{path|/etc/fstab}}:&lt;br /&gt;
  none            /sys/kernel/debug debugfs defaults 0 0&lt;br /&gt;
&lt;br /&gt;
After mounting that you can now access {{path|/usr/kernel/debug/vgaswitcheroo/switch}}. &lt;br /&gt;
&lt;br /&gt;
See which GPU is currently active (look for '+'), and which ones are powered (look for 'pwr'): &lt;br /&gt;
  {{cmdroot|cat /sys/kernel/debug/vgaswitcheroo/switch}}&lt;br /&gt;
&lt;br /&gt;
To force it to use the internal graphics write: &lt;br /&gt;
  {{cmdroot|echo 'IGD' &amp;gt; /sys/kernel/debug/vgaswitcheroo/switch}}&lt;br /&gt;
&lt;br /&gt;
To force it to use the discrete GPU: &lt;br /&gt;
  {{cmdroot|echo 'DES' &amp;gt; /sys/kernel/debug/vgaswitcheroo/switch}}&lt;br /&gt;
&lt;br /&gt;
Most importantly, to poweroff the currently unused GPU, run: &lt;br /&gt;
  {{cmdroot|echo 'OFF' &amp;gt; /sys/kernel/debug/vgaswitcheroo/switch}}&lt;br /&gt;
&lt;br /&gt;
Your average battery-life will greatly improved on the ThinkPad T420 if you only use intel integrated.&lt;br /&gt;
&lt;br /&gt;
== Development status ==&lt;br /&gt;
David Arlie worked on switching between GPUs without having to reboot or change BIOS settings. An initial version of a new driver (vga_switcheroo) was merged in the 2.6.34 kernel. This driver allowed switching between graphics cards, but required restarting the X server.&lt;br /&gt;
&lt;br /&gt;
http://www.phoronix.com/scan.php?page=news_item&amp;amp;px=ODAyMg&lt;br /&gt;
&lt;br /&gt;
Seamless runtime switching support required significant X server work, which was later completed. If free software graphics drivers are used, integrated or discrete graphics can now be selected via configuration of the DRI_PRIME environmental value globally, or per application.&lt;br /&gt;
&lt;br /&gt;
Generally, integrated is renderer 0 and discrete is renderer 1 as below (although it is possible for the order to be reversed);&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
DRI_PRIME=0 glxinfo | grep &amp;quot;OpenGL renderer&amp;quot;&lt;br /&gt;
OpenGL renderer string: &amp;lt;renderer&amp;gt;&lt;br /&gt;
DRI_PRIME=1 glxinfo | grep &amp;quot;OpenGL renderer&amp;quot;&lt;br /&gt;
OpenGL renderer string: &amp;lt;renderer&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To default to integrated for all graphical programs, add to .bash_profile;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#default to integrated&lt;br /&gt;
export DRI_PRIME=0&lt;br /&gt;
#default to discrete&lt;br /&gt;
#export DRI_PRIME=1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
You would comment the integrated export and uncomment the discrete export to default to discrete.&lt;br /&gt;
&lt;br /&gt;
Even with a default selection, you can still select which GPU to use at runtime by setting the DRI_PRIME variable (see the glxinfo example).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A script to switch between ATI discrete graphics with the fglrx driver and Intel integrated graphics with xorg driver through rebooting and selection in the bios is posted here.  The user must reboot, but no further configuration is needed as the script detects the card used and copies the correct libraries and configuration file.&lt;br /&gt;
&lt;br /&gt;
http://www.thinkwiki.org/wiki/Auto_detect_drivers_for_switchable_graphics&lt;br /&gt;
&lt;br /&gt;
It has been discovered that on a W500 running Windows 7 64-bit that the switch can be invoked using one of the two following commands (depending on which chipset is currently in use)&lt;br /&gt;
&lt;br /&gt;
{{cmd|C:\PROGRA~2\ThinkPad\UTILIT~1\PWMUIAux.exe /HighPerformanceGpu |}}&lt;br /&gt;
&lt;br /&gt;
{{cmd|C:\PROGRA~2\ThinkPad\UTILIT~1\PWMUIAux.exe /EnergySavingGpu |}}&lt;br /&gt;
&lt;br /&gt;
A small utility has been developed to switch between the chipsets with the ThinkVantage button, using Windows SetupAPI to detect the current chipset. More information and download of source and binary available here: http://entropicassembly.com/thinkpadgraphics/&lt;br /&gt;
&lt;br /&gt;
== ThinkPad models which may have this feature ==&lt;br /&gt;
* {{R400}}&lt;br /&gt;
* {{T400}}, {{T500}}, {{T510i}}, {{T420}}, {{T420s}}, {{T520}}, {{T430s}}&lt;br /&gt;
* {{W500}}, {{W520}}, {{W530}}&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Switchable_Graphics&amp;diff=62646</id>
		<title>Switchable Graphics</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Switchable_Graphics&amp;diff=62646"/>
		<updated>2025-04-12T02:02:05Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Linux is only a kernel. Updated information and added DRI_PRIME graphics switching information.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Select ThinkPads feature switchable graphics, where a low power consumption integrated GPU and high performance dedicated GPU is combined and you have the ability to switch between them, sacrificing either performance or battery life.&lt;br /&gt;
&lt;br /&gt;
In Windows XP this switching requires a logout/login, while in Vista and Windows 7 there is support for runtime switching.&lt;br /&gt;
&lt;br /&gt;
Under GNU/Linux, switching can be configured by entering BIOS setup and choosing between the &amp;quot;Internal&amp;quot; (low power, integrated), &amp;quot;External&amp;quot; (high performance, discrete) or &amp;quot;Switchable&amp;quot; (OS selectable) options.&lt;br /&gt;
&lt;br /&gt;
Depending on which GNU/Linux version you use, you could have the following effects&lt;br /&gt;
* On Ubuntu 8.10 (Intrepid) BIOS setting has to be either on Internal or External, not Switchable.&lt;br /&gt;
* On Ubuntu 9.10 (Karmic) the Integrated Intel card works with both Integrated or Switchable set&lt;br /&gt;
* On Ubuntu 13.10 and above, see [http://www.junauza.com/2014/03/how-to-get-nvidia-optimus-working-on-ubuntu-linux.html | How to Get NVIDIA Optimus Working on Ubuntu Linux]&lt;br /&gt;
&lt;br /&gt;
== Switchable Graphics and Docks ==&lt;br /&gt;
&lt;br /&gt;
ThinkPads with switchable graphics can only drive DVI or DisplayPort outputs on Docks by using the high-performance discrete graphics card, the integrated GPU is just not attached to the DVI or DisplayPort outputs (though VGA output through the dock is possible).&lt;br /&gt;
&lt;br /&gt;
== Improving Battery-life with Optimus ==&lt;br /&gt;
ThinkPads with NVidia Optimus graphics, have been well known to have significantly better battery-life in Windows than in GNU/Linux, even when GNU/Linux only uses the internal graphics. The reason is that the NVidia GPU is not automatically powered off when it is not used. So to get optimal battery-life in GNU/Linux on ThinkPad with Optimus, you need to switch it off manually (or by a script).&lt;br /&gt;
&lt;br /&gt;
First you need to enable access to vga-switcheroo settings, for that you need to mount the debugfs. You can do that by adding the following line to {{path|/etc/fstab}}:&lt;br /&gt;
  none            /sys/kernel/debug debugfs defaults 0 0&lt;br /&gt;
&lt;br /&gt;
After mounting that you can now access {{path|/usr/kernel/debug/vgaswitcheroo/switch}}. &lt;br /&gt;
&lt;br /&gt;
See which GPU is currently active (look for '+'), and which ones are powered (look for 'pwr'): &lt;br /&gt;
  {{cmdroot|cat /sys/kernel/debug/vgaswitcheroo/switch}}&lt;br /&gt;
&lt;br /&gt;
To force it to use the internal graphics write: &lt;br /&gt;
  {{cmdroot|echo 'IGD' &amp;gt; /sys/kernel/debug/vgaswitcheroo/switch}}&lt;br /&gt;
&lt;br /&gt;
To force it to use the discrete GPU: &lt;br /&gt;
  {{cmdroot|echo 'DES' &amp;gt; /sys/kernel/debug/vgaswitcheroo/switch}}&lt;br /&gt;
&lt;br /&gt;
Most importantly, to poweroff the currently unused GPU, run: &lt;br /&gt;
  {{cmdroot|echo 'OFF' &amp;gt; /sys/kernel/debug/vgaswitcheroo/switch}}&lt;br /&gt;
&lt;br /&gt;
Your average battery-life will greatly improved on the ThinkPad T420 if you only use intel integrated.&lt;br /&gt;
&lt;br /&gt;
== Development status ==&lt;br /&gt;
David Arlie worked on switching between GPUs without having to reboot or change BIOS settings. An initial version of a new driver (vga_switcheroo) was merged in the 2.6.34 kernel. This driver allowed switching between graphics cards, but required restarting the X server.&lt;br /&gt;
&lt;br /&gt;
http://www.phoronix.com/scan.php?page=news_item&amp;amp;px=ODAyMg&lt;br /&gt;
&lt;br /&gt;
Seamless runtime switching support required significant X server work, which was later completed. If free software graphics drivers are used, integrated or discrete graphics can now be selected via configuration of the DRI_PRIME environmental value globally, or per application.&lt;br /&gt;
&lt;br /&gt;
Generally, integrated is renderer 0 and discrete is renderer 1 as below (although it is possible for the order to be reversed);&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
DRI_PRIME=0 glxinfo | grep &amp;quot;OpenGL renderer&amp;quot;&lt;br /&gt;
OpenGL renderer string: &amp;lt;renderer&amp;gt;&lt;br /&gt;
DRI_PRIME=1 glxinfo | grep &amp;quot;OpenGL renderer&amp;quot;&lt;br /&gt;
OpenGL renderer string: &amp;lt;renderer&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To default to integrated for all graphical programs, add to .bash_profile;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#default to integrated&lt;br /&gt;
export DRI_PRIME=0&lt;br /&gt;
#default to discrete&lt;br /&gt;
#export DRI_PRIME=1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
You would comment the integrated export and uncomment the discrete export to default to discrete.&lt;br /&gt;
&lt;br /&gt;
Even with a default selection, you can still select which GPU to use at runtime by setting the DRI_PRIME variable (see the glxinfo example).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A script to switch between ATI discrete graphics with the fglrx driver and Intel integrated graphics with xorg driver through rebooting and selection in the bios is posted here.  The user must reboot, but no further configuration is needed as the script detects the card used and copies the correct libraries and configuration file.&lt;br /&gt;
&lt;br /&gt;
http://www.thinkwiki.org/wiki/Auto_detect_drivers_for_switchable_graphics&lt;br /&gt;
&lt;br /&gt;
It has been discovered that on a W500 running Windows 7 64-bit that the switch can be invoked using one of the two following commands (depending on which chipset is currently in use)&lt;br /&gt;
&lt;br /&gt;
{{cmd|C:\PROGRA~2\ThinkPad\UTILIT~1\PWMUIAux.exe /HighPerformanceGpu |}}&lt;br /&gt;
&lt;br /&gt;
{{cmd|C:\PROGRA~2\ThinkPad\UTILIT~1\PWMUIAux.exe /EnergySavingGpu |}}&lt;br /&gt;
&lt;br /&gt;
A small utility has been developed to switch between the chipsets with the ThinkVantage button, using Windows SetupAPI to detect the current chipset. More information and download of source and binary available here: http://entropicassembly.com/thinkpadgraphics/&lt;br /&gt;
&lt;br /&gt;
== ThinkPad models which may have this feature ==&lt;br /&gt;
* {{R400}}&lt;br /&gt;
* {{T400}}, {{T500}}, {{T510i}}, {{T420}}, {{T420s}}, {{T520}}, {{T430s}}&lt;br /&gt;
* {{W500}}, {{W520}}, {{W530}}&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Install_Mandriva_2009.0_on_a_ThinkPad_W500&amp;diff=62645</id>
		<title>Install Mandriva 2009.0 on a ThinkPad W500</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Install_Mandriva_2009.0_on_a_ThinkPad_W500&amp;diff=62645"/>
		<updated>2025-04-12T01:36:33Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Linux is only a kernel. Spelling. Added correction about EC mute.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[:Category:W500|W500]] {{NOTE|The below issues have been fixed in later GNU/Linux versions, but they have been left in case someone decides to try installing Mandriva 2009.0 for some reason.}}&lt;br /&gt;
&lt;br /&gt;
==BIOS Issues==&lt;br /&gt;
&lt;br /&gt;
* [[Switchable Graphics]]&lt;br /&gt;
GNU/Linux with X.Org previously lacked the support for on-the-fly switching of GPUs. It not only did not support switching, you also had to explicitly turn off switching in BIOS. Go to Config-&amp;gt;Display-&amp;gt;Graphics Device and '''DISABLE''' OS detection of switchable graphics.&lt;br /&gt;
&lt;br /&gt;
If you don't disable OS detection, Linux will enumerate two graphic adapters (see `lspci` output) and X.Org will be confused as to which one to use, leading to random weird side effects such as hangs and worse.&lt;br /&gt;
&lt;br /&gt;
* AHCI&lt;br /&gt;
I also had to turn off AHCI in Config-&amp;gt;SATA and used '''Compatibility Mode''' instead, otherwise the kernel would not boot occasionally.&lt;br /&gt;
&lt;br /&gt;
* Intel Virtualization&lt;br /&gt;
The T9400 and up CPUs also support advanced Intel Virtualization technologies. Just don't turn on '''VT-d''' (disk I/O virtualization) in BIOS, otherwise WLAN any a couple of other things will not work and even freeze your system, see [https://qa.mandriva.com/show_bug.cgi?id=44711 https://qa.mandriva.com/show_bug.cgi?id=44711]&lt;br /&gt;
&lt;br /&gt;
==Things not working/issues==&lt;br /&gt;
&lt;br /&gt;
As I've found most of the components are just working out of the box, I will only list the issues I have found so far:&lt;br /&gt;
&lt;br /&gt;
* booting with &amp;quot;vga=788&amp;quot; not working&lt;br /&gt;
** the Mandriva installer added the &amp;quot;vga=788&amp;quot; parameter to my Linux boot line. That prevented the laptop from booting quite frequently, not always though. Still to be investigated, but removing &amp;quot;vga=788&amp;quot; from the kernel boot line solved the issue for now.&lt;br /&gt;
* [[Active Protection System]]&lt;br /&gt;
** HD-APS is not working for me, probably due to a BIOS bug, see [http://bugzilla.kernel.org/show_bug.cgi?id=12221 http://bugzilla.kernel.org/show_bug.cgi?id=12221]&lt;br /&gt;
*** some kind of workaround is to add pnpacpi=off to the kernel boot line, but that turns off ACPI, which is no real option&lt;br /&gt;
* Suspend/Resume&lt;br /&gt;
** while suspending works fine, resuming always ended with a blank screen, workaround below&lt;br /&gt;
* muted audio not shown in alsamixer&lt;br /&gt;
** when you use the built in &amp;quot;mute audio&amp;quot; button on the ThinkPad keyboard, the EC does a hardware mute without sending a XF86AudioMute event, so the mute state will not show in any audio mixer. So if you don't hear a sound, press the &amp;quot;mute audio&amp;quot; or &amp;quot;volume up&amp;quot; button to unmute :-)&lt;br /&gt;
* 3D and radeonhd&lt;br /&gt;
** the radeonhd driver did not support 3D acceleration&lt;br /&gt;
* 2D and fglrx&lt;br /&gt;
** see below&lt;br /&gt;
&lt;br /&gt;
== Suspend/Resume problem ==&lt;br /&gt;
&lt;br /&gt;
If resuming just leaves you with a blank black display, try the following:&lt;br /&gt;
&lt;br /&gt;
  echo &amp;quot;ADD_PARAMETERS='--quirk-vbe-post'&amp;quot; &amp;gt; /etc/pm/config.d/w500_vbe_post&lt;br /&gt;
&lt;br /&gt;
== Display / Xorg ==&lt;br /&gt;
&lt;br /&gt;
The laptop comes with [[Switchable Graphics]], so you can choose on your own which GPU to use:&lt;br /&gt;
&lt;br /&gt;
* intel&lt;br /&gt;
** consumes the least energy&lt;br /&gt;
** DVI connector on the [[ThinkPad Advanced Mini Dock]] ist not recognoized&lt;br /&gt;
** a static dual head configuration gives weird background garbage when one of the statically configured monitors is not connected, see [http://bugs.freedesktop.org/show_bug.cgi?id=19412 http://bugs.freedesktop.org/show_bug.cgi?id=19412]&lt;br /&gt;
&lt;br /&gt;
* radeonhd&lt;br /&gt;
** consumes the most energy&lt;br /&gt;
** lack of 3D support&lt;br /&gt;
&lt;br /&gt;
* fglrx&lt;br /&gt;
** changing runlevel to 3 (init 3) leaves you with X eating 100% CPU&lt;br /&gt;
** huge performance issues when switching between virtual desktops, switching can take a couple of seconds with 100% CPU again&lt;br /&gt;
&lt;br /&gt;
So if battery life and 3D are important for you, you should probably use the intel driver, but I am fine with the radeonhd driver for now. And fglrx is nothing but proprietary nonsense, IMHO ... for a '''commercial''' driver this is ridiculous.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:W500]][[Category:Mandriva]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Category:W500&amp;diff=62644</id>
		<title>Category:W500</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Category:W500&amp;diff=62644"/>
		<updated>2025-04-12T01:12:07Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Those are GNU/Linux distro's, so you are installing GNU/Linux and not just Linux.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== ThinkPad W500 ===&lt;br /&gt;
&lt;br /&gt;
This page gives an overview of the ThinkPad W500.&lt;br /&gt;
&lt;br /&gt;
==== Standard Features ====&lt;br /&gt;
* [[Intel Core 2 Duo (Penryn)]] 2.4, 2.6, 2.8GHz 1066MHz FSB, 6MB L2 Cache CPU&lt;br /&gt;
* [[Switchable Graphics]] graphics with the following graphics cards&lt;br /&gt;
** [[ATI Mobility FireGL V5700]] (512 MB)&lt;br /&gt;
** [[ATI Mobility Radeon HD 3650]] (256 MB)&lt;br /&gt;
** [[Intel Graphics Media Accelerator 4500MHD]]&lt;br /&gt;
* One of the following [[TFT display]]s:&lt;br /&gt;
** 15.4&amp;quot; TFT display with 1680x1050 (WSXGA+) resolution&lt;br /&gt;
** 15.4&amp;quot; TFT display with 1920x1200 (WUXGA) resolution&lt;br /&gt;
* 2GB [[PC3-8500]] memory standard upgradable to 8GB&lt;br /&gt;
* 80GB 2.5&amp;quot; SATA HDD&lt;br /&gt;
* 100GB 2.5&amp;quot; SATA HDD&lt;br /&gt;
* 160GB 2.5&amp;quot; SATA HDD&lt;br /&gt;
* 200GB 7200rpm 2.5&amp;quot; SATA HDD (available with encryption)&lt;br /&gt;
* 250GB 2.5&amp;quot; SATA HDD&lt;br /&gt;
* 320GB 5400rpm 2.5&amp;quot; SATA HDD&lt;br /&gt;
* 64GB 1.8&amp;quot; SSD HDD (Solid State Disk)&lt;br /&gt;
* 80GB 1.8&amp;quot; SSD HDD (Solid State Disk)&lt;br /&gt;
* 128GB 1.8&amp;quot; SSD HDD (Solid State Disk)&lt;br /&gt;
** [[Full Disk Encryption (FDE)]] Available on some models&lt;br /&gt;
* [[Intel Gigabit Ethernet (10/100/1000) PCI-Express]]&lt;br /&gt;
* [[ThinkPad Modem (MDC-3.0, 56kbps HDA)]]&lt;br /&gt;
* [[Ultrabay|Serial Ultrabay Slim]] with one of the following:&lt;br /&gt;
**[[Serial Ultrabay Slim DVD-ROM Drive]]&lt;br /&gt;
**[[Serial Ultrabay Slim CD-RW/DVD combo Drive]]&lt;br /&gt;
**[[Serial Ultrabay Slim DVD Burner]]&lt;br /&gt;
**[[Serial Ultrabay Slim Blu-ray Burner]]&lt;br /&gt;
* [[MiniPCI Express slot]] 1 with one of the following:&lt;br /&gt;
** None (empty)&lt;br /&gt;
** [[Intel Wifi Link 5100 (AGN)]]&lt;br /&gt;
** [[Intel Wifi Link 5300 (AGN)]]&lt;br /&gt;
** [[Intel WiMAX/WiFi Link 5150/5350 WiFi/WiMAX controller]]&lt;br /&gt;
* [[MiniPCI Express slot]] 2 with one of the following:&lt;br /&gt;
** None (empty)&lt;br /&gt;
** [[Sierra Wireless MC5725|Verizon Mobile Broadband]]&lt;br /&gt;
** [[Ericsson F3507g Mobile Broadband Module|AT&amp;amp;T Mobile Broadband with GPS]]&lt;br /&gt;
** [[Intel® Turbo Memory hard drive cache]] up to 2GB&lt;br /&gt;
* 1 [[CardBus slot]] (Type 2)&lt;br /&gt;
* 1 Slot with one of the following:&lt;br /&gt;
** [[ExpressCard slot|ExpressCard/54 slot]] &lt;br /&gt;
** [[Lenovo Integrated Smart Card Reader]]&lt;br /&gt;
* [[Ricoh_R5C843|4-in-1 Memory reader]]&lt;br /&gt;
* 1.3MP [[Integrated camera]] on select models&lt;br /&gt;
* [[Embedded Security Subsystem|Trusted Computing Group TPM 1.2]]&lt;br /&gt;
* [[Active Protection System]]&lt;br /&gt;
* [[Integrated Fingerprint Reader]] on select models&lt;br /&gt;
* [[ThinkPad_Bluetooth_with_Enhanced_Data_Rate_(BDC-2.1)|Bluetooth]] on select models&lt;br /&gt;
* [[UltraNav]] (TrackPoint / Touchpad combo)&lt;br /&gt;
* [[Firewire Port|Firewire 400]] (IEEE1394a)&lt;br /&gt;
* [[DisplayPort]]&lt;br /&gt;
* [[Intel Active Management Technology (AMT)]] on select models&lt;br /&gt;
* Intel HD Audio with a [[CX20561]] codec&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
[[Image:ThinkPadW500.jpg|ThinkPad W500|300px]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GNU/Linux Installation ===&lt;br /&gt;
&lt;br /&gt;
*[[Install Mandriva 2009.0 on a ThinkPad W500]]&lt;br /&gt;
*[[Install Lucid Lynx on a ThinkPad W500]]&lt;br /&gt;
&lt;br /&gt;
[[Category:W Series]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Intel_GMA_4500MHD&amp;diff=62643</id>
		<title>Intel GMA 4500MHD</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Intel_GMA_4500MHD&amp;diff=62643"/>
		<updated>2025-04-12T01:10:31Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: X.org is not Linux. Linux is only a kernel. intel-gfx is for Xorg, although it's xf86-video-intel now (I can't tell if anyone bothered to implement video acceleration for the 4500MHD).&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== Intel Graphics Media Accelerator 4500MHD ===&lt;br /&gt;
This is an Intel video adapter&lt;br /&gt;
&lt;br /&gt;
=== Features ===&lt;br /&gt;
* Integrated into the following chipsets:&lt;br /&gt;
** [[Intel GM45]]&lt;br /&gt;
* PCI ID: 8086:2a42&lt;br /&gt;
* Uses part of main memory for video usage&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Linux KMS ==&lt;br /&gt;
KMS (Kernel Mode Setting) is a recent development, and requires that you have at least kernel 2.6.31 and Intel Xorg driver version 2.8. But newer is better. With the 2.6.32 kernel and Intel Xorg driver 2.9 you can expect full functionality including external displays and 3D acceleration. However, Linux &amp;gt;=3.19 should be used because it includes a fix for a [https://bbs.archlinux.org/viewtopic.php?id=190528 Graphics Corruption Bug].&lt;br /&gt;
&lt;br /&gt;
== X.Org driver User Mode Setting ==&lt;br /&gt;
{{NOTE|UMS where the mode setting is done by the Xorg driver in user-land is deprecated and newer versions of the Intel Xorg driver (v2.10+) no longer support it. Instead you will have to use KMS (Kernel Mode Setting)}}&lt;br /&gt;
&lt;br /&gt;
Make sure you're using Intel Xorg driver, version 2.8 or 2.9.&lt;br /&gt;
&lt;br /&gt;
== HD video acceleration ==&lt;br /&gt;
The hardware does support acceleration of video decoding, but it's not yet supported by X.Org's intel-gfx. Support '''was''' supposed to arrive in [http://lists.freedesktop.org/archives/intel-gfx/2010-March/006404.html Q3 2010] via libva. There is already MPEG2 acceleration for this chip though.&lt;br /&gt;
&lt;br /&gt;
== ThinkPad models with this component==&lt;br /&gt;
* {{Edge 13&amp;quot;}} (Intel)&lt;br /&gt;
* {{R400}}, {{R500}}&lt;br /&gt;
* {{SL300}}, {{SL400}}, {{SL400c}}, {{SL410}}, {{SL500}}, {{SL500c}}, {{SL510}}&lt;br /&gt;
* {{T400}}, {{T400s}}, {{T500}}&lt;br /&gt;
* {{W500}}&lt;br /&gt;
* {{X200}}, {{X200s}}, {{X200 Tablet}}, {{X301}}&lt;br /&gt;
&lt;br /&gt;
== Resources ==&lt;br /&gt;
* [https://web.archive.org/web/20100811005120/http://www.intel.com/design/chipsets/embedded/GM45/index.htm http://www.intel.com/design/chipsets/embedded/GM45/index.htm (archived from the original)]&lt;br /&gt;
* http://www.notebookcheck.net/Intel-Graphics-Media-Accelerator-4500MHD-GMA-X4500MHD.9883.0.html&lt;br /&gt;
* https://01.org/linuxgraphics&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=ATI_Mobility_Radeon_X1300&amp;diff=62642</id>
		<title>ATI Mobility Radeon X1300</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=ATI_Mobility_Radeon_X1300&amp;diff=62642"/>
		<updated>2025-04-12T00:57:23Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Linux is not X.Org. Linux's terminal emulator is called fbcon.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Features ==&lt;br /&gt;
* Chipset: ATI M52&lt;br /&gt;
* PCI ID: 1002:7149&lt;br /&gt;
* PCI Express x16&lt;br /&gt;
* 64MB GDDR1 video memory&lt;br /&gt;
&lt;br /&gt;
== X.Org driver ==&lt;br /&gt;
Supported by either recent versions of the [[radeon]] driver or the [[radeonhd]] driver (availible in debian stable). &lt;br /&gt;
3D is even working with latest versions of mesa (7.1rc3) and xorg from debian experimental (as of July 20, 2008).&lt;br /&gt;
&lt;br /&gt;
== ThinkPad LCD ==&lt;br /&gt;
Display on the internal LCD works as long as you set the monitor settings correct.&lt;br /&gt;
&lt;br /&gt;
== External VGA port ==&lt;br /&gt;
Using the radeon driver, VGA port is enabled or disabled by using &amp;quot;xrandr --auto&amp;quot; if something is plugged in or unplugged.&lt;br /&gt;
&lt;br /&gt;
== SVideo port ==&lt;br /&gt;
??&lt;br /&gt;
&lt;br /&gt;
== DVI port ==&lt;br /&gt;
DVI port is enabled in T60.&lt;br /&gt;
&lt;br /&gt;
Using the proprietary driver the Dell 2405FPW works at 1920x1200 pixels via Advanced Mini Dock.&lt;br /&gt;
&lt;br /&gt;
== Proprietary ATI driver ==&lt;br /&gt;
[[Fglrx]] supports this card since release 8.24.8.&lt;br /&gt;
&lt;br /&gt;
driver by ATI&lt;br /&gt;
&lt;br /&gt;
https://support.ati.com/ics/support/KBAnswer.asp?questionID=18875&lt;br /&gt;
&lt;br /&gt;
== Linux fbcon Framebuffer driver ==&lt;br /&gt;
* OS: RHEL4-U3&lt;br /&gt;
* Kernel: 2.6.9-34&lt;br /&gt;
* X Version: 6.8.2-1&lt;br /&gt;
* Result: ''Failure''&lt;br /&gt;
** Driver can't find a compatible card&lt;br /&gt;
&lt;br /&gt;
== ThinkPads this chip may be found in ==&lt;br /&gt;
* {{T60}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Video Controllers]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Problem_with_high_pitch_noises&amp;diff=62641</id>
		<title>Problem with high pitch noises</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Problem_with_high_pitch_noises&amp;diff=62641"/>
		<updated>2025-04-12T00:56:11Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Linux is not an OS. Typo.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Information on strange high pitch, low volume noises emitted by ThinkPads.&lt;br /&gt;
&lt;br /&gt;
==Problem description==&lt;br /&gt;
Even though ThinkPads are known as very silent notebooks, they tend to emit different, mostly high pitch noises in certain circumstances. The noises are of low volume and hence not realized by everyone or at least tolerated by most people. However, there are those with &amp;quot;bat like ears&amp;quot; that hear them and might be annoyed by that.&lt;br /&gt;
&lt;br /&gt;
==Affected Models==&lt;br /&gt;
Noises have been experienced in the following situations:&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! style=&amp;quot;vertical-align:top;background-color:#DDDDDD;&amp;quot; | situation&lt;br /&gt;
! style=&amp;quot;vertical-align:top;background-color:#DDDDDD;&amp;quot; | noise description&lt;br /&gt;
! style=&amp;quot;vertical-align:top;background-color:#DDDDDD;&amp;quot; | affected models&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
Plugged into AC / running at high CPU frequency&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
soft crackling, buzzing noise&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{T41}}&lt;br /&gt;
**2379-DJU&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
ThinkPad suspended to RAM&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
constant high pitch noise&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{T42p}}&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
ThinkPad connected to power and switched off, with battery fully charged&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
constant high pitch noise&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{T41p}}&lt;br /&gt;
**2373-GHG&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
moving windows or just the mouse in xorg&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
strange noise like a rapid series of very short high pitch noises adding to a constant kind of whistling (only as long as the movement goes)&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{A21m}}&lt;br /&gt;
**2628&lt;br /&gt;
*{{T41p}}&lt;br /&gt;
**2373-GHG&lt;br /&gt;
*{{T60}}&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
Thinkpad connected to power or working on battery, also when suspended to RAM&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
High pitch noise also when HD is powered down.&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{T23}}&lt;br /&gt;
**2647-DG4&lt;br /&gt;
*{{X24}}&lt;br /&gt;
**2662-MWG&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
Thinkpad connected to power battery charged less than 60%&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
High pitch noise till battery is charged more than 60%.&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{T41p}}&lt;br /&gt;
**2373-GEG&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
Constantly, if AC connected&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
High pitched, low volume constant noise.&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{T40}}&lt;br /&gt;
**2373-88U&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
When the CPU freq jumps up to 1Ghz or above, or when the laptop is in suspend mode&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
Constant high pitched&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{R50}}&lt;br /&gt;
**1829-6DM&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
(May come from harddisk.)&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
continuous, intermittent, low volume, high pitched&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{600X}}&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
ACPI puts the processor into the C3 or C4 power saving states (i.e., the system is idle).&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
High-pitched crackling noise.&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{X61}}&lt;br /&gt;
**7673-B56&lt;br /&gt;
*{{X41}}&lt;br /&gt;
*{{T43}}&lt;br /&gt;
**2686-DGU&lt;br /&gt;
*{{T43p}}&lt;br /&gt;
*{{T60}}&lt;br /&gt;
**2007-72U&lt;br /&gt;
*{{T21}}&lt;br /&gt;
*{{T20}}&lt;br /&gt;
**2648-46U&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
Cpufreqd (or powernowd etc.) slows down the processor, for exemple at the end of an heavy task.&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
High-pitched crackling noise.&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{T42}}&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
When on battery&lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
Noise level varies from inaudible to clearly audible, screeching sound, or sometimes beeping (when wifi is on). &lt;br /&gt;
| style=&amp;quot;vertical-align:top;&amp;quot; |&lt;br /&gt;
*{{A21m}}&lt;br /&gt;
**2628&lt;br /&gt;
*{{R51}}&lt;br /&gt;
**EHG-1829&lt;br /&gt;
*{{R52}}&lt;br /&gt;
**1858-A11&lt;br /&gt;
**1846-B5G&lt;br /&gt;
*{{R60}}&lt;br /&gt;
**9461-DXG&lt;br /&gt;
**9462-77G&lt;br /&gt;
**9456-HTG&lt;br /&gt;
**9461-DXG&lt;br /&gt;
*{{R60e}}&lt;br /&gt;
**0657-A9G&lt;br /&gt;
**0657-3LG&lt;br /&gt;
*{{T43}}&lt;br /&gt;
**2686-DGU&lt;br /&gt;
**1871-4AG&lt;br /&gt;
*{{T60}}&lt;br /&gt;
**2007-72U&lt;br /&gt;
**1951-24G&lt;br /&gt;
**1951-24G&lt;br /&gt;
**2007-49G&lt;br /&gt;
**2007-FUG&lt;br /&gt;
*{{T60p}}&lt;br /&gt;
**2007-FBG&lt;br /&gt;
*{{T61}}&lt;br /&gt;
**7659-12G&lt;br /&gt;
**8898-5FG&lt;br /&gt;
**6463-9WG&lt;br /&gt;
*{{x60}}&lt;br /&gt;
*{{x31}}&lt;br /&gt;
**2673-CBU&lt;br /&gt;
*{{Z61m}}&lt;br /&gt;
**9450-3HG&lt;br /&gt;
**9452-128&lt;br /&gt;
**9452-W5Q&lt;br /&gt;
*{{Z61t}}&lt;br /&gt;
**9440-2QU&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| CPU is used much AND laptop is on AC power AND the TFT panel is enabled.&lt;br /&gt;
| Screetching high pitch noise, like a million crickets&lt;br /&gt;
| &lt;br /&gt;
* {{X41}}&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Network is pluged in and networkload is ~100%.&lt;br /&gt;
| low volume highfreq. pitch noise from left speaker or cpu.&lt;br /&gt;
|&lt;br /&gt;
*{{Z60m}}, {{Z60t}}&lt;br /&gt;
*{{T40}}&lt;br /&gt;
*{{T43}}&lt;br /&gt;
**2687-DDU&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Constant, but is louder when Tablet Pen is near screen, on battery power&lt;br /&gt;
| high pitch noise, screeching sounds *solved by &amp;quot;Media player paused&amp;quot; (see below) and also by BIOS versions 1.05 and later.&lt;br /&gt;
|&lt;br /&gt;
*{{X60_Tablet}}&lt;br /&gt;
**6366-4DU&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| When fan is running on some speeds. Turning off fan stops pitch noise instandly.&lt;br /&gt;
| High pitch noise (&amp;quot;CPU whining&amp;quot;). &lt;br /&gt;
|&lt;br /&gt;
*{{T60p}}&lt;br /&gt;
**2007-83G&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Affected Operating Systems==&lt;br /&gt;
All, though GNU/Linux appears especially susceptible.&lt;br /&gt;
&lt;br /&gt;
==Possible sources==&lt;br /&gt;
&lt;br /&gt;
* '''CPU activity:''' On some models the noise is triggered by certain CPU power states or activity patterns (as proven [http://www.wisdom.weizmann.ac.il/~tromer/acoustic here]).&lt;br /&gt;
* '''Graphics processor:''' In some models from the T2x era, e.g. the {{T23}}, the problem was related to the graphics circuitry and occured especially or only while making use of DirectDraw functions. IBM was able to fix it through a BIOS upgrade.&lt;br /&gt;
* '''Hard disk:''' On some ThinkPads the processor and hard disk are adjacent and produce similar noise. For example, in the {{X41}} the sound generated by the hard disk is likely to be loudest at the vent.&lt;br /&gt;
* '''Gigabit Ethernet processor:''' In some models (e.g., {{T43}}) high ethernet activity causes a high pitch noise.&lt;br /&gt;
* '''Screen brightness:''' on an {{X31}}, a hissing sound is started whenever screen brightness is not full.&lt;br /&gt;
* '''Power supply:''' a T61p is known to have the sound if a 90W power supply revision 01 is used. An alternative power supply of an other manufacturer did not make the laptop noisy.&lt;br /&gt;
&lt;br /&gt;
==Status==&lt;br /&gt;
&lt;br /&gt;
The problem is highly specific to operating system, model and even individual machines. There is no universal solution, but on most machines one of the following will reduce or eliminate the noise (possibly at some cost in power consumption).&lt;br /&gt;
&lt;br /&gt;
==Solutions for CPU-triggered noise==&lt;br /&gt;
&lt;br /&gt;
===Limit ACPI CPU power states===&lt;br /&gt;
&lt;br /&gt;
By default, the kernel supports up to eight ACPI CPU power saving states (C-states), called C1 through C8 (but the ThinkPad BIOS and hardware often offers (or remaps them to) only C1 to C4). Often only the extreme power saving modes C4 or C3 produce the noise, so the noise can be stopped by instructing the Linux ACPI code to use only lower modes. This has a cost, though: disabling C3 and C4 will make the CPU consume more power and reduce battery life. &lt;br /&gt;
&lt;br /&gt;
To forbid the ACPI driver from using C4 (this fixed the problem with on some ThinkPad {{T43}}, {{T43p}} and {{T41}}):&lt;br /&gt;
* If the ACPI processor component is compiled as built-in (&amp;lt;tt&amp;gt;CONFIG_ACPI_PROCESSOR=y&amp;lt;/tt&amp;gt;):&lt;br /&gt;
**Pass the {{bootparm|processor.max_cstate|3}} kernel argument.&lt;br /&gt;
* If the ACPI processor component is loaded as a module (&amp;lt;tt&amp;gt;CONFIG_ACPI_PROCESSOR=m&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;processor&amp;lt;/tt&amp;gt; shows in the output of {{cmdroot|lsmod}}), do either of:&lt;br /&gt;
** Pass the {{bootparm|processor.max_cstate|3}} kernel argument (this does not work in Ubuntu 5.10 with default kernel).&lt;br /&gt;
** Add &amp;lt;code&amp;gt;options processor max_cstate=3&amp;lt;/code&amp;gt; to {{path|/etc/modprobe.conf}} (or {{path|/etc/modprobe.conf.local}}, or {{path|/etc/modprobe.d/...}}, depending on your system) (this does not work in Ubuntu 5.10 with default kernel).&lt;br /&gt;
** {{cmdroot|echo 3 &amp;gt;  /sys/module/processor/parameters/max_cstate}} (this can be changed in runtime for experimentation). (If may need to be set again upon resume from suspend, e.g., in the wakeup script.)&lt;br /&gt;
** (On Ubuntu 5.10, the default kernel uses &amp;lt;code&amp;gt;processor&amp;lt;/code&amp;gt; as a module.  Unfortunately, the script loading it, {{path|/etc/init.d/acpid}}, ignores the &amp;lt;code&amp;gt;options processor max_cstate=3&amp;lt;/code&amp;gt; setting in {{path|/etc/modprobe.d/&amp;lt;my file&amp;gt;}}.  As a solution for this specific problem, add the line &amp;lt;code&amp;gt;echo 2 &amp;gt; /sys/module/processor/parameters/max_cstate&amp;lt;/code&amp;gt; directly to {{path|/etc/init.d/acpid}}, at the end of the function &amp;lt;code&amp;gt;load_modules()&amp;lt;/code&amp;gt;, immediately after the line &amp;lt;code&amp;gt;echo &amp;quot;$PRINTK&amp;quot; &amp;gt; /proc/sys/kernel/printk&amp;lt;/code&amp;gt;.)&lt;br /&gt;
** On Gentoo: Configure your Thinkpad as described in the [http://www.gentoo.org/doc/en/power-management-guide.xml Power Management Guide].  Then as root create the files {{path|/etc/init.d/limit-sleep-states}} and {{path|/etc/conf.d/limit-sleep-states}} as below. After that just issue the command {{cmdroot|rc-update add limit-sleep-states default}} to limit the sleep states only when running on AC power, or {{cmdroot|rc-update add limit-sleep-states default battery}} to always limit the sleep states.&lt;br /&gt;
 cat &amp;lt;&amp;lt;EOF &amp;gt; /etc/init.d/limit-sleep-states&lt;br /&gt;
 #!/sbin/runscript&lt;br /&gt;
 &lt;br /&gt;
 depend() {&lt;br /&gt;
 	need acpid&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 start() {&lt;br /&gt;
 	ebegin &amp;quot;Limiting CPU sleep state to C${LIMIT_CSTATE}&amp;quot;&lt;br /&gt;
 	echo $LIMIT_CSTATE &amp;gt; /sys/module/processor/parameters/max_cstate&lt;br /&gt;
 	eend $?&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 stop() {&lt;br /&gt;
        ebegin &amp;quot;Removing CPU sleep state limit&amp;quot;&lt;br /&gt;
        echo $REMOVE_CSTATE &amp;gt; /sys/module/processor/parameters/max_cstate&lt;br /&gt;
        eend $?&lt;br /&gt;
 }&lt;br /&gt;
 EOF&lt;br /&gt;
&lt;br /&gt;
 cat &amp;lt;&amp;lt;EOF &amp;gt; /etc/conf.d/limit-sleep-states&lt;br /&gt;
 # limit CPU sleep state to the following value (adjust accordingly)&lt;br /&gt;
 LIMIT_CSTATE=3&lt;br /&gt;
 # some value which is higher than all available sleep states&lt;br /&gt;
 REMOVE_CSTATE=8&lt;br /&gt;
 EOF&lt;br /&gt;
&lt;br /&gt;
To also forbid the C3 state, replace &amp;quot;&amp;lt;tt&amp;gt;3&amp;lt;/tt&amp;gt;&amp;quot; with &amp;quot;&amp;lt;tt&amp;gt;2&amp;lt;/tt&amp;gt;&amp;quot; above (this fixed the problem on some ThinkPad {{X40}}, {{X41}}, {{X60}}, {{T60}}, {{T61}}, {{Z61t}} and {{R52}}, as well as on {{T20}} where C4 is not supported at all).&lt;br /&gt;
&lt;br /&gt;
Note that these options affect power consumption when the CPU is idle. For example, here is the [[How to measure power consumption|measured power consumption]] on a ThinkPad {{T43}}:&lt;br /&gt;
* {{bootparm|processor.max_cstate|4}}: 15160mW (default, noisy)&lt;br /&gt;
* {{bootparm|processor.max_cstate|3}}: 15770mW (660mW higher, silent)&lt;br /&gt;
* {{bootparm|processor.max_cstate|2}}: 16100mW (2940mW higher, silent)&lt;br /&gt;
&lt;br /&gt;
One can control how often Linux tries to enter the C3 state by using the {{bootparm|processor.bm_history|&amp;lt;bitmask&amp;gt;}} parameter on kernels with a scheduler frequency below 800Hz (and if you have noise problems, you really should not be running the kernel at 1000Hz...).  Setting {{bootparm|processor.bm_history|0xFFFFFFFF}} will cause C3 to be entered less often.  This will waste more power as the CPU won't do C3 or C4 as often, but at least it doesn't forbid C3 and C4 permanently, unlike {{bootparm|max_cstate|2}}.&lt;br /&gt;
&lt;br /&gt;
See the [http://thinkwiki.org/wiki?title=Talk:Problem_with_high_pitch_noises discussion page] for further information and success reports.&lt;br /&gt;
&lt;br /&gt;
*Jakob Schou Pedersen: Editing the file {{path|/etc/init.d/acpid}} as described above (the last solution) worked on my T43 :-)&lt;br /&gt;
&lt;br /&gt;
===MS Windows: Disable CPU popup mode ===&lt;br /&gt;
&lt;br /&gt;
This is a generic solution for Core 2 Duo platforms --- using the RMClock utility you can disable C4 to C1/C2/C3 transition and force the CPU to go straight to C0. To do this, in RMClock settings go to: &amp;quot;Enable Advanced CPU settings &amp;gt; Chipset&amp;quot; and disable at least &amp;quot;Enable Popup Mode&amp;quot;. Related discussion can be found here: [[http://forum.thinkpads.com/viewtopic.php?f=30&amp;amp;t=75283]].&lt;br /&gt;
&lt;br /&gt;
===Turn off CPU power saving in the BIOS===&lt;br /&gt;
&lt;br /&gt;
Go into the BIOS and turn off the power saving processor feature that puts it into idle mode.  This should be somewhere under Config/Power - look for &amp;quot;CPU Power Management&amp;quot;, the default being automatic.  Set &amp;quot;CPU Power Management&amp;quot; to &amp;quot;Disabled&amp;quot; (This worked on a ThinkPad {{T21}}, {{T43}}, {{T60}}, {{X60s}}, {{X200s}} and {{Z61m}}). However, this also affects power consumption when the CPU is idle, it's similar to disabling the C4/C3 ACPI CPU power state. For example, on a Z61m 9450-3HG, a full charged battery with power management enabled in the BIOS provides the notebook with power for about 3.5h, if disabled, the battery-lifetime is only about 2h.&lt;br /&gt;
&lt;br /&gt;
===Disable ACPI CPU power states===&lt;br /&gt;
&lt;br /&gt;
Completely disable CPU ACPI power states. Discussion:&lt;br /&gt;
&lt;br /&gt;
*From Martin Steigerwald: I made the observation that I get at least less high pitch noises on my {{T23}} when I do not use the two ACPI modules &amp;quot;processor&amp;quot; and &amp;quot;thermal&amp;quot; (depends on the first one). I have no clue, why. Anyone with similar experiences?&lt;br /&gt;
:Omar Yasin: I've got a {{R52}} and when I load the same ACPIO modules the high pitch noises are not as loud but I can still hear them.&lt;br /&gt;
*Kaspar Schleiser: On my {{T23}} the noise is less loud when setting max_cstate to 2, but to completely silence it, I have to set it to &amp;quot;1&amp;quot;. Is that the same as removing the &amp;quot;processor&amp;quot;-module? &amp;quot;cat /proc/acpi/battery/BAT0/state&amp;quot; does not show increased power drain.&lt;br /&gt;
*Niko Ehrenfeuchter: I'm experiencing the same here on my {{X24}}. Removing the &amp;quot;processor&amp;quot; module also stops the pitch noise, which does ONLY occur when setting the CPU to maximum speed (using cpufreq). On low speed it's completely silent, even having loaded the processor module.&lt;br /&gt;
&lt;br /&gt;
*Rolf Adelsberger: I can confirm this: the high pitch noise is only remarkable (at least with my ears ;-) ) if the processor speed is set to maximum frequency.&lt;br /&gt;
&lt;br /&gt;
*Stefan Baums: My {{X41}} produced a high-pitched crackle from the processor vent on the left.  Changing HZ did nothing, and the 'processor' module could not easily be removed from the system (Ubuntu 5.04).  What solved the problem for me was adding {{bootparm|idle|halt}} to the boot command line. Unfortunately, this solution only lasts until the first hibernation or suspend - when the computer ({{X41}}) resumes, the high-pitched crackle is back.&lt;br /&gt;
&lt;br /&gt;
* The {{bootparm|idle|halt}} solution combined with setting &amp;lt;code&amp;gt;#define HZ 100&amp;lt;/code&amp;gt; in the kernel fixes the problem on a {{T43}}.&lt;br /&gt;
&lt;br /&gt;
* jhatch:  {{bootparm|idle|halt}} plus &amp;lt;code&amp;gt;#define HZ 100&amp;lt;/code&amp;gt; also worked on my {{T43}}.  It still reverts back to noisy after a suspend/resume though.  This needs to be fixed...&lt;br /&gt;
&lt;br /&gt;
===Use both C-States (sleep modes) and P-States (frequency scaling)===&lt;br /&gt;
*Max Gaukler: I had the problem with a &amp;quot;beeping&amp;quot; noise of my {{R60}} on battery. When using powertop I recognised that it went into C3 (deep sleep mode), but it was always running at the highest possible frequency. I followed the instructions in [[How_to_make_use_of_Dynamic_Frequency_Scaling|How to make use of Dynamic Frequency Scaling]] and the noise disappeared except for a short time during boot until frequency scaling has been loaded.&lt;br /&gt;
&lt;br /&gt;
===Change the timer interrupt frequency===&lt;br /&gt;
&lt;br /&gt;
Change the &amp;quot;HZ&amp;quot; kernel constants to alter the frequency of timer interrupts. Discussion:&lt;br /&gt;
&lt;br /&gt;
{{NOTE|The timer interrupt frequency (HZ) in current kernels is directly tied to Linux's task scheduler.  Lower frequencies provide larger time-slices and thus also higher latencies (which may kill latency-sensitive applications like audio processing). 100Hz ended up as the recommended &amp;quot;server&amp;quot; setting (because it increases disk/CPU throughput in a latency-insensitive environment).  Higher frequencies are better for latency-sensitive applications, and improve desktop responsivity at the cost of less processor throughput. 1000Hz ended up as the recommended &amp;quot;desktop&amp;quot; setting.}}&lt;br /&gt;
&lt;br /&gt;
*Andreas Karnahl: i've read in several forums it has something to do with the &amp;quot;idle&amp;quot;-state (or &amp;quot;C3&amp;quot;) of the processor. There is a frequency called &amp;quot;timer interrupt&amp;quot; (or something like that). Since kernel 2.6x it is set to 1000 Hz by default (compared to 100 Hz in Kernel 2.4x). The exact reason i don't know, but it is safe to change this frequency to 100 Hz in kernel 2.6x (by the way, windows up to XP uses 100 Hz by default).&amp;lt;br /&amp;gt;Just do the following:&amp;lt;br /&amp;gt;&lt;br /&gt;
:   In {{path|[path to kernel-sources]/include/asm-i386/param.h}} find the line&lt;br /&gt;
::       &amp;lt;code&amp;gt;#define HZ 1000&amp;lt;/code&amp;gt;&lt;br /&gt;
:   and change the value of HZ to 100: &lt;br /&gt;
::       &amp;lt;code&amp;gt;#define HZ 100&amp;lt;/code&amp;gt;&lt;br /&gt;
:Then recompile the kernel.&amp;lt;br /&amp;gt;After i changed it on my ThinkPad {{A30}} (under SuSE 9.2 and 9.3) and recompiling the kernel the high pitch noise is gone away.&lt;br /&gt;
&lt;br /&gt;
* Omar Yasin: Worked on my {{R52}}, thanks.&lt;br /&gt;
&lt;br /&gt;
* [[User:Thinker|Thinker]]: In modern kernels this constant is in the kernel configuration {{kernelconf|CONFIG_HZ|Processor type and features||Timer Frequency|||||}}.&lt;br /&gt;
&lt;br /&gt;
* [[User:sklnd|sklnd]]: As of 2.6.21, enabling a tickless kernel (CONFIG_NO_HZ) seems to fix the sound issue on the X60. This also has the added benefit of causing the kernel to wake up less, which will improve battery life.&lt;br /&gt;
&lt;br /&gt;
===Prevent idling===&lt;br /&gt;
&lt;br /&gt;
Indirectly avoid power saving states by making sure the CPU is rarely idle:&lt;br /&gt;
&lt;br /&gt;
* Paul RIVIER: Here is a really simple workaround. C3 / C4 states are mainly called when the cpu freq is higher than required, for example if your cpufreqd is lazy to slow down the frequency but quick to raise it. That is why I use powernowd with the builtin &amp;quot;passive&amp;quot; mode, which is lazy for raising frequency, but quick to go back to the lowest. Now I don't hear them as often as before, as I avoid C3/C4 states at high frequency.&lt;br /&gt;
&lt;br /&gt;
* The problem also occurs on my {{X41}} with 2.6.11. Setting up [[How to make use of Dynamic Frequency Scaling|frequency scaling]] with the &amp;lt;code&amp;gt;ondemand&amp;lt;/code&amp;gt; governor makes things a lot better, as the processor does not stay with the maximum frequency when in idle mode. It can be still heard sometimes, though.&lt;br /&gt;
&lt;br /&gt;
* On a {{T43}} the noise was gone after dropping cpufreqd and switching to the ondemand governor - maybe because of the high sampling rate? (used the default: 10ms)&lt;br /&gt;
&lt;br /&gt;
===Change the processor voltage===&lt;br /&gt;
&lt;br /&gt;
Reducing the processor voltage (when possible) may decrease or eliminate the noise. On one ThinkPad {{T43}}, [[Pentium M undervolting and underclocking|undervolting the Pentium M processor]] eliminated the high-pitched noise. Compared to the other solutions this has the benefit of lower power consumption, both due to the undervolting itself and because there is no need to forbid high APCI CPU power saving modes.&lt;br /&gt;
&lt;br /&gt;
===Kernel BIOS options===&lt;br /&gt;
&lt;br /&gt;
Adding acpi_sleep=s3_bios and pci=bios as boot parameters significantly reduced the pitch noise on a T61. Seems to be the best solution so far, without losing battery capacity. If ondemand governor is enabled as well, the noise is almost gone.--[[User:Mozz|Mozz]] 13:14, 18 January 2008 (CET)&lt;br /&gt;
&lt;br /&gt;
===Kernel Update===&lt;br /&gt;
&lt;br /&gt;
The recent kernel update in Ubuntu 8.04 from 2.6.24-19 to 2.6.24-21 made the noise disappear on my T61. With the old kernel the sound was very audible when running on battery power, although setting the kernel BIOS options as specified in the paragraph above made it somewhat bearable. Now I can barely hear anything with the default startup options, even with my ear close to the laptop.&lt;br /&gt;
&lt;br /&gt;
==Solutions for screen brightness related sounds==&lt;br /&gt;
&lt;br /&gt;
===Disable BIOS brightness control===&lt;br /&gt;
&lt;br /&gt;
The sound starts when on batteries as the BIOS automatically reduces screen brightness. To disable this, simply switch Config&amp;gt;Display&amp;gt;Brightness from&lt;br /&gt;
Normal to High. See also [[User:Piccobello/Hissing sound on battery|here]].&lt;br /&gt;
&lt;br /&gt;
==Other solutions==&lt;br /&gt;
&lt;br /&gt;
===Disable UltraBay===&lt;br /&gt;
*Naheed Vora: My {{T41}} (2373-268) started to give high pitch noise ocassionally, when I upgraded to 2.6.11 kernel. I tried to unload lot of modules but finally figured out that disabling bay stops the noise. If you have [[ibm-acpi]], do (need a cleaner solution): {{cmduser|echo eject &amp;gt;/proc/acpi/ibm/bay}} .&lt;br /&gt;
&lt;br /&gt;
===Disable IrDA===&lt;br /&gt;
*Mike Perry: I was able to cure an intermittent high-pitched whine on both my {{X24}} and {{X40}} by disabling the Infrared port.&lt;br /&gt;
&lt;br /&gt;
===Disable the Linuxant Modem Driver===&lt;br /&gt;
*Joern Heissler: I made another experience. I played around with linuxant conexant [[Modem Devices|modem]] drivers. After loading them I got some noise on my {{T42p}}.&lt;br /&gt;
&lt;br /&gt;
===Media Player paused===&lt;br /&gt;
*Eilif Muller: On my {{R52}} the high-pitched noises go away if I load XMMS, play something then pause it.&lt;br /&gt;
*Jacob: On my {{T43}} DGU it goes away if I open mplayerc.exe and press play then pause it. This is the high-pitched noise that only shows up when I'm on battery.&lt;br /&gt;
*butcom: On my {{X60 Tablet}}, this tip works in Windows as well with Media Player Classic or Windows Media Player.  Just open either program, start playing any music file and pause it and the screeching noise stops.&lt;br /&gt;
&lt;br /&gt;
''I'd guess that the above tip works as when xmms or similar is running, it is uncompressing compressed audio/video, which is a processor intensive action.  Keeping this paused means that the app won't 'let go' of the processor, forcing it to stay up and running, which stops it entering the higher powersave modes.''&lt;br /&gt;
&lt;br /&gt;
===nice yes===&lt;br /&gt;
&lt;br /&gt;
Run the command: &lt;br /&gt;
 {{cmduser|nice yes &amp;gt; /dev/null}}.&lt;br /&gt;
&lt;br /&gt;
This is a good way to test whether the processor is causing the interference, since it forces the CPU to stay at full power. Of course, this will make your system get warm, and probably turn on the fan, as well as eating power.&lt;br /&gt;
&lt;br /&gt;
===Upgrade BIOS===&lt;br /&gt;
On a ThinkPad {{X60s}}, [[BIOS_Upgrade|upgrading the BIOS]] to version 1.06 eliminated the high pitch noise when running on battery.&lt;br /&gt;
&lt;br /&gt;
On a ThinkPad {{X61}}, [[BIOS_Upgrade|upgrading the BIOS]] to version 2.21 reduces the noise. It's not completely eliminated though.&lt;br /&gt;
&lt;br /&gt;
On a ThinkPad {{R60}}, [[BIOS_Upgrade|upgrading the BIOS]] to version 2.19 eliminated the voice also.&lt;br /&gt;
&lt;br /&gt;
===Disable USB===&lt;br /&gt;
Disabling USB (partially) using {{cmdroot|rmmod uhci_hcd}} significantly reduced the noise in some cases.&lt;br /&gt;
Reported on {{T43}}, {{T61}}, {{X60}}, {{X200s}}&lt;br /&gt;
On a {{T60}} this trick worked well and doing ''rmmod/modprobe'' twice wiped the noise permanently.&lt;br /&gt;
&lt;br /&gt;
This is likely a CPU-induced noise case, as disabling USB UHCI will reduce a lot the amount of busmaster activity while the computer is idle, and thus has a direct effect on the need for ACPI C-state transitions from C3/C4 to C2 or lower states.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*syscrash: Plugging in my USB mouse has completely solved the problem for me.&lt;br /&gt;
*lorien: Plugging USB mouse helped me too {{T61}}&lt;br /&gt;
*telofy: Disabling USB &amp;quot;solved&amp;quot; the problem; so does disabling the CPU idle setting in the BIOS on my X200s.&lt;br /&gt;
&lt;br /&gt;
===Suspend USB===&lt;br /&gt;
*Stefan Ott: On my X41, the noise seems to have stopped since I enabled &amp;quot;USB selective suspend/resume and wakeup&amp;quot; (CONFIG_USB_SUSPEND).&lt;br /&gt;
*babrodtk: This approach worked with an R60 as well.&lt;br /&gt;
&lt;br /&gt;
===Turn off fan===&lt;br /&gt;
On a ThinkPad {{T60p}}, changing the fan speed or turning off the fan using TP Fan Control eliminated the high pitch noise.&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/thinkpad-smapi.sh&amp;diff=62573</id>
		<title>Code/thinkpad-smapi.sh</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/thinkpad-smapi.sh&amp;diff=62573"/>
		<updated>2025-04-11T07:53:44Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put script in pre block.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
# Copyright (C) 2007 William Poetra Yoga Hadisoeseno &amp;lt;williampoetra@gmail.com&amp;gt;&lt;br /&gt;
# This file is licensed under the GPL v2. E-mail me if you have any ideas of&lt;br /&gt;
# other licenses to use (BSD, GPL v3, Public Domain, etc.), I'm open :)&lt;br /&gt;
&lt;br /&gt;
# IDEAS&lt;br /&gt;
# - make an ncurses interface, and also maybe gtk+ and qt&lt;br /&gt;
# - add option to enable modifying the charge control variables&lt;br /&gt;
&lt;br /&gt;
TP_SMAPI_BASE=/sys/devices/platform/smapi&lt;br /&gt;
&lt;br /&gt;
# function to simplify reading from files&lt;br /&gt;
# syntax: read_file &amp;lt;variable&amp;gt; &amp;lt;filename&amp;gt; &amp;lt;check_return_value 0/1&amp;gt; &amp;lt;translate 0/1&amp;gt; [[value] [translation_string]]&lt;br /&gt;
read_file()&lt;br /&gt;
{&lt;br /&gt;
  local VARIABLE&lt;br /&gt;
  local FILENAME&lt;br /&gt;
  local CHECK_RETURN&lt;br /&gt;
  local TRANSLATE&lt;br /&gt;
  local VAL&lt;br /&gt;
  local RET&lt;br /&gt;
&lt;br /&gt;
  VARIABLE=&amp;quot;$1&amp;quot;; shift&lt;br /&gt;
  FILENAME=&amp;quot;$1&amp;quot;; shift&lt;br /&gt;
  CHECK_RETURN=&amp;quot;$1&amp;quot;; shift&lt;br /&gt;
  TRANSLATE=&amp;quot;$1&amp;quot;; shift&lt;br /&gt;
&lt;br /&gt;
  VAL=`cat &amp;quot;$FILENAME&amp;quot; 2&amp;gt; /dev/null`&lt;br /&gt;
  RET=$?&lt;br /&gt;
&lt;br /&gt;
  if [[ &amp;quot;$CHECK_RETURN&amp;quot; == &amp;quot;1&amp;quot; ]] &amp;amp;&amp;amp; [[ $RET -gt 0 ]]&lt;br /&gt;
  then&lt;br /&gt;
    RESULT=&amp;quot;[unavailable]&amp;quot;&lt;br /&gt;
  elif [ &amp;quot;$TRANSLATE&amp;quot; == &amp;quot;1&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    RESULT=&amp;quot;unknown ($RET)&amp;quot;&lt;br /&gt;
    while [ -n &amp;quot;$1&amp;quot; ]&lt;br /&gt;
    do&lt;br /&gt;
      if [ &amp;quot;$VAL&amp;quot; == &amp;quot;$1&amp;quot; ]&lt;br /&gt;
      then&lt;br /&gt;
        RESULT=&amp;quot;$2&amp;quot;&lt;br /&gt;
        break&lt;br /&gt;
      fi&lt;br /&gt;
      shift 2&lt;br /&gt;
    done&lt;br /&gt;
  else&lt;br /&gt;
    RESULT=&amp;quot;$VAL&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  eval &amp;quot;$VARIABLE=&amp;quot;'&amp;quot;'&amp;quot;$RESULT&amp;quot;'&amp;quot;'&lt;br /&gt;
#  eval &amp;quot;$VARIABLE=$RESULT&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
give_units()&lt;br /&gt;
{&lt;br /&gt;
  local VARIABLE&lt;br /&gt;
  local UNIT&lt;br /&gt;
  local VALUE&lt;br /&gt;
  local RESULT&lt;br /&gt;
&lt;br /&gt;
  VARIABLE=&amp;quot;$1&amp;quot;&lt;br /&gt;
  UNIT=&amp;quot;$2&amp;quot;&lt;br /&gt;
  eval &amp;quot;VALUE=\$$VARIABLE&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  if (echo &amp;quot;$VALUE&amp;quot; | grep -qs &amp;quot;^-\?[0-9]&amp;quot;)&lt;br /&gt;
  then&lt;br /&gt;
    RESULT=&amp;quot;$VALUE $UNIT&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    RESULT=&amp;quot;$VALUE&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  eval &amp;quot;$VARIABLE=&amp;quot;'&amp;quot;'&amp;quot;$RESULT&amp;quot;'&amp;quot;'&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
replace_val()&lt;br /&gt;
{&lt;br /&gt;
  local VARIABLE&lt;br /&gt;
  local OLD_VALUE&lt;br /&gt;
  local NEW_VALUE&lt;br /&gt;
  local VALUE&lt;br /&gt;
  local RESULT&lt;br /&gt;
&lt;br /&gt;
  VARIABLE=&amp;quot;$1&amp;quot;&lt;br /&gt;
  OLD_VALUE=&amp;quot;$2&amp;quot;&lt;br /&gt;
  NEW_VALUE=&amp;quot;$3&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  eval &amp;quot;VALUE=\$$VARIABLE&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  if [ &amp;quot;$VALUE&amp;quot; == &amp;quot;$OLD_VALUE&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    RESULT=&amp;quot;$NEW_VALUE&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    RESULT=&amp;quot;$VALUE&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  eval &amp;quot;$VARIABLE=&amp;quot;'&amp;quot;'&amp;quot;$RESULT&amp;quot;'&amp;quot;'&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
show_help()&lt;br /&gt;
{&lt;br /&gt;
  cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
&lt;br /&gt;
  thinkpad-smapi.sh - Show SMAPI information on ThinkPad laptops, through&lt;br /&gt;
                      the exported SMAPI information by the tp_smapi module.&lt;br /&gt;
&lt;br /&gt;
  -a      Show all available information&lt;br /&gt;
  -b [n]  Show all available information for battery [n]&lt;br /&gt;
  -h      Show this help text&lt;br /&gt;
  -m      Show miscellaneous information&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
show_misc()&lt;br /&gt;
{&lt;br /&gt;
  cd $TP_SMAPI_BASE&lt;br /&gt;
&lt;br /&gt;
  read_file PCI_POWER_SAVINGS &amp;quot;enable_pci_power_saving_on_boot&amp;quot; 1 1 1 &amp;quot;enabled&amp;quot; 0 &amp;quot;disabled&amp;quot;&lt;br /&gt;
  read_file AC_ADAPTER &amp;quot;ac_connected&amp;quot; 1 1 1 &amp;quot;connected&amp;quot; 0 &amp;quot;disconnected&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
MISCELLANEOUS INFORMATION&lt;br /&gt;
=========================&lt;br /&gt;
&lt;br /&gt;
PCI power savings on boot: $PCI_POWER_SAVINGS&lt;br /&gt;
AC adapter status: $AC_ADAPTER&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
show_batt()&lt;br /&gt;
{&lt;br /&gt;
  SLOT=$1&lt;br /&gt;
  cd $TP_SMAPI_BASE/BAT$SLOT&lt;br /&gt;
&lt;br /&gt;
  TMP=`cat installed`&lt;br /&gt;
  if [ $TMP -eq 1 ]&lt;br /&gt;
  then&lt;br /&gt;
    BATT_INSTALLED=&amp;quot;yes&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    BATT_INSTALLED=&amp;quot;no&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  BATT_STATE=`cat state`&lt;br /&gt;
&lt;br /&gt;
  if [ $BATT_INSTALLED == &amp;quot;yes&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
&lt;br /&gt;
    read_file BARCODING &amp;quot;barcoding&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_CHEMISTRY &amp;quot;chemistry&amp;quot; 1 0&lt;br /&gt;
    read_file DESIGN_CAPACITY &amp;quot;design_capacity&amp;quot; 1 0&lt;br /&gt;
    read_file DESIGN_VOLTAGE &amp;quot;design_voltage&amp;quot; 1 0&lt;br /&gt;
    read_file MANUFACTURE_DATE &amp;quot;manufacture_date&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_FRU &amp;quot;model&amp;quot; 1 0&lt;br /&gt;
    read_file MANUFACTURER &amp;quot;manufacturer&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_SERIAL &amp;quot;serial&amp;quot; 1 0&lt;br /&gt;
&lt;br /&gt;
    read_file FIRST_USE_DATE &amp;quot;first_use_date&amp;quot; 1 0&lt;br /&gt;
    read_file CYCLE_COUNT &amp;quot;cycle_count&amp;quot; 1 0&lt;br /&gt;
    read_file LAST_FULL_CAPACITY &amp;quot;last_full_capacity&amp;quot; 1 0&lt;br /&gt;
    read_file CURRENT_1MIN &amp;quot;current_avg&amp;quot; 1 0&lt;br /&gt;
    read_file POWER_1MIN &amp;quot;power_avg&amp;quot; 1 0&lt;br /&gt;
&lt;br /&gt;
    read_file CAPACITY_MWH &amp;quot;remaining_capacity&amp;quot; 1 0&lt;br /&gt;
    read_file CAPACITY_PERCENT &amp;quot;remaining_percent&amp;quot; 1 0&lt;br /&gt;
    read_file REMAINING_RUNNING_TIME &amp;quot;remaining_running_time&amp;quot; 1 0&lt;br /&gt;
    read_file CURRENT_NOW &amp;quot;current_now&amp;quot; 1 0&lt;br /&gt;
    read_file POWER_NOW &amp;quot;power_now&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_TEMPERATURE &amp;quot;temperature&amp;quot; 1 0&lt;br /&gt;
    read_file BATT_VOLTAGE &amp;quot;voltage&amp;quot; 1 0&lt;br /&gt;
    read_file REMAINING_CHARGING_TIME &amp;quot;remaining_charging_time&amp;quot; 1 0&lt;br /&gt;
&lt;br /&gt;
    # fixups&lt;br /&gt;
    give_units DESIGN_CAPACITY &amp;quot;mWh&amp;quot;&lt;br /&gt;
    give_units DESIGN_VOLTAGE &amp;quot;mV&amp;quot;&lt;br /&gt;
    give_units CURRENT_NOW &amp;quot;mA&amp;quot;&lt;br /&gt;
    give_units POWER_NOW &amp;quot;mW&amp;quot;&lt;br /&gt;
    give_units CURRENT_1MIN &amp;quot;mA&amp;quot;&lt;br /&gt;
    give_units POWER_1MIN &amp;quot;mW&amp;quot;&lt;br /&gt;
    give_units LAST_FULL_CAPACITY &amp;quot;mWh&amp;quot;&lt;br /&gt;
    give_units REMAINING_RUNNING_TIME &amp;quot;min&amp;quot;&lt;br /&gt;
    give_units REMAINING_CHARGING_TIME &amp;quot;min&amp;quot;&lt;br /&gt;
    give_units CAPACITY_PERCENT &amp;quot;%&amp;quot;&lt;br /&gt;
    give_units BATT_TEMPERATURE &amp;quot;mC&amp;quot;&lt;br /&gt;
    give_units BATT_VOLTAGE &amp;quot;mV&amp;quot;&lt;br /&gt;
&lt;br /&gt;
    # some more&lt;br /&gt;
    replace_val REMAINING_RUNNING_TIME &amp;quot;not_discharging&amp;quot; &amp;quot;[not discharging]&amp;quot;&lt;br /&gt;
    replace_val REMAINING_CHARGING_TIME &amp;quot;not_charging&amp;quot; &amp;quot;[not charging]&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  else&lt;br /&gt;
&lt;br /&gt;
    BATT_FRU=&lt;br /&gt;
    MANUFACTURER=   &lt;br /&gt;
    BATT_SERIAL=&lt;br /&gt;
    BARCODING=&lt;br /&gt;
    BATT_CHEMISTRY=&lt;br /&gt;
    DESIGN_CAPACITY=&lt;br /&gt;
    DESIGN_VOLTAGE=&lt;br /&gt;
    MANUFACTURE_DATE=&lt;br /&gt;
&lt;br /&gt;
    FIRST_USE_DATE=&lt;br /&gt;
    CYCLE_COUNT=&lt;br /&gt;
    LAST_FULL_CAPACITY=&lt;br /&gt;
    CURRENT_1MIN=&lt;br /&gt;
    POWER_1MIN=&lt;br /&gt;
&lt;br /&gt;
    CAPACITY_MWH=&lt;br /&gt;
    CAPACITY_PERCENT=&lt;br /&gt;
    REMAINING_RUNNING_TIME=&lt;br /&gt;
    CURRENT_NOW=&lt;br /&gt;
    POWER_NOW=&lt;br /&gt;
    BATT_TEMPERATURE=&lt;br /&gt;
    BATT_VOLTAGE=&lt;br /&gt;
    REMAINING_CHARGING_TIME=&lt;br /&gt;
&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  read_file START_CHARGE_THRESH &amp;quot;start_charge_thresh&amp;quot; 1 0&lt;br /&gt;
  read_file STOP_CHARGE_THRESH &amp;quot;stop_charge_thresh&amp;quot; 1 0&lt;br /&gt;
  read_file INHIBIT_CHARGE_MIN &amp;quot;inhibit_charge_minutes&amp;quot; 1 0&lt;br /&gt;
  read_file BATT_FORCE_DISCHARGE &amp;quot;force_discharge&amp;quot; 1 1 1 &amp;quot;yes&amp;quot; 0 &amp;quot;no&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# installed*, state*, dump&lt;br /&gt;
# barcoding, chemistry, design_capacity, design_voltage, manufacture_date, model, manufacturer, serial&lt;br /&gt;
# first_use_date, cycle_count, last_full_capacity, current_avg, power_avg&lt;br /&gt;
# remaining_capacity, remaining_percent, remaining_running_time, current_now, power_now, temperature, voltage, remaining_charging_time&lt;br /&gt;
# start_charge_thresh*, stop_charge_thresh*, inhibit_charge_minutes*, force_discharge*&lt;br /&gt;
&lt;br /&gt;
  cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
BATTERY $SLOT INFORMATION&lt;br /&gt;
=====================&lt;br /&gt;
&lt;br /&gt;
Battery slot:&lt;br /&gt;
  Battery present: $BATT_INSTALLED&lt;br /&gt;
  Battery state: $BATT_STATE&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
&lt;br /&gt;
  if [ &amp;quot;$BATT_INSTALLED&amp;quot; == &amp;quot;yes&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
Embedded info:&lt;br /&gt;
  FRU P/N: $BATT_FRU&lt;br /&gt;
  Barcoding: $BARCODING&lt;br /&gt;
  Serial number: $BATT_SERIAL&lt;br /&gt;
  OEM Manufacturer: $MANUFACTURER&lt;br /&gt;
  Chemistry: $BATT_CHEMISTRY&lt;br /&gt;
  Manufacture date: $MANUFACTURE_DATE&lt;br /&gt;
  Design capacity &amp;amp; voltage: $DESIGN_CAPACITY, $DESIGN_VOLTAGE&lt;br /&gt;
&lt;br /&gt;
Battery health:&lt;br /&gt;
  First use date: $FIRST_USE_DATE&lt;br /&gt;
  Cycle count: $CYCLE_COUNT&lt;br /&gt;
  Last full capacity: $LAST_FULL_CAPACITY&lt;br /&gt;
  Average current / power (past 1 minute): $CURRENT_1MIN, $POWER_1MIN&lt;br /&gt;
&lt;br /&gt;
Battery status:&lt;br /&gt;
  Remaining capacity: $CAPACITY_MWH mWh ($CAPACITY_PERCENT)&lt;br /&gt;
  Remaining running time: $REMAINING_RUNNING_TIME&lt;br /&gt;
  Running current &amp;amp; power: $CURRENT_NOW, $POWER_NOW&lt;br /&gt;
  Temperature: $BATT_TEMPERATURE&lt;br /&gt;
  Voltage: $BATT_VOLTAGE&lt;br /&gt;
  Remaining charging time: $REMAINING_CHARGING_TIME&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  cat &amp;lt;&amp;lt; EOF&lt;br /&gt;
Battery charging control:&lt;br /&gt;
  Start charging at: $START_CHARGE_THRESH %&lt;br /&gt;
  Stop charging at: $STOP_CHARGE_THRESH %&lt;br /&gt;
  Prevent charging for: $INHIBIT_CHARGE_MIN min&lt;br /&gt;
  Force battery discharge: $BATT_FORCE_DISCHARGE&lt;br /&gt;
&lt;br /&gt;
EOF&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
SHOW_ALL=&lt;br /&gt;
SHOW_BATT=&lt;br /&gt;
SHOW_MISC=&lt;br /&gt;
GOT_OPTS=&lt;br /&gt;
&lt;br /&gt;
while getopts ab:hm OPT&lt;br /&gt;
do&lt;br /&gt;
  GOT_OPTS=y&lt;br /&gt;
  case ${OPT} in&lt;br /&gt;
  a) SHOW_ALL=y;;&lt;br /&gt;
  b) if [ ${OPTARG} -eq 0 -o ${OPTARG} -eq 1 ]&lt;br /&gt;
     then&lt;br /&gt;
       SHOW_BATT=${OPTARG}&lt;br /&gt;
     else&lt;br /&gt;
       SHOW_BATT=y&lt;br /&gt;
     fi&lt;br /&gt;
     ;;&lt;br /&gt;
  h) show_help&lt;br /&gt;
     exit 0&lt;br /&gt;
     ;;&lt;br /&gt;
  m) SHOW_MISC=y;;&lt;br /&gt;
  \?) show_help&lt;br /&gt;
     exit 1&lt;br /&gt;
     ;;&lt;br /&gt;
  esac&lt;br /&gt;
done&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$GOT_OPTS&amp;quot; != y ]&lt;br /&gt;
then&lt;br /&gt;
  show_help&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$SHOW_ALL&amp;quot; == y ]&lt;br /&gt;
then&lt;br /&gt;
  show_misc&lt;br /&gt;
  show_batt 0&lt;br /&gt;
  show_batt 1&lt;br /&gt;
else&lt;br /&gt;
  if [ -n &amp;quot;$SHOW_MISC&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    show_misc&lt;br /&gt;
  fi&lt;br /&gt;
  if [ -n &amp;quot;$SHOW_BATT&amp;quot; ]&lt;br /&gt;
  then&lt;br /&gt;
    show_batt $SHOW_BATT&lt;br /&gt;
  fi&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Serial_Ultrabay_Slim_DVD-ROM_Drive&amp;diff=62565</id>
		<title>Serial Ultrabay Slim DVD-ROM Drive</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Serial_Ultrabay_Slim_DVD-ROM_Drive&amp;diff=62565"/>
		<updated>2025-04-11T07:49:38Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: The kernel, Linux doesn't play DVDs. If it can be changed via software means, it's not firmware.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== Serial Ultrabay Slim DVD-ROM Drive (43N3212) ===&lt;br /&gt;
This is an optical drive that slides into a Serial Ultrabay Slim.&lt;br /&gt;
=== Features ===&lt;br /&gt;
* Read/Write capabilities:&lt;br /&gt;
** CD-ROM, CD-R, CD-RW (24x read speed)&lt;br /&gt;
** DVD-ROM, DVD±R, DVD±R DL, DVD±RW, DVD±RW DL (8x read speed)&lt;br /&gt;
* Tray loading&lt;br /&gt;
* Activity LED&lt;br /&gt;
{{footnotes|&lt;br /&gt;
#This model requires its original optical drive's faceplate and mounting bracket to be swapped onto the Serial Ultrabay Slim DVD-ROM Drive, otherwise the drive will not fit in properly. It also requires the black plastic stub located at the back of the DVD-ROM drive to be removed to fit in as well, due to the lack of an eject mechanism (and the fact that it may prevent the drive's installation).&lt;br /&gt;
}}&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
[[image:UltraBay Slim Optical Drive.gif|192px]]&lt;br /&gt;
|}&lt;br /&gt;
=== Part numbers ===&lt;br /&gt;
==== Sony DDU7940H ====&lt;br /&gt;
* 45N7521 (45N7582)&lt;br /&gt;
==== Sony DDU7930H ====&lt;br /&gt;
* 45N7521 (45N7520)&lt;br /&gt;
==== LG DU20N ====&lt;br /&gt;
* 45N7485 (45N7484)&lt;br /&gt;
==== LG DU10N ====&lt;br /&gt;
* 42T2541 (42T2540)&lt;br /&gt;
==== Panasonic UJ8C2 ====&lt;br /&gt;
* 45N7619 (45N7618)&lt;br /&gt;
&lt;br /&gt;
=== Linux support ===&lt;br /&gt;
If connected at boot time, the drive is normally {{path|/dev/sr0}}.&lt;br /&gt;
&lt;br /&gt;
==== Problem regarding reading video DVDs ====&lt;br /&gt;
When playing a region-coded video DVD for the first time using a GNU/Linux player, you may get errors such as the following:&lt;br /&gt;
 libdvdread: Invalid IFO for VMGM (VIDEO_TS.IFO)&lt;br /&gt;
This is caused by the DVD driver's region never having been set. Use &amp;lt;tt&amp;gt;regionset&amp;lt;/tt&amp;gt; to set some region and retry. It is important that you choose the region code wisely, as you will '''not''' be able to read any other regions, and you can only change the region 4 times before it becomes permanent.&lt;br /&gt;
&lt;br /&gt;
With older drives you could use libdvdread to bypass a drives region restrictions, but this doesn't work in some drives, particularly those from Panasonic. Panasonic DVD drives actually refuse to read out-of-region media, and implement RPC-2 fully. This cannot be worked around in any way short of patches to the drive's internal software, which '''are not''' available anywhere.&lt;br /&gt;
&lt;br /&gt;
== Models supporting this accessory ==&lt;br /&gt;
* {{P70}}{{footnote|1}}, {{P71}}{{footnote|1}}&lt;br /&gt;
* {{W500}}, {{W510}}, {{W520}}, {{W530}}, {{W540}}{{footnote|1}}, {{W541}}{{footnote|1}}, {{W700}}, {{W700ds}}, {{W701}}, {{W701ds}}&lt;br /&gt;
* {{T400}}, {{T400s}}, {{T410}}, {{T410i}}, {{T410s}}, {{T410si}}, {{T420}}, {{T420i}}, {{T420s}}, {{T420si}}, {{T430}}, {{T430i}}, {{T430s}}, {{T430si}}, {{T440p}}{{footnote|1}}, {{T500}}, {{T510}}, {{T510i}}, {{T520}}, {{T520i}}, {{T530}}, {{T530i}}, {{T540p}}{{footnote|1}}&lt;br /&gt;
* {{L410}}{{footnote|1}}, {{L412}}{{footnote|1}}, {{L420}}{{footnote|1}}, {{L421}}{{footnote|1}}, {{L430}}{{footnote|1}}, {{L440}}{{footnote|1}}, {{L510}}{{footnote|1}}, {{L512}}{{footnote|1}}, {{L520}}{{footnote|1}}, {{L530}}{{footnote|1}}, {{L540}}{{footnote|1}}, {{L560}}{{footnote|1}}, {{L570}}{{footnote|1}}&lt;br /&gt;
* {{R400}}, {{R500}}&lt;br /&gt;
* {{ThinkPad X200 UltraBase}}, {{ThinkPad UltraBase Series 3}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Ultrabay Devices]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=S3_Savage_IX8&amp;diff=62562</id>
		<title>S3 Savage IX8</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=S3_Savage_IX8&amp;diff=62562"/>
		<updated>2025-04-11T07:45:59Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: I inspected the binary with readelf and it's a GNU/Linux and X.org binary.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== S3 Savage IX8 or IX8+===&lt;br /&gt;
This is a S3 video adapter&amp;lt;br&amp;gt;&lt;br /&gt;
S3 is now owned by Via Technologies&lt;br /&gt;
&lt;br /&gt;
The IX8 and IX8+ chips share the same PCI-ID&lt;br /&gt;
&lt;br /&gt;
=== Features ===&lt;br /&gt;
* Chipset: S3&lt;br /&gt;
* PCI ID: 5333:8c12&lt;br /&gt;
* AGP 2X&lt;br /&gt;
* 8MB SGRAM video memory&lt;br /&gt;
&lt;br /&gt;
=== Driver Download ===&lt;br /&gt;
&lt;br /&gt;
A proprietary GNU/Linux binary and X.org Driver is available from an archive of the s3graphics websites: [https://web.archive.org/web/20130103055651if_/http://www.s3graphics.com:80/en/drivers/legacy_software_archive.aspx Savage Family GNU/Linux XFree86 4.0.3 X Server Binary and Switch Utility version 1.1.18]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== X.Org driver ===&lt;br /&gt;
This chip is supported by the '[[savage]]' driver as part of the X.Org distribution.&lt;br /&gt;
&lt;br /&gt;
==== ThinkPad LCD ====&lt;br /&gt;
Display on the internal LCD works as long as you set the monitor settings correctly. The driver does not appear&lt;br /&gt;
to support [[DPMS]] on the internal LCD, so it is necessary to make sure that horizontal sync and vertical refresh settings are included in the &amp;quot;Monitor&amp;quot; section of xorg.conf.&lt;br /&gt;
&lt;br /&gt;
 HorizSync       31.5 - 48.5&lt;br /&gt;
 VertRefresh     50-70&lt;br /&gt;
&lt;br /&gt;
==== External VGA port ====&lt;br /&gt;
Works. {{key|Fn}}-{{Key|F7}} switches between LCD and CRT. To use both, use [http://www.probo.com/timr/savage40.html s3switch] (on some models you need to run &amp;quot;'''s3switch lcd crt tv'''&amp;quot; even if you want only CRT and LCD, otherwise the CRT display is corrupted).  You can also use [[thinkpad-acpi]] to control video output by echoing commands to {{path|/proc/acpi/ibm/video}}.&lt;br /&gt;
&lt;br /&gt;
==== SVideo port ====&lt;br /&gt;
Works. Use [http://www.probo.com/timr/savage40.html s3switch] to change display output in software.&lt;br /&gt;
&lt;br /&gt;
=== Linux fbcon Framebuffer driver ===&lt;br /&gt;
This chip will work with either the 'vesa' or 'savagefb' driver as part of any recent 2.4 or 2.6 kernel.&lt;br /&gt;
&lt;br /&gt;
==== Dual Monitor Tip ====&lt;br /&gt;
The chip supports using an external monitor plus the LCD as one big monitor. This can lead to a problem&lt;br /&gt;
if X is configured for this, but the external monitor has been detached. This creates a ghost monitor that you &lt;br /&gt;
cannot see, but can move the mouse onto and applications can open windows on.&lt;br /&gt;
&lt;br /&gt;
Sometimes in this situation it's necessary to grab a window from the ghost monitor and drag it into view.&lt;br /&gt;
This can be done by moving the mouse onto the ghost screen and then holding down the ALT key, which allows you&lt;br /&gt;
to click-and-drag a window back into view. To see what is on the ghost monitor, a screen capture utility like&lt;br /&gt;
Ksnapshot can help you. When it takes a screenshot of the entire screen, it will show the contents of the ghost&lt;br /&gt;
screen, even though you can't see it directly.&lt;br /&gt;
&lt;br /&gt;
=== Quirks ===&lt;br /&gt;
==== Power Management and savagefb ====&lt;br /&gt;
The savagefb appears to interfere with acpi sleep. (tested on 2.6 kernels up to 2.6.12)  There are also some display problems with savagefb including limiting boot text to a 800x600 window centered in a 1024x768 display and problems with libdirectfb.  For those reasons, vesafb is recommended as the framebuffer driver.&amp;lt;br /&amp;gt;&lt;br /&gt;
The 800x600 boot-text problem can be resolved by altering the savagefb.c (pre-2.6.20) or savagefb_driver.c (2.6.20 and later) and then recompiling the Kernel or the respective module. To do that, open the savagefb_driver.c, for example under ''&amp;lt;Kernel Root&amp;gt;/drivers/video/savage'' in the 2.6.20 release. Now, locate the following function:&lt;br /&gt;
&amp;lt;pre&amp;gt;static struct fb_var_screeninfo __devinitdata savagefb_var800x600x8 = {&lt;br /&gt;
	.accel_flags =	FB_ACCELF_TEXT,&lt;br /&gt;
	.xres =		800,&lt;br /&gt;
	.yres =		600,&lt;br /&gt;
	.xres_virtual =  800,&lt;br /&gt;
	.yres_virtual =  600,&lt;br /&gt;
	.bits_per_pixel = 8,&lt;br /&gt;
	.pixclock =	25000,&lt;br /&gt;
	.left_margin =	88,&lt;br /&gt;
	.right_margin =	40,&lt;br /&gt;
	.upper_margin =	23,&lt;br /&gt;
	.lower_margin =	1,&lt;br /&gt;
	.hsync_len =	128,&lt;br /&gt;
	.vsync_len =	4,&lt;br /&gt;
	.sync =		FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT,&lt;br /&gt;
	.vmode =	FB_VMODE_NONINTERLACED&lt;br /&gt;
};&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alter the lines ''.xres'', ''.yres'', ''.xres_virtual'' and ''.yres_virtual'' to reflect your chosen resolution. Recompile and reinstall the Kernel, reboot or reload the module and the savagefb should use the new resolution.&lt;br /&gt;
&lt;br /&gt;
==== Video-related System Lockups ====&lt;br /&gt;
Some quirks in the interactions between the OS and the Savage hardware can cause system lockups, especially due to high video load and 3D rendering operations.  For a more complete description of this problem and the workarounds, see the [[Problem with video related system lockup]] page.&lt;br /&gt;
&lt;br /&gt;
==== The Black 'X' (old X pointer) Problem ====&lt;br /&gt;
On some systems a black 'X' (which is actually the old default XFree86 pointer) appears frozen in the middle of the screen inside of X Windows.  This problem can be remedied by setting&lt;br /&gt;
&lt;br /&gt;
 Option &amp;quot;SWCursor&amp;quot; &amp;quot;on&amp;quot;&lt;br /&gt;
&lt;br /&gt;
in xorg.conf.  Also see the [[Problem with black X]] page for more information.&lt;br /&gt;
&lt;br /&gt;
==== 3D Acceleration Quirks ====&lt;br /&gt;
If 3D acceleration is not working on your system (after installing the DRM savage module), or 3D programs are exhibiting strange behavior, one of the following changes may fix the problem.  First, most Savage chips do not have enough video memory to support 3D textures and acceleration with a frame buffer depth of 24 bits.  Therefore, you may need to change &amp;quot;DefaultDepth 24&amp;quot; to &amp;quot;DefaultDepth 16&amp;quot; in the &amp;quot;Screen&amp;quot; section of xorg.conf (and of course provide the appropriate subsection for 16 bit depth if it is not present).  Also, adding one of both of the following configuration options to the &amp;quot;Device&amp;quot; section of your xorg.conf may solve the video quirks (also explained in the [[Problem with video related system lockup|video related system lockup]] page)&lt;br /&gt;
&lt;br /&gt;
 Option     &amp;quot;BusType&amp;quot; &amp;quot;PCI&amp;quot;&lt;br /&gt;
 Option     &amp;quot;DmaMode&amp;quot; &amp;quot;None&amp;quot;&lt;br /&gt;
&lt;br /&gt;
On Debian based systems you need the package '''libgl1-mesa-dri''' to enable 3d acceleration. Deborphan may decide it is just a futile library, but that is false.&lt;br /&gt;
&lt;br /&gt;
==== Blank screen ====&lt;br /&gt;
&lt;br /&gt;
Symptoms:&lt;br /&gt;
&lt;br /&gt;
* X starts but nothing shows up on screen, hard drive led shows normal activity up to login&lt;br /&gt;
* /etc/init.d/xorg.conf does not exist, so X.org is using autoconfiguration which fails&lt;br /&gt;
* /var/log/Xorg.0.log does not show any relevant errors or warnings&lt;br /&gt;
&lt;br /&gt;
This happened on a T20 running Debian Etch and Lenny.&lt;br /&gt;
&lt;br /&gt;
Workaround is to add DmaType and BusType as &amp;quot;PCI&amp;quot; in /etc/X11/xorg.conf:&lt;br /&gt;
&lt;br /&gt;
 Section &amp;quot;Device&amp;quot;&lt;br /&gt;
        Identifier      &amp;quot;S3 Inc. 86C270-294 Savage/IX-MV&amp;quot;&lt;br /&gt;
        Driver          &amp;quot;savage&amp;quot;&lt;br /&gt;
        BusID           &amp;quot;PCI:1:0:0&amp;quot;&lt;br /&gt;
        Option &amp;quot;DmaType&amp;quot; &amp;quot;PCI&amp;quot; &lt;br /&gt;
        Option &amp;quot;BusType&amp;quot; &amp;quot;PCI&amp;quot; &lt;br /&gt;
 EndSection&lt;br /&gt;
&lt;br /&gt;
=== ThinkPads this chip may be found in ===&lt;br /&gt;
* {{A22e}}&lt;br /&gt;
* {{T20}}, {{T21}}, {{T22}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Video Controllers]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=ATI_Mobility_FireGL_V3200&amp;diff=62558</id>
		<title>ATI Mobility FireGL V3200</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=ATI_Mobility_FireGL_V3200&amp;diff=62558"/>
		<updated>2025-04-11T07:37:32Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: X.Org is not Linux. Linux's terminal emulator is called fbcon.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is a ATI video adapter&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
* Chipset: ATI RV380 (M24) - Similar to [[ATI Mobility Radeon X600]]&lt;br /&gt;
* PCI ID: 1002:3154&lt;br /&gt;
* PCI Express x16&lt;br /&gt;
* 128MB GDDR1 video memory&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== X.Org driver ==&lt;br /&gt;
Works fine with xorg 7.0.0&lt;br /&gt;
&lt;br /&gt;
=== ThinkPad LCD ===&lt;br /&gt;
Display on the internal LCD works as long as you set the monitor settings correct.&lt;br /&gt;
&lt;br /&gt;
=== External VGA port ===&lt;br /&gt;
&lt;br /&gt;
==== SuSE ====&lt;br /&gt;
&lt;br /&gt;
Works fine using ATI [[fglrx]] driver version 8.19.10 configured with fglrxconfig into clone mode (display shows full resolution, external CRT shows full resolution with higher refresh rate). &lt;br /&gt;
This was tested using SuSE 9.2 with a Thinkpad T43p.&lt;br /&gt;
&lt;br /&gt;
==== Ubuntu Gutsy ====&lt;br /&gt;
Works fine using Catalyst 7.12.&lt;br /&gt;
If you get corrupted output in OpenGL, set Anti-Aliasing in the Catalyst Control Center and it works fine magically.&lt;br /&gt;
&lt;br /&gt;
==== Ubuntu Dapper ====&lt;br /&gt;
&lt;br /&gt;
On an ''Ubuntu Dapper'' (xorg 7.0.0) external vga/ monitor/ beamer works fine with the following in {{path|/etc/xorg.conf}}. I used the free ati driver shipped with Dapper. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
# insert after section 'Screen' with identifier 'Default Screen'&lt;br /&gt;
&lt;br /&gt;
##################################################################################&lt;br /&gt;
# MergedFB2 from http://mg.pov.lt/xorg.conf&lt;br /&gt;
##################################################################################&lt;br /&gt;
&lt;br /&gt;
Section &amp;quot;Device&amp;quot;&lt;br /&gt;
	Identifier	&amp;quot;MergedFB ATI&amp;quot;&lt;br /&gt;
	Driver		&amp;quot;ati&amp;quot;&lt;br /&gt;
	BusID		&amp;quot;PCI:1:0:0&amp;quot;&lt;br /&gt;
	Option		&amp;quot;DynamicClocks&amp;quot;	&amp;quot;on&amp;quot;&lt;br /&gt;
	Option		&amp;quot;MergedFB&amp;quot;	&amp;quot;true&amp;quot;&lt;br /&gt;
	Option		&amp;quot;CRT2Position&amp;quot;	&amp;quot;RightOf&amp;quot;&lt;br /&gt;
    # This allows X to use MergedFB if the external monitor is not connected&lt;br /&gt;
    # when I start X.  The ranges are taken from DDC values of the CTX monitor&lt;br /&gt;
    # I use at the office; as listed in Xorg.log.&lt;br /&gt;
	Option		&amp;quot;CRT2HSync&amp;quot;	&amp;quot;30-81&amp;quot;&lt;br /&gt;
	Option		&amp;quot;CRT2VRefresh&amp;quot;	&amp;quot;56-76&amp;quot;&lt;br /&gt;
    # The next line lets me switch between dual-head and several clone modes&lt;br /&gt;
    # of varying resolutions with xrandr.&lt;br /&gt;
    # modified by jensens&lt;br /&gt;
	Option		&amp;quot;MetaModes&amp;quot;	&amp;quot;1400x1050-1280x1024 1400x1050-1024x768 1400x1050 1280x1024 1024x768 800x600 640x480&amp;quot;&lt;br /&gt;
    # A newer version of the radeon driver has an option that disables vertical&lt;br /&gt;
    # scrolling for the 1024x768 part.&lt;br /&gt;
	Option		&amp;quot;MergedNonRectangular&amp;quot;	&amp;quot;true&amp;quot;&lt;br /&gt;
    # In 1024x768-1280x1024 mode the DPI is correct (100), but in all other&lt;br /&gt;
    # modes it is weird.  Try to override&lt;br /&gt;
	Option		&amp;quot;MergedDPI&amp;quot;	&amp;quot;100 100&amp;quot;&lt;br /&gt;
EndSection&lt;br /&gt;
&lt;br /&gt;
Section &amp;quot;Screen&amp;quot;&lt;br /&gt;
	Identifier	&amp;quot;MergedFB Screen&amp;quot;&lt;br /&gt;
	Device		&amp;quot;MergedFB ATI&amp;quot;&lt;br /&gt;
	Monitor		&amp;quot;Generic Monitor&amp;quot;&lt;br /&gt;
	DefaultDepth	24&lt;br /&gt;
	SubSection &amp;quot;Display&amp;quot;&lt;br /&gt;
		Depth		24&lt;br /&gt;
		Modes		&amp;quot;1400x1050&amp;quot; &amp;quot;1280x1024&amp;quot; &amp;quot;1024x768&amp;quot; &amp;quot;800x600&amp;quot; &amp;quot;640x480&amp;quot;&lt;br /&gt;
	EndSubSection&lt;br /&gt;
EndSection&lt;br /&gt;
##################################################################################&lt;br /&gt;
&lt;br /&gt;
# replace ServerLayout with this lines:&lt;br /&gt;
&lt;br /&gt;
Section &amp;quot;ServerLayout&amp;quot;&lt;br /&gt;
	Identifier	&amp;quot;Default Layout&amp;quot;&lt;br /&gt;
	#Screen		&amp;quot;Default Screen&amp;quot;&lt;br /&gt;
	Screen		&amp;quot;MergedFB Screen&amp;quot;&lt;br /&gt;
	InputDevice	&amp;quot;Generic Keyboard&amp;quot;&lt;br /&gt;
	InputDevice	&amp;quot;Configured Mouse&amp;quot;&lt;br /&gt;
	InputDevice     &amp;quot;stylus&amp;quot; &amp;quot;SendCoreEvents&amp;quot;&lt;br /&gt;
	InputDevice     &amp;quot;cursor&amp;quot; &amp;quot;SendCoreEvents&amp;quot;&lt;br /&gt;
	InputDevice     &amp;quot;eraser&amp;quot; &amp;quot;SendCoreEvents&amp;quot;&lt;br /&gt;
	InputDevice	&amp;quot;Synaptics Touchpad&amp;quot;&lt;br /&gt;
EndSection&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{NOTE|The built-in switching of resolutions does not work with this setting! Use the Gnome applet '''Grandr''' - it works fine.}}&lt;br /&gt;
&lt;br /&gt;
{{HINT|To switch off external VGA port and save some battery you can use the command '''sudo radeontool dac off'''.}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== SVideo port ===&lt;br /&gt;
??&lt;br /&gt;
&lt;br /&gt;
=== DVI port ===&lt;br /&gt;
??&lt;br /&gt;
&lt;br /&gt;
== Proprietary ATI driver ==&lt;br /&gt;
The [[fglrx]] driver adds 3D acceleration.&lt;br /&gt;
&lt;br /&gt;
== Linux fbcon Framebuffer driver ==&lt;br /&gt;
??&lt;br /&gt;
&lt;br /&gt;
== ThinkPads this chip may be found in ==&lt;br /&gt;
* {{T43p}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Video Controllers]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Hard_drive_firmware_update&amp;diff=62557</id>
		<title>Hard drive firmware update</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Hard_drive_firmware_update&amp;diff=62557"/>
		<updated>2025-04-11T07:36:35Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Lenovo calls them &amp;quot;firmware&amp;quot;, so the user figures it's something else than software, but in fact it's just proprietary software.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Lenovo provides ''Hard drive firmware update utilities'' in the form of bootable iso-images. There are at least two such different iso-images, each of them contains software updates for quite a few different Lenovo laptops. They are different by the method they use to boot. One uses [http://www-307.ibm.com/pc/support/site.wss/document.do?lndocid=MIGR-63685 harddrive emulation bootimage], and the other uses [http://www-307.ibm.com/pc/support/site.wss/document.do?lndocid=MIGR-62282 floppy emulation bootimage].&lt;br /&gt;
&lt;br /&gt;
If you have an optical drive, just burn the iso-image and update the firmare. In case if you don't have an optical disk to boot it from, see [[BIOS update without optical disk]] for harddisk emulation bootimage, and [[BIOS Upgrade/X_Series]] for floppy emulation bootimage.&lt;br /&gt;
==Models with harddisk emulation bootimage==&lt;br /&gt;
{{R60}}, {{R60e}}, {{R61}}, {{R61i}}, {{R400}}, {{R500}}, {{SL300}}, {{SL400}}, {{SL500}}, {{T60}}, {{T60p}}, {{T61}}, {{T61p}}, {{T400}}, {{T500}}, {{W500}}, {{W700}}, {{X60}}, {{X60s}}, {{X60 Tablet}}, {{X61}}, {{X61s}}, {{X61 Tablet}}, {{X200}}, {{Z60m}}, {{Z60t}}, {{Z61e}}, {{Z61m}}, {{Z61p}}, {{Z61t}}&lt;br /&gt;
==Models with floppy emulation bootimage==&lt;br /&gt;
{{A20m}}, {{A20p}}, {{A21e}}, {{A21m}}, {{A21p}}, {{A22e}}, {{A22m}}, {{A22p}}, {{i1800}},&lt;br /&gt;
{{A30}}, {{A30p}}, {{A31}}, {{A31p}},&lt;br /&gt;
{{G40}}, {{G41}},&lt;br /&gt;
{{R40}}, {{R40e}},&lt;br /&gt;
{{R50}}, {{R50p}}, {{R51}}, {{R52}},&lt;br /&gt;
{{T20}}, {{T21}}, {{T22}}, {{T23}},&lt;br /&gt;
{{T30}},&lt;br /&gt;
{{T40}}, {{T40p}}, {{T41}}, {{T41p}}, {{T42}}, {{T42p}}, {{T43}}, {{T43p}},&lt;br /&gt;
{{X20}}, {{X21}}, {{X22}}, {{X23}},&lt;br /&gt;
{{X30}}, {{X31}}, {{X32}},&lt;br /&gt;
{{X40}}, {{X41}}, {{X41 Tablet}}&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/ibm-acpi-0.12a-2.6.17-fan.patch&amp;diff=62555</id>
		<title>Code/ibm-acpi-0.12a-2.6.17-fan.patch</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/ibm-acpi-0.12a-2.6.17-fan.patch&amp;diff=62555"/>
		<updated>2025-04-11T07:30:07Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put patch in &amp;lt;pre&amp;gt; block&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
--- drivers/acpi/ibm_acpi.c.orig        2006-08-22 19:04:43.000000000 +0900&lt;br /&gt;
+++ drivers/acpi/ibm_acpi.c     2006-08-22 19:10:28.000000000 +0900&lt;br /&gt;
@@ -1466,6 +1466,7 @@&lt;br /&gt;
 {&lt;br /&gt;
        int len = 0;&lt;br /&gt;
        int s;&lt;br /&gt;
+       char status_read = 0;&lt;br /&gt;
        u8 lo, hi, status;&lt;br /&gt;
&lt;br /&gt;
        if (gfan_handle) {&lt;br /&gt;
@@ -1479,8 +1480,11 @@&lt;br /&gt;
                if (!acpi_ec_read(fan_status_offset, &amp;amp;status))&lt;br /&gt;
                        len += sprintf(p + len, &amp;quot;status:\t\tunreadable\n&amp;quot;);&lt;br /&gt;
                else&lt;br /&gt;
+               {&lt;br /&gt;
                        len += sprintf(p + len, &amp;quot;status:\t\t%s\n&amp;quot;,&lt;br /&gt;
-                                      enabled(status, 7));&lt;br /&gt;
+                                       status ? &amp;quot;enabled&amp;quot; : &amp;quot;disabled&amp;quot; );&lt;br /&gt;
+                       status_read = 1;&lt;br /&gt;
+               }&lt;br /&gt;
&lt;br /&gt;
                if (!acpi_ec_read(fan_rpm_offset, &amp;amp;lo) ||&lt;br /&gt;
                    !acpi_ec_read(fan_rpm_offset + 1, &amp;amp;hi))&lt;br /&gt;
@@ -1488,6 +1492,16 @@&lt;br /&gt;
                else&lt;br /&gt;
                        len += sprintf(p + len, &amp;quot;speed:\t\t%d\n&amp;quot;,&lt;br /&gt;
                                       (hi &amp;lt;&amp;lt; 8) + lo);&lt;br /&gt;
+&lt;br /&gt;
+               if (status_read) {&lt;br /&gt;
+                       if (status &amp;amp; 0x40)&lt;br /&gt;
+                               len += sprintf(p + len, &amp;quot;level:\t\tdisengaged\n&amp;quot;);&lt;br /&gt;
+                       else if (status &amp;amp; 0x80)&lt;br /&gt;
+                               len += sprintf(p + len, &amp;quot;level:\t\tauto\n&amp;quot;);&lt;br /&gt;
+                       else&lt;br /&gt;
+                               len += sprintf(p + len, &amp;quot;level:\t\t%d\n&amp;quot;, status);&lt;br /&gt;
+               }&lt;br /&gt;
+&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        if (sfan_handle)&lt;br /&gt;
@@ -1496,7 +1510,10 @@&lt;br /&gt;
                               &amp;quot; (&amp;lt;level&amp;gt; is 0-7)\n&amp;quot;);&lt;br /&gt;
        if (!gfan_handle)&lt;br /&gt;
                /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
-               len += sprintf(p + len, &amp;quot;commands:\tenable, disable\n&amp;quot;);&lt;br /&gt;
+                len += sprintf(p + len, &lt;br /&gt;
+                             &amp;quot;commands:\tenable, disable, level &amp;lt;level&amp;gt;\n&amp;quot;&lt;br /&gt;
+                             &amp;quot;         \t(&amp;lt;level&amp;gt; is 0-7, auto &amp;quot;&lt;br /&gt;
+                             &amp;quot;or disengaged)\n&amp;quot;);&lt;br /&gt;
        if (fans_handle)&lt;br /&gt;
                /* X31, X40 */&lt;br /&gt;
                len += sprintf(p + len, &amp;quot;commands:\tspeed &amp;lt;speed&amp;gt;&amp;quot;&lt;br /&gt;
@@ -1517,7 +1534,8 @@&lt;br /&gt;
                        /* 570, 770x-JL */&lt;br /&gt;
                        if (!acpi_evalf(sfan_handle, NULL, NULL, &amp;quot;vd&amp;quot;, level))&lt;br /&gt;
                                return -EIO;&lt;br /&gt;
-               } else if (!gfan_handle &amp;amp;&amp;amp; strlencmp(cmd, &amp;quot;enable&amp;quot;) == 0) {&lt;br /&gt;
+               } else if (!gfan_handle &amp;amp;&amp;amp; ( (strlencmp(cmd, &amp;quot;enable&amp;quot;) == 0) || &lt;br /&gt;
+                               (strlencmp(cmd, &amp;quot;level auto&amp;quot;) == 0) ) ) {&lt;br /&gt;
                        /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
                        if (!acpi_ec_write(fan_status_offset, 0x80))&lt;br /&gt;
                                return -EIO;&lt;br /&gt;
@@ -1525,6 +1543,17 @@&lt;br /&gt;
                        /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
                        if (!acpi_ec_write(fan_status_offset, 0x00))&lt;br /&gt;
                                return -EIO;&lt;br /&gt;
+                } else if (!gfan_handle &amp;amp;&amp;amp;&lt;br /&gt;
+                          strlencmp(cmd, &amp;quot;level disengaged&amp;quot;) == 0) {&lt;br /&gt;
+                       /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
+                       if (!acpi_ec_write(fan_status_offset, 0x40))&lt;br /&gt;
+                               return -EIO;&lt;br /&gt;
+               } else if (!gfan_handle &amp;amp;&amp;amp;&lt;br /&gt;
+                   sscanf(cmd, &amp;quot;level %d&amp;quot;, &amp;amp;level) == 1 &amp;amp;&amp;amp;&lt;br /&gt;
+                   level &amp;gt;=0 &amp;amp;&amp;amp; level &amp;lt;= 7) {&lt;br /&gt;
+                       /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
+                       if (!acpi_ec_write(fan_status_offset, level))&lt;br /&gt;
+                               return -EIO;&lt;br /&gt;
                } else if (fans_handle &amp;amp;&amp;amp;&lt;br /&gt;
                           sscanf(cmd, &amp;quot;speed %d&amp;quot;, &amp;amp;speed) == 1 &amp;amp;&amp;amp;&lt;br /&gt;
                           speed &amp;gt;= 0 &amp;amp;&amp;amp; speed &amp;lt;= 65535) {&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/tp-fancontrol.conf&amp;diff=62554</id>
		<title>Code/tp-fancontrol.conf</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/tp-fancontrol.conf&amp;diff=62554"/>
		<updated>2025-04-11T07:29:30Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put config file in &amp;lt;pre&amp;gt; block.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
# config file for tp-fancontrol&lt;br /&gt;
&lt;br /&gt;
# &lt;br /&gt;
# The temparature shift will shift the trip points for different fan speeds.&lt;br /&gt;
#&lt;br /&gt;
# A positive value means that the trip-point is at a higher temperature and&lt;br /&gt;
# thus the fan is less noisy. A negative shift lets the fan start earlier.&lt;br /&gt;
# The default value is 0.&lt;br /&gt;
#&lt;br /&gt;
#TEMP_SHIFT=10&lt;br /&gt;
&lt;br /&gt;
#&lt;br /&gt;
# True if logging to syslog should be enabled. If zero no logging to syslog&lt;br /&gt;
# is enabled. All output will appear on console. This option implies QUIET=1.&lt;br /&gt;
# The default value is 1.&lt;br /&gt;
#&lt;br /&gt;
#LOG_SYSLOG=0&lt;br /&gt;
&lt;br /&gt;
#&lt;br /&gt;
# If no logging to syslog is on, the output will be verbose. To be less&lt;br /&gt;
# verbose set QUIET to 1. The default value is 1.&lt;br /&gt;
#&lt;br /&gt;
#QUIET=1&lt;br /&gt;
&lt;br /&gt;
#&lt;br /&gt;
# The file to store the pid of the currently running fan-control daemon in.&lt;br /&gt;
# The default value is /var/run/tp-fancontrol.pid&lt;br /&gt;
#&lt;br /&gt;
#PIDFILE=/var/run/tp-fancontrol.pid&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/tp-fancontrol.init&amp;diff=62553</id>
		<title>Code/tp-fancontrol.init</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/tp-fancontrol.init&amp;diff=62553"/>
		<updated>2025-04-11T07:28:57Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put script in &amp;lt;pre&amp;gt; block, so it can be copy-pasted&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#! /bin/sh&lt;br /&gt;
### BEGIN INIT INFO&lt;br /&gt;
# Provides:             tp-fancontrol&lt;br /&gt;
# Default-Start:        2 3 4 5&lt;br /&gt;
# Default-Stop:         S 0 1 6&lt;br /&gt;
### END INIT INFO&lt;br /&gt;
# Copyright (c) 2006 Ronald Aigner &amp;lt;ra3@os.inf.tu-dresden.de&amp;gt;&lt;br /&gt;
&lt;br /&gt;
set -e&lt;br /&gt;
&lt;br /&gt;
DAEMON=/usr/bin/tp-fancontrol&lt;br /&gt;
NAME=tp-fancontrol&lt;br /&gt;
DAEMONUSER=root&lt;br /&gt;
PIDDIR=/var/run&lt;br /&gt;
PIDFILE=$PIDDIR/tp-fancontrol.pid&lt;br /&gt;
DESC=&amp;quot;Thinkpad CPU fan control&amp;quot;&lt;br /&gt;
&lt;br /&gt;
test -x $DAEMON || exit 0&lt;br /&gt;
&lt;br /&gt;
# source config file; edit that file to configure this script&lt;br /&gt;
TEMP_SHIFT=0&lt;br /&gt;
LOG_SYSLOG=1&lt;br /&gt;
QUIET=1&lt;br /&gt;
if [ -e /etc/tp-fancontrol.conf ]; then&lt;br /&gt;
  . /etc/tp-fancontrol.conf&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
start_it()&lt;br /&gt;
{&lt;br /&gt;
  PARAMS=-d&lt;br /&gt;
  if [ -e $PIDFILE ]; then&lt;br /&gt;
    echo &amp;quot;$DESC already running. Stop first.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
  fi&lt;br /&gt;
  if [ &amp;quot;$TEMP_SHIFT&amp;quot; != &amp;quot;0&amp;quot; ]; then&lt;br /&gt;
    PARAMS=$PARAMS&amp;quot; -s $TEMP_SHIFT&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
  if [ &amp;quot;$LOG_SYSLOG&amp;quot; = &amp;quot;1&amp;quot; ]; then&lt;br /&gt;
    PARAMS=$PARAMS&amp;quot; -l&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    if [ &amp;quot;$QUIET&amp;quot; = &amp;quot;1&amp;quot; ]; then&lt;br /&gt;
      PARAMS=$PARAMS&amp;quot; -q&amp;quot;&lt;br /&gt;
    fi&lt;br /&gt;
  fi&lt;br /&gt;
  PARAMS=$PARAMS&amp;quot; -p $PIDFILE&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  echo -n &amp;quot;Starting $DESC: $NAME ... &amp;quot;&lt;br /&gt;
  $DAEMON $PARAMS&lt;br /&gt;
  if [ &amp;quot;$?&amp;quot; = &amp;quot;0&amp;quot; ]; then&lt;br /&gt;
    echo &amp;quot;Success.&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    echo &amp;quot;Error while starting: $?&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
}&lt;br /&gt;
 &lt;br /&gt;
stop_it()&lt;br /&gt;
{&lt;br /&gt;
  if [ -e $PIDFILE ]; then&lt;br /&gt;
    echo -n &amp;quot;Stopping $DESC ... &amp;quot;&lt;br /&gt;
    $DAEMON -k&lt;br /&gt;
    if [ &amp;quot;$?&amp;quot; = &amp;quot;0&amp;quot; ]; then&lt;br /&gt;
      echo &amp;quot;Success.&amp;quot;&lt;br /&gt;
    else&lt;br /&gt;
      echo &amp;quot;Error while stopping: $?&amp;quot;&lt;br /&gt;
    fi&lt;br /&gt;
  else&lt;br /&gt;
    echo &amp;quot;$DESC not running.&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
restart_it()&lt;br /&gt;
{&lt;br /&gt;
  if [ -e $PIDFILE ]; then&lt;br /&gt;
    stop_it&lt;br /&gt;
    sleep 2&lt;br /&gt;
  fi&lt;br /&gt;
  start_it&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
case &amp;quot;$1&amp;quot; in&lt;br /&gt;
  start)&lt;br /&gt;
    start_it&lt;br /&gt;
  ;;&lt;br /&gt;
  stop)&lt;br /&gt;
    stop_it&lt;br /&gt;
  ;;&lt;br /&gt;
  reload|force-reload|restart)&lt;br /&gt;
    restart_it&lt;br /&gt;
  ;;&lt;br /&gt;
  *)&lt;br /&gt;
    echo &amp;quot;Usage: /etc/init.d/$NAME {start|stop|reload|restart|force-reload}&amp;quot; &amp;gt;&amp;amp;2&lt;br /&gt;
    exit 1&lt;br /&gt;
  ;;&lt;br /&gt;
esac&lt;br /&gt;
&lt;br /&gt;
exit 0&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/tp-fancontrol&amp;diff=62552</id>
		<title>Code/tp-fancontrol</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/tp-fancontrol&amp;diff=62552"/>
		<updated>2025-04-11T07:28:10Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put script in &amp;lt;pre&amp;gt; block, so it can be copy-pasted&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
# tp-fancontrol 0.3.02 (http://thinkwiki.org/wiki/ACPI_fan_control_script)&lt;br /&gt;
# Provided under the GNU General Public License version 2 or later or&lt;br /&gt;
# the GNU Free Documentation License version 1.2 or later, at your option.&lt;br /&gt;
# See http://www.gnu.org/copyleft/gpl.html for the Warranty Disclaimer.&lt;br /&gt;
&lt;br /&gt;
# This script dynamically controls fan speed on some ThinkPad models&lt;br /&gt;
# according to user-defined temperature thresholds.  It implements its&lt;br /&gt;
# own decision algorithm, overriding the ThinkPad embedded&lt;br /&gt;
# controller. It also implements a workaround for the fan noise pulse&lt;br /&gt;
# experienced every few seconds on some ThinkPads.&lt;br /&gt;
#&lt;br /&gt;
# Run 'tp-fancontrol --help' for options.&lt;br /&gt;
#&lt;br /&gt;
# For optimal fan behavior during suspend and resume, invoke &lt;br /&gt;
# &amp;quot;tp-fancontrol -u&amp;quot; during the suspend process.&lt;br /&gt;
# &lt;br /&gt;
# WARNING: This script relies on undocumented hardware features and&lt;br /&gt;
# overrides nominal hardware behavior. It may thus cause arbitrary&lt;br /&gt;
# damage to your laptop or data. Watch your temperatures!&lt;br /&gt;
#&lt;br /&gt;
# WARNING: The list of temperature ranges used below is much more liberal&lt;br /&gt;
# than the rules used by the embedded controller firmware, and is&lt;br /&gt;
# derived mostly from anecdotal evidence, hunches and wishful thinking.&lt;br /&gt;
# It is also model-specific (see http://thinkwiki.org/wiki/Thermal_sensors).&lt;br /&gt;
&lt;br /&gt;
# Temperature ranges, per sensor:&lt;br /&gt;
# (min temperature: when to step up from 0-th fan level,&lt;br /&gt;
#  max temperature: when to step up to maximum fan level)&lt;br /&gt;
THRESHOLDS=( #  Sensor     ThinkPad model&lt;br /&gt;
             #             R51     T41/2  Z60t   T43-26xx&lt;br /&gt;
# min  max   #  ---------- ------- -----  -----  ---------------------------&lt;br /&gt;
  50   70    #  EC 0x78    CPU     CPU    ?      CPU&lt;br /&gt;
  47   60    #  EC 0x79    miniPCI ?      ?      Between CPU and PCMCIA slot&lt;br /&gt;
  43   55    #  EC 0x7A    HDD     ?      ?      PCMCIA slot&lt;br /&gt;
  49   68    #  EC 0x7B    GPU     GPU    ?      GPU&lt;br /&gt;
  40   50    #  EC 0x7C    BAT     BAT    BAT    Sys BAT (front left of battery)&lt;br /&gt;
  40   50    #  EC 0x7D    n/a     n/a    n/a    UltraBay BAT&lt;br /&gt;
  37   47    #  EC 0x7E    BAT     BAT    BAT    Sys BAT (rear right of battery)&lt;br /&gt;
  37   47    #  EC 0x7F    n/a     n/a    n/a    UltraBay BAT&lt;br /&gt;
&lt;br /&gt;
  45   60    #  EC 0xC0    ?       n/a    ?      Between northbridge and DRAM&lt;br /&gt;
  48   62    #  EC 0xC1    ?       n/a    ?      Southbridge (under miniPCI)&lt;br /&gt;
  50   65    #  EC 0xC2    ?       n/a    ?      Power circuitry (under CDC)&lt;br /&gt;
&lt;br /&gt;
  47   58    #  HDD        -&amp;gt;      -&amp;gt;     -&amp;gt;     Hard disk internal sensor&lt;br /&gt;
  47   60    #  HDAPS      -&amp;gt;      -&amp;gt;     -&amp;gt;     HDAPS readout (same as EC 0x79)&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
LEVELS=(    0      2      4      7)  # Fan speed levels&lt;br /&gt;
ANTIPULSE=( 0      1      1      0)  # Prevent fan pulsing noise at this level&lt;br /&gt;
                                     # (reduces frequency of fan RPM updates)&lt;br /&gt;
&lt;br /&gt;
OFF_THRESH_DELTA=3 # when gets this much cooler than 'min' above, may turn off fan&lt;br /&gt;
MIN_THRESH_SHIFT=0 # increase min thresholds by this much&lt;br /&gt;
MAX_THRESH_SHIFT=0 # increase max thresholds by this much&lt;br /&gt;
MIN_WAIT=180 # minimum time (seconds) to spend in a given level before stepping down&lt;br /&gt;
&lt;br /&gt;
IBM_ACPI=/proc/acpi/ibm&lt;br /&gt;
HDAPS_TEMP=/sys/bus/platform/drivers/hdaps/hdaps/temp1&lt;br /&gt;
PID_FILE=/var/run/tp-fancontrol.pid&lt;br /&gt;
LOGGER=/usr/bin/logger&lt;br /&gt;
INTERVAL=3        # sample+refresh interval&lt;br /&gt;
SETTLE_TIME=6     # wait this many seconds long before applying anti-pulsing&lt;br /&gt;
RESETTLE_TIME=600 # briefly disable anti-pulsing at every N seconds&lt;br /&gt;
SUSPEND_TIME=5    # seconds to sleep when receiving SIGUSR1&lt;br /&gt;
DISK_POLL_PERIOD=15 # poll period in seconds for disk sensors (it changes slowly and is expensive to read)&lt;br /&gt;
HITACHI_MODELS=&amp;quot;^(HTS4212..H9AT00|HTS726060M9AT00|HTS5410..G9AT00|IC25[NT]0..ATCS0[45]|HTE541040G9AT00|HTS5416..J9(AT|SA)00)&amp;quot;&lt;br /&gt;
SEP=','           # Separator char for display&lt;br /&gt;
&lt;br /&gt;
WATCHDOG_DELAY=$(( 3 * INTERVAL ))&lt;br /&gt;
HAVE_WATCHDOG=`grep -q watchdog $IBM_ACPI/fan &amp;amp;&amp;amp; echo true || echo false`&lt;br /&gt;
HAVE_LEVELCMD=`grep -q disengaged $IBM_ACPI/fan &amp;amp;&amp;amp; echo true || echo false`&lt;br /&gt;
&lt;br /&gt;
QUIET=false&lt;br /&gt;
DRY_RUN=false&lt;br /&gt;
DAEMONIZE=false&lt;br /&gt;
AM_DAEMON=false&lt;br /&gt;
KILL_DAEMON=false&lt;br /&gt;
SUSPEND_DAEMON=false&lt;br /&gt;
SYSLOG=false&lt;br /&gt;
DISK_POLL_TIME=-$DISK_POLL_PERIOD&lt;br /&gt;
&lt;br /&gt;
usage() {&lt;br /&gt;
    echo &amp;quot;&lt;br /&gt;
Usage: $0 [OPTION]...&lt;br /&gt;
&lt;br /&gt;
Available options:&lt;br /&gt;
   -s N   Shift up the min temperature thresholds by N degrees&lt;br /&gt;
          (positive for quieter, negative for cooler).&lt;br /&gt;
          Max temperature thresholds are not affected.&lt;br /&gt;
   -S N   Shift up the max temperature thresholds by N degrees&lt;br /&gt;
          (positive for quieter, negative for cooler). DANGEROUS.&lt;br /&gt;
   -t     Test mode&lt;br /&gt;
   -q     Quiet mode&lt;br /&gt;
   -d     Daemon mode, go into background (implies -q)&lt;br /&gt;
   -l     Log to syslog&lt;br /&gt;
   -k     Kill already-running daemon&lt;br /&gt;
   -u     Tell already-running daemon that the system is being suspended&lt;br /&gt;
   -p     Pid file location for daemon mode, default: $PID_FILE&lt;br /&gt;
&amp;quot;&lt;br /&gt;
    exit 1;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
while getopts 's:S:qtdlp:kuh' OPT; do&lt;br /&gt;
    case &amp;quot;$OPT&amp;quot; in&lt;br /&gt;
        s) # shift thresholds&lt;br /&gt;
            MIN_THRESH_SHIFT=&amp;quot;$OPTARG&amp;quot;&lt;br /&gt;
            ;;&lt;br /&gt;
        S) # shift thresholds&lt;br /&gt;
            MAX_THRESH_SHIFT=&amp;quot;$OPTARG&amp;quot;&lt;br /&gt;
            ;;&lt;br /&gt;
        t) # test mode&lt;br /&gt;
            DRY_RUN=true&lt;br /&gt;
            ;;&lt;br /&gt;
        q) # quiet mode&lt;br /&gt;
            QUIET=true&lt;br /&gt;
            ;;&lt;br /&gt;
        d) # go into background and daemonize&lt;br /&gt;
            DAEMONIZE=true&lt;br /&gt;
            ;;&lt;br /&gt;
        l) # log to syslog&lt;br /&gt;
            SYSLOG=true&lt;br /&gt;
            ;;&lt;br /&gt;
        p) # different pidfile&lt;br /&gt;
            PID_FILE=&amp;quot;$OPTARG&amp;quot;&lt;br /&gt;
            ;;&lt;br /&gt;
        k) # kill daemon&lt;br /&gt;
            KILL_DAEMON=true&lt;br /&gt;
            ;;&lt;br /&gt;
        u) # suspend daemon&lt;br /&gt;
            SUSPEND_DAEMON=true&lt;br /&gt;
            ;;&lt;br /&gt;
        h) # short help&lt;br /&gt;
            usage&lt;br /&gt;
            ;;&lt;br /&gt;
        \?) # error&lt;br /&gt;
            usage&lt;br /&gt;
            ;;&lt;br /&gt;
    esac&lt;br /&gt;
done&lt;br /&gt;
[ $OPTIND -gt $# ] || usage  # no non-option args&lt;br /&gt;
&lt;br /&gt;
# no logger found, no syslog capabilities&lt;br /&gt;
$SYSLOG &amp;amp;&amp;amp; [ ! -x $LOGGER ] &amp;amp;&amp;amp; SYSLOG=false || :&lt;br /&gt;
&lt;br /&gt;
if $DRY_RUN; then&lt;br /&gt;
    echo &amp;quot;$0: Dry run, will not change fan state.&amp;quot;&lt;br /&gt;
    QUIET=false&lt;br /&gt;
    DAEMONIZE=false&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# Read the temperature sensor on new Hitachi drivers without spinning up the&lt;br /&gt;
# disk or unloading its head (this cannot be done using standard SMART).&lt;br /&gt;
# Works only with drivers/ide or new libata. Equivalent to hdparm -H in &amp;gt;=6.7.&lt;br /&gt;
read_hitachi_temp() { perl - &amp;quot;$@&amp;quot; &amp;lt;&amp;lt;'EOPERL'    # do it in Perl&lt;br /&gt;
    #!/usr/bin/perl&lt;br /&gt;
    $dev=&amp;quot;$ARGV[0]&amp;quot; or die &amp;quot;No device given.\n&amp;quot;;&lt;br /&gt;
    $HDIO_DRIVE_CMD=0x031f;&lt;br /&gt;
    $args=pack(&amp;quot;cccc&amp;quot;,0xf0,0,0x01,0);   # Sense Condition command&lt;br /&gt;
    open(DEV,&amp;quot;&amp;lt;&amp;quot;,$dev) or die &amp;quot;open(\&amp;quot;$dev\&amp;quot;): $!\n&amp;quot;;&lt;br /&gt;
    if (ioctl(DEV,$HDIO_DRIVE_CMD,$args)) {&lt;br /&gt;
       $nsect=(unpack(&amp;quot;cccc&amp;quot;,$args))[2];&lt;br /&gt;
       if ($nsect==0 || $nsect==0xff) {&lt;br /&gt;
           die &amp;quot;Temperature over/underflow.\n&amp;quot;;&lt;br /&gt;
       } elsif ($nsect==0x01) {  # Linux&amp;lt;=2.6.18 doesn't return ATA registers&lt;br /&gt;
           die &amp;quot;Old Linux kernel, readout not supported.\n&amp;quot;;&lt;br /&gt;
       } else {&lt;br /&gt;
           printf &amp;quot;%d\n&amp;quot;, $nsect/2-20;&lt;br /&gt;
       }&lt;br /&gt;
    } else {&lt;br /&gt;
        die &amp;quot;ioctl(\&amp;quot;$dev\&amp;quot;,HDIO_DRIVE_CMD,SENSE_CONDITION): $!\n&amp;quot;&lt;br /&gt;
    }&lt;br /&gt;
EOPERL&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
update_disk_temp() {&lt;br /&gt;
    if (( SECONDS &amp;gt;= DISK_POLL_TIME + DISK_POLL_PERIOD )); then&lt;br /&gt;
        LAST_DISK_TEMP=&amp;quot;-128&amp;quot;&lt;br /&gt;
        for DEV in {sda,hda}; do&lt;br /&gt;
            if [[ -b &amp;quot;/dev/$DEV&amp;quot; ]]; then&lt;br /&gt;
                local MODEL=`cat /sys/block/$DEV/device/model`&lt;br /&gt;
                if [[ &amp;quot;$MODEL&amp;quot; =~ &amp;quot;$HITACHI_MODELS&amp;quot; ]]; then&lt;br /&gt;
                    if HTEMP=`read_hitachi_temp &amp;quot;/dev/$DEV&amp;quot; 2&amp;gt;/dev/null`; then&lt;br /&gt;
                        LAST_DISK_TEMP=&amp;quot;$HTEMP&amp;quot;&lt;br /&gt;
                        break&lt;br /&gt;
                    fi&lt;br /&gt;
                fi&lt;br /&gt;
            fi&lt;br /&gt;
        done&lt;br /&gt;
        DISK_POLL_TIME=$SECONDS&lt;br /&gt;
    fi&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
thermometer() { # output list of temperatures&lt;br /&gt;
    # 8 basic temperatures from ibm-acpi:&lt;br /&gt;
    [[ -r $IBM_ACPI/thermal ]] || { echo &amp;quot;$0: Cannot read $IBM_ACPI/thermal&amp;quot; 2&amp;gt;&amp;amp;1 ; exit 1; }&lt;br /&gt;
    read THERMAL &amp;lt; $IBM_ACPI/thermal&lt;br /&gt;
    read X Y1 Y2 Y3 Y4 Y5 Y6 Y7 Y8 Z1 Z2 Z3 JNK &amp;lt; &amp;lt;(echo &amp;quot;$THERMAL&amp;quot;) &lt;br /&gt;
    [[ &amp;quot;$X&amp;quot; == &amp;quot;temperatures:&amp;quot; ]] || { echo &amp;quot;$0: Bad readout: \&amp;quot;$THERMAL\&amp;quot;&amp;quot; &amp;gt;&amp;amp;2;  exit 1; }&lt;br /&gt;
    echo -n &amp;quot;$Y1 $Y2 $Y3 $Y4 $Y5 $Y6 $Y7 $Y8 &amp;quot;;&lt;br /&gt;
    # 3 extra temperatures from ibm_acpi:&lt;br /&gt;
    if [[ -n &amp;quot;$Z1&amp;quot; &amp;amp;&amp;amp; -n &amp;quot;$Z2&amp;quot; &amp;amp;&amp;amp; -n &amp;quot;$Z3&amp;quot; ]]; then &lt;br /&gt;
        # ibm_acpi provided extra sensors from at EC offsets 0xC0 to 0xC2?&lt;br /&gt;
        echo -n &amp;quot;$SEP $Z1 $Z2 $Z3 &amp;quot;&lt;br /&gt;
    else &lt;br /&gt;
        [ -r $IBM_ACPI/ecdump ] || { echo &amp;quot;$0: Cannot read $IBM_ACPI/ecdump&amp;quot; 2&amp;gt;&amp;amp;1; exit 1; }&lt;br /&gt;
        perl -e 'm/^EC 0xc0: .(..) .(..) .(..) / and print hex($1).&amp;quot; &amp;quot;.hex($2).&amp;quot; &amp;quot;.hex($3).&amp;quot; &amp;quot; and exit 0 while &amp;lt;&amp;gt;; exit 1' &amp;lt; $IBM_ACPI/ecdump&lt;br /&gt;
    fi&lt;br /&gt;
    # 1 Disk drive temperatures:&lt;br /&gt;
    echo -n &amp;quot;$SEP $LAST_DISK_TEMP &amp;quot;&lt;br /&gt;
    # 1 HDAPS temperature (optional):&lt;br /&gt;
    if [ -r $HDAPS_TEMP ]; then&lt;br /&gt;
        Y=&amp;quot;`cat $HDAPS_TEMP`&amp;quot;&lt;br /&gt;
        (( &amp;quot;$Y&amp;quot; &amp;gt; 100 )) || echo -n &amp;quot;$Y &amp;quot;  # the HDAPS readouts are nonsensical right after resume&lt;br /&gt;
    fi&lt;br /&gt;
    return 0&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
speedometer() { # output fan speed RPM&lt;br /&gt;
    sed -n 's/^speed:[ \t]*//p' $IBM_ACPI/fan&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
setlevel() { # set fan speed level&lt;br /&gt;
    local LEVEL=$1&lt;br /&gt;
    if ! $DRY_RUN; then&lt;br /&gt;
        if $HAVE_LEVELCMD; then&lt;br /&gt;
        	echo &amp;quot;level $LEVEL&amp;quot; &amp;gt; $IBM_ACPI/fan&lt;br /&gt;
	else&lt;br /&gt;
		case &amp;quot;$LEVEL&amp;quot; in&lt;br /&gt;
		(auto)        LEVEL=0x80 ;;&lt;br /&gt;
		(disengaged)  LEVEL=0x40 ;;&lt;br /&gt;
		esac&lt;br /&gt;
        	echo 0x2F $LEVEL &amp;gt; $IBM_ACPI/ecdump&lt;br /&gt;
	fi&lt;br /&gt;
    fi&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
getlevel() { # get fan speed level&lt;br /&gt;
    perl -e 'm/^EC 0x20: .* .(..)$/ and print $1 and exit 0 while &amp;lt;&amp;gt;; exit 1' &amp;lt; $IBM_ACPI/ecdump&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
log() {&lt;br /&gt;
	$QUIET || echo &amp;quot;&amp;gt; $*&amp;quot;&lt;br /&gt;
	! $SYSLOG || $LOGGER -t &amp;quot;`basename $0`[$$]&amp;quot; &amp;quot;$*&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
cleanup() { # clean up after work&lt;br /&gt;
    $AM_DAEMON &amp;amp;&amp;amp; rm -f &amp;quot;$PID_FILE&amp;quot; 2&amp;gt; /dev/null&lt;br /&gt;
    log &amp;quot;Shutting down, switching to automatic fan control&amp;quot;&lt;br /&gt;
    if ! $DRY_RUN; then&lt;br /&gt;
        if $HAVE_LEVELCMD; then&lt;br /&gt;
            echo enable &amp;gt; $IBM_ACPI/fan&lt;br /&gt;
        else&lt;br /&gt;
            echo 0x2F 0x80 &amp;gt; $IBM_ACPI/ecdump&lt;br /&gt;
        fi&lt;br /&gt;
        if $HAVE_WATCHDOG; then&lt;br /&gt;
            echo watchdog 0 &amp;gt; $IBM_ACPI/fan  # disable watchdog&lt;br /&gt;
        fi&lt;br /&gt;
    fi&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
floor_div() {&lt;br /&gt;
    echo $(( (($1)+1000*($2))/($2) - 1000 ))&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
set_priority() {&lt;br /&gt;
    ! $DRY_RUN &amp;amp;&amp;amp; renice -10 -p $$&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
init_state() {&lt;br /&gt;
    IDX=0&lt;br /&gt;
    NEW_IDX=0&lt;br /&gt;
    START_TIME=0&lt;br /&gt;
    MAX_IDX=$(( ${#LEVELS[@]} - 1 ))&lt;br /&gt;
    SETTLE_LEFT=0&lt;br /&gt;
    RESETTLE_LEFT=0&lt;br /&gt;
    FIRST=true&lt;br /&gt;
    RESTART=false&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
control_fan() {&lt;br /&gt;
    # Enable the fan in default mode if anything goes wrong:&lt;br /&gt;
    set -e -E -u&lt;br /&gt;
    trap &amp;quot;cleanup; exit 2&amp;quot; HUP INT ABRT QUIT SEGV TERM&lt;br /&gt;
    trap &amp;quot;cleanup&amp;quot; EXIT&lt;br /&gt;
    trap &amp;quot;log 'Got SIGUSR1'; setlevel 0; RESTART=true; sleep $SUSPEND_TIME&amp;quot; USR1&lt;br /&gt;
    if ! $DRY_RUN &amp;amp;&amp;amp; $HAVE_WATCHDOG; then&lt;br /&gt;
        log &amp;quot;Activating watchdog with delay $WATCHDOG_DELAY sec&amp;quot;&lt;br /&gt;
        echo &amp;quot;watchdog $WATCHDOG_DELAY&amp;quot; &amp;gt; $IBM_ACPI/fan&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
    init_state&lt;br /&gt;
    log &amp;quot;Starting dynamic fan control&amp;quot;&lt;br /&gt;
&lt;br /&gt;
    # Control loop:&lt;br /&gt;
    while true; do&lt;br /&gt;
        # Get readouts&lt;br /&gt;
        update_disk_temp  # don't do this in a subshell, it's stateful&lt;br /&gt;
        TEMPS=`thermometer`&lt;br /&gt;
        $QUIET || SPEED=`speedometer`&lt;br /&gt;
        $QUIET || ECLEVEL=`getlevel`&lt;br /&gt;
        NOW=`date +%s`&lt;br /&gt;
        if echo &amp;quot;$TEMPS&amp;quot; | grep -q &amp;quot;[^ 0-9$SEP\n-]&amp;quot;; then&lt;br /&gt;
            echo &amp;quot;Invalid character in temperatures: $TEMPS&amp;quot; &amp;gt;&amp;amp;2; exit 1;&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        # Calculate new level index by placing temperatures into regions of &amp;quot;Z&amp;quot; values:&lt;br /&gt;
        # Z &amp;gt;= 2*I means &amp;quot;must be at index I or higher&amp;quot;&lt;br /&gt;
        # Z  = 2*I+1 is hysteresis: &amp;quot;don't step down if currently at I+1&amp;quot;&lt;br /&gt;
        # The set of temperatures for each Z value are as follows, denoting d=(MAX-MIN)/(2*(MAX_IDX-1)) :&lt;br /&gt;
        #   Z=0:         {-infty..MIN-OFF_THRESH_DELTA)     Z=1:   {MIN-OFF_THRESH_DELTA..MIN}&lt;br /&gt;
        #   Z=2:         {MIN..MIN+d}         Z=3:   {MIN+d..MIN+2d}&lt;br /&gt;
        #   Z=4:         {MIN+2d..MIN+3d}     Z=5:   {MIN+3d..MIN+4d}   ...&lt;br /&gt;
        #   Z=2*MAX_IDX: {MAX..infty}&lt;br /&gt;
&lt;br /&gt;
        # Enforce minimum time in this level before stepping down:&lt;br /&gt;
        MAX_Z=$(( IDX&amp;gt;0 ? ( NOW&amp;gt;START_TIME+MIN_WAIT ? 2*(IDX-1) : 2*IDX ) : 0 ))&lt;br /&gt;
&lt;br /&gt;
        # Go over all sensors and compute the Z value; compute the maximum Z and a pretty-printed string:&lt;br /&gt;
        SENSOR=0&lt;br /&gt;
        Z_STR=&amp;quot;$MAX_Z+&amp;quot;&lt;br /&gt;
        TEMP_STR=&amp;quot;&amp;quot;;&lt;br /&gt;
        for TEMP in $TEMPS; do&lt;br /&gt;
            if [[ &amp;quot;$TEMP&amp;quot; == &amp;quot;$SEP&amp;quot; ]]; then   # ignore this (a separator for visual aid)&lt;br /&gt;
                Z_STR=&amp;quot;${Z_STR}$SEP&amp;quot;&lt;br /&gt;
                TEMP_STR=&amp;quot;${TEMP_STR}$SEP &amp;quot;&lt;br /&gt;
                continue&lt;br /&gt;
            fi&lt;br /&gt;
            [ $((2*SENSOR+2)) -le ${#THRESHOLDS[@]} ] ||&lt;br /&gt;
                { echo &amp;quot;Too many sensors, not enough values in THRESHOLDS&amp;quot; 2&amp;gt;&amp;amp;1; exit 1; }&lt;br /&gt;
            if [[ $TEMP == -128 || $TEMP == 128 ]]; then&lt;br /&gt;
                Z='_'; TEMP='_' # inactive sensor&lt;br /&gt;
            else&lt;br /&gt;
                MIN=$((THRESHOLDS[SENSOR*2] + MIN_THRESH_SHIFT))&lt;br /&gt;
                MAX=$((THRESHOLDS[SENSOR*2+1] + MAX_THRESH_SHIFT ))&lt;br /&gt;
                [[ $MAX -le $MIN ]] &amp;amp;&amp;amp; \&lt;br /&gt;
                    { echo 'Reversed temperature thresholds (shifted too much?)' 2&amp;gt;&amp;amp;1; exit 1; }&lt;br /&gt;
                if (( TEMP &amp;lt; MIN - OFF_THRESH_DELTA )); then&lt;br /&gt;
                    Z=0&lt;br /&gt;
                else  # compute Z value for this sensor (see above):&lt;br /&gt;
                    Z=$(( `floor_div $(( 2*(TEMP-MIN)*(MAX_IDX-1) )) $((MAX-MIN))` + 2 ))&lt;br /&gt;
                    [ $Z -ge 1 ] || Z=1&lt;br /&gt;
                    [ $Z -le $((2*MAX_IDX)) ] || Z=$((2*MAX_IDX))&lt;br /&gt;
                fi&lt;br /&gt;
                [ $MAX_Z -gt $Z ] || MAX_Z=$Z&lt;br /&gt;
            fi&lt;br /&gt;
            Z_STR=&amp;quot;${Z_STR}${Z}&amp;quot;&lt;br /&gt;
            TEMP_STR=&amp;quot;${TEMP_STR}${TEMP} &amp;quot;&lt;br /&gt;
            (( ++SENSOR ))&lt;br /&gt;
        done&lt;br /&gt;
        [ $SENSOR -gt 0 ] || { echo &amp;quot;No temperatures read&amp;quot; &amp;gt;&amp;amp;2; exit 1; }&lt;br /&gt;
&lt;br /&gt;
        HYS=$(( (MAX_Z == 2*IDX-1) &amp;amp;&amp;amp; ++MAX_Z )) # hysteresis&lt;br /&gt;
        NEW_IDX=$(( MAX_Z/2 ))&lt;br /&gt;
&lt;br /&gt;
        # Interrupted by a signal?&lt;br /&gt;
        if $RESTART; then&lt;br /&gt;
            init_state&lt;br /&gt;
            log &amp;quot;Resetting state&amp;quot;&lt;br /&gt;
            continue&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        # Transition&lt;br /&gt;
        $FIRST &amp;amp;&amp;amp; OLDLEVEL='?' || OLDLEVEL=${LEVELS[$IDX]}&lt;br /&gt;
        NEWLEVEL=${LEVELS[$NEW_IDX]}&lt;br /&gt;
        $QUIET || echo &amp;quot;L=$OLDLEVEL-&amp;gt;$NEWLEVEL EC=$ECLEVEL RPM=`printf %4s $SPEED` T=($TEMP_STR) Z=$Z_STR&amp;quot;&lt;br /&gt;
        if [ &amp;quot;$OLDLEVEL&amp;quot; != &amp;quot;$NEWLEVEL&amp;quot; ]; then&lt;br /&gt;
            START_TIME=$NOW&lt;br /&gt;
            log &amp;quot;Changing fan level: $OLDLEVEL-&amp;gt;$NEWLEVEL  (temps: $TEMP_STR)&amp;quot;&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        setlevel $NEWLEVEL&lt;br /&gt;
&lt;br /&gt;
        sleep $INTERVAL&lt;br /&gt;
&lt;br /&gt;
        # If needed, apply anti-pulsing hack after a settle-down period (and occasionally re-settle):&lt;br /&gt;
        if [ ${ANTIPULSE[${NEW_IDX}]} == 1 ]; then &lt;br /&gt;
            if [ $NEWLEVEL != $OLDLEVEL -o $RESETTLE_LEFT -le 0 ]; then # start settling?&lt;br /&gt;
                SETTLE_LEFT=$SETTLE_TIME&lt;br /&gt;
                RESETTLE_LEFT=$RESETTLE_TIME&lt;br /&gt;
            fi&lt;br /&gt;
            if [ $SETTLE_LEFT -ge 0 ]; then&lt;br /&gt;
                SETTLE_LEFT=$((SETTLE_LEFT-INTERVAL))&lt;br /&gt;
            else&lt;br /&gt;
                setlevel disengaged # disengage briefly to fool embedded controller&lt;br /&gt;
                sleep 0.5&lt;br /&gt;
                RESETTLE_LEFT=$((RESETTLE_LEFT-INTERVAL))&lt;br /&gt;
            fi&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        IDX=$NEW_IDX&lt;br /&gt;
        FIRST=false&lt;br /&gt;
    done&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
if $KILL_DAEMON || $SUSPEND_DAEMON; then &lt;br /&gt;
    if [ -f &amp;quot;$PID_FILE&amp;quot; ]; then&lt;br /&gt;
	set -e&lt;br /&gt;
	DPID=&amp;quot;`cat \&amp;quot;$PID_FILE\&amp;quot;`&amp;quot; &lt;br /&gt;
	if $KILL_DAEMON; then&lt;br /&gt;
        	kill &amp;quot;$DPID&amp;quot;&lt;br /&gt;
		rm &amp;quot;$PID_FILE&amp;quot;&lt;br /&gt;
		$QUIET || echo &amp;quot;Killed process $DPID&amp;quot;&lt;br /&gt;
	else # SUSPEND_DAEMON&lt;br /&gt;
		kill -USR1 &amp;quot;$DPID&amp;quot;&lt;br /&gt;
		$QUIET || echo &amp;quot;Sent SIGUSR1 to $DPID&amp;quot;&lt;br /&gt;
	fi&lt;br /&gt;
    else&lt;br /&gt;
        $QUIET || echo &amp;quot;Daemon not running.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
elif $DAEMONIZE ; then&lt;br /&gt;
    if [ -e &amp;quot;$PID_FILE&amp;quot; ]; then&lt;br /&gt;
        echo &amp;quot;$0: File $PID_FILE already exists, refusing to run.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
    else&lt;br /&gt;
        set_priority&lt;br /&gt;
        AM_DAEMON=true QUIET=true control_fan 0&amp;lt;&amp;amp;- 1&amp;gt;&amp;amp;- 2&amp;gt;&amp;amp;- &amp;amp;&lt;br /&gt;
        echo $! &amp;gt; &amp;quot;$PID_FILE&amp;quot;&lt;br /&gt;
        exit 0&lt;br /&gt;
    fi&lt;br /&gt;
else&lt;br /&gt;
    [ -e &amp;quot;$PID_FILE&amp;quot; ] &amp;amp;&amp;amp; echo &amp;quot;WARNING: daemon already running&amp;quot;&lt;br /&gt;
    set_priority&lt;br /&gt;
    control_fan&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/build-experimental-X&amp;diff=62551</id>
		<title>Code/build-experimental-X</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/build-experimental-X&amp;diff=62551"/>
		<updated>2025-04-11T07:27:42Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put script in &amp;lt;pre&amp;gt; block.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
# Script to fetch and build X.org (incl. XCB and pixman), DRI, Mesa and&lt;br /&gt;
# xkeyboard-config from CVS and GIT, and save full git snapshots of their&lt;br /&gt;
# source and installation.&lt;br /&gt;
#&lt;br /&gt;
# Default action:&lt;br /&gt;
# - Create/update a git repository for each module, under $HOME/3d-pit.&lt;br /&gt;
# - Install all modules, under $HOME/3d-pit/install&lt;br /&gt;
# - Make $HOME/3d-pit/install a git repository to track the installed binaries&lt;br /&gt;
# - Make $HOME/3d-pit a git super-repository which tracks all of the above&lt;br /&gt;
#   using the submodule mechanism of git &amp;gt;= 1.5.3.&lt;br /&gt;
#&lt;br /&gt;
# Each of these can be disabled via command line (see the code table below).&lt;br /&gt;
#&lt;br /&gt;
# Source: http://thinkwiki.org/wiki/How_to_compile_an_experimental_X_server&lt;br /&gt;
# See also:&lt;br /&gt;
#   http://wiki.x.org/wiki/ModularDevelopersGuide&lt;br /&gt;
#   http://wiki.x.org/wiki/GitPage&lt;br /&gt;
#   http://gitweb.freedesktop.org&lt;br /&gt;
#   http://dri.freedesktop.org/wiki/Building&lt;br /&gt;
#   http://www.mesa3d.org/repository.html&lt;br /&gt;
#   http://www.mesa3d.org/install.html&lt;br /&gt;
#   http://web.telia.com/~u89404340/touchpad&lt;br /&gt;
#   http://www.freedesktop.org/wiki/Software_2fXKeyboardConfig&lt;br /&gt;
#   http://gitweb.freedesktop.org/?p=xorg/util/modular.git;a=blob;f=build.sh&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# X.org setup&lt;br /&gt;
# This is a list of modules that are in flux and likely to be related to&lt;br /&gt;
# whatever you're testing (or are required for the build), sorted by&lt;br /&gt;
# build order (see util/modular/build.sh for dependencies).&lt;br /&gt;
# Check CVS and the above URLs for other modules.&lt;br /&gt;
# For exhaustive list, see &lt;br /&gt;
# get -qO - http://gitweb.freedesktop.org/ \&lt;br /&gt;
# | perl -ne 'print &amp;quot;$1\n&amp;quot; if m!&amp;lt;a href=&amp;quot;/\?p=([^;]+);a=summary&amp;quot;&amp;gt;!' \&lt;br /&gt;
# | egrep '^xcb/|^xorg/|^pixman/'&lt;br /&gt;
&lt;br /&gt;
XORG_MODULES=(&lt;br /&gt;
  xorg/util/macros&lt;br /&gt;
  xorg/proto/{bigreqs,composite,fixes,damage,gl,input,kb,pm,randr,resource,xext,xcmisc}proto&lt;br /&gt;
  xorg/proto/{fontcache,fonts,kb}proto&lt;br /&gt;
  xorg/proto/{render,scrnsaver,video}proto&lt;br /&gt;
  xorg/proto/{x11,xf86bigfont,xf86dga,xf86dri,xf86misc,xf86vidmode,xinerama}proto&lt;br /&gt;
  xcb/proto&lt;br /&gt;
  xorg/lib/lib{xtrans,Xau,Xdmcp}&lt;br /&gt;
  xcb/libxcb&lt;br /&gt;
  xorg/lib/lib{X11,ICE,SM,Xt,Xmu,Xcomposite,Xrender,Xdamage,Xcursor,Xi,Xinerama}&lt;br /&gt;
  xorg/lib/lib{Xfont,Xfontcache,Xft}&lt;br /&gt;
  xorg/lib/lib{xkbui,Xrandr,Xv,XvMC,Xxf86dga,Xxf86misc,Xxf86vm,pciaccess}&lt;br /&gt;
  pixman&lt;br /&gt;
  xorg/xserver&lt;br /&gt;
  xorg/driver/xf86-video-ati&lt;br /&gt;
  xorg/driver/xf86-input-{mouse,keyboard,joystick,evdev}&lt;br /&gt;
  xorg/app/{xkbutils,xkbcomp,setxkbmap,xrandr,xsetpointer,xbacklight}&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Init&lt;br /&gt;
&lt;br /&gt;
FETCH=true&lt;br /&gt;
BUILD=true&lt;br /&gt;
RECONFIGURE=false       # Reconfigure everything even if unchanged from last run&lt;br /&gt;
MAKE_CLEAN=false        # If true, run &amp;quot;make clean&amp;quot; before building.&lt;br /&gt;
GIT_CLEAN=false         # Use &amp;quot;git clean&amp;quot; to delete all non-source files before building.&lt;br /&gt;
SUPERMODULE=true        # Take meta-snapshots using Git super/submodule&lt;br /&gt;
&lt;br /&gt;
for OPT in &amp;quot;$@&amp;quot;; do&lt;br /&gt;
	case &amp;quot;$OPT&amp;quot; in&lt;br /&gt;
		(--no-fetch)       FETCH=false ;;&lt;br /&gt;
		(--no-build)       BUILD=false ;;&lt;br /&gt;
		(--no-supermodule) SUPERMODULE=false ;;&lt;br /&gt;
		(--reconfigure)    RECONFIGURE=true ;;&lt;br /&gt;
		(--make-clean)     MAKE_CLEAN=true ;;&lt;br /&gt;
		(--git-clean)      GIT_CLEAN=true ;;&lt;br /&gt;
		(*) echo &amp;quot;Unknown option&amp;quot; &amp;gt;&amp;amp;2; exit 1 ;;&lt;br /&gt;
	esac&lt;br /&gt;
done&lt;br /&gt;
&lt;br /&gt;
PIT=$HOME/3d-pit       # Download and build here&lt;br /&gt;
DEST_SUBDIR=install    # Install in this subdirectory of $PIT&lt;br /&gt;
USE_XCB=false          # Use XCB?&lt;br /&gt;
FLAGS='-O2 -g -march=pentium-m'&lt;br /&gt;
&lt;br /&gt;
DEST=$PIT/$DEST_SUBDIR&lt;br /&gt;
&lt;br /&gt;
trap &amp;quot;echo Aborting.; exit 1&amp;quot; ERR&lt;br /&gt;
set -E&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Support functions&lt;br /&gt;
&lt;br /&gt;
die() {&lt;br /&gt;
  echo &amp;quot;$*&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
run() {&lt;br /&gt;
  echo &amp;quot;@`pwd`:  $@&amp;quot;&lt;br /&gt;
  &amp;quot;$@&amp;quot; || { echo &amp;quot;ERROR: Command \&amp;quot;$*\&amp;quot; failed in `pwd`&amp;quot;; exit 1; }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
nothing_to_commit() {&lt;br /&gt;
  git status &amp;gt; /dev/null   # Force check of files for which only the timestamp changed.&lt;br /&gt;
  git diff --quiet HEAD &amp;gt; /dev/null&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
fetch_from_git() {&lt;br /&gt;
  PARENT_DIR=&amp;quot;$1&amp;quot;&lt;br /&gt;
  GIT_REP=&amp;quot;$2&amp;quot;&lt;br /&gt;
  MODULE=&amp;quot;$3&amp;quot;&lt;br /&gt;
  DIR=&amp;quot;${4:-$MODULE}&amp;quot;&lt;br /&gt;
  FULLDIR=&amp;quot;$PARENT_DIR/$DIR&amp;quot;&lt;br /&gt;
  RELDIR=&amp;quot;${FULLDIR#$PIT/}&amp;quot;&lt;br /&gt;
  if [ -d &amp;quot;$FULLDIR&amp;quot; ]; then &lt;br /&gt;
    cd &amp;quot;$FULLDIR&amp;quot;&lt;br /&gt;
    ORIG_HEAD=`git rev-parse HEAD`&lt;br /&gt;
    run git pull&lt;br /&gt;
    NEW_HEAD=`git rev-parse HEAD`&lt;br /&gt;
    [[ &amp;quot;$ORIG_HEAD&amp;quot; == &amp;quot;$NEW_HEAD&amp;quot; ]] || run git shortlog ORIG_HEAD..HEAD | cat&lt;br /&gt;
  else&lt;br /&gt;
    run cd &amp;quot;$PARENT_DIR&amp;quot;&lt;br /&gt;
    run git clone &amp;quot;$GIT_REP/$MODULE&amp;quot; &amp;quot;$DIR&amp;quot;&lt;br /&gt;
    cd &amp;quot;$DIR&amp;quot;&lt;br /&gt;
    git gc&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  add_to_supermodule &amp;quot;$RELDIR&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
fetch_from_cvs() {&lt;br /&gt;
  CVS_SERVER=&amp;quot;$1&amp;quot;&lt;br /&gt;
  DIR=&amp;quot;$2&amp;quot;&lt;br /&gt;
  GITIGNORES=&amp;quot;$3&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  run cd $PIT&lt;br /&gt;
  if [ ! -d $DIR ]; then&lt;br /&gt;
    grep -qF $CVS_SERVER ~/.cvspass || run cvs -d $CVS_SERVER login&lt;br /&gt;
    run cvs -z3 -d $CVS_SERVER co $DIR&lt;br /&gt;
&lt;br /&gt;
    cd $PIT/$DIR&lt;br /&gt;
    run git init&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  cd $PIT/$DIR&lt;br /&gt;
  run cvs -z3 update -ACPd -I .gitignore -I .git&lt;br /&gt;
  find . -name .cvsignore | while read X; do cp &amp;quot;$X&amp;quot; &amp;quot;${X%/.cvsignore}/.gitignore&amp;quot;; done&lt;br /&gt;
  echo -e &amp;quot;$GITIGNORES&amp;quot; &amp;gt;&amp;gt; .gitignore&lt;br /&gt;
  run git add .&lt;br /&gt;
  nothing_to_commit || run git commit -a -m &amp;quot;`date +'Fetched at %Y-%m-%d %H:%M:%S'`&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# We could use git-cvsimport instead, but that's way too slow:&lt;br /&gt;
#  mkdir -p $PIT/$DIR&lt;br /&gt;
#  cd $PIT/$DIR&lt;br /&gt;
#  git-cvsimport -v -d &amp;quot;$CVS_SERVER&amp;quot; -r origin&lt;br /&gt;
&lt;br /&gt;
  add_to_supermodule &amp;quot;$DIR&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Handing git super/submodules&lt;br /&gt;
&lt;br /&gt;
if $SUPERMODULE; then&lt;br /&gt;
  which git-submodule &amp;gt;&amp;amp;/dev/null || \&lt;br /&gt;
    die &amp;quot;Error: git &amp;gt;= 1.3.5 required for submodule support. Try --no-supermodule.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  run mkdir -p $PIT&lt;br /&gt;
  cd $PIT&lt;br /&gt;
  if [ ! -d .git ]; then&lt;br /&gt;
     run git init&lt;br /&gt;
     echo -e 'xorg/autoconf.cache' &amp;gt; .gitignore&lt;br /&gt;
     run git add .gitignore&lt;br /&gt;
     run git commit -m 'initial'&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  # Add new submodule's repository to the supermodule's .gitmodules&lt;br /&gt;
  add_to_supermodule_gitmodules() {&lt;br /&gt;
    SUBDIR=&amp;quot;$1&amp;quot;&lt;br /&gt;
    GIT_CONFIG=$PIT/.gitmodules git config &amp;quot;submodule.$SUBDIR.path&amp;quot; &amp;quot;$SUBDIR&amp;quot;&lt;br /&gt;
    GIT_CONFIG=$PIT/.gitmodules git config &amp;quot;submodule.$SUBDIR.url&amp;quot; &amp;quot;$SUBDIR&amp;quot;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  add_to_supermodule() {&lt;br /&gt;
    cd $PIT&lt;br /&gt;
    # add_to_supermodule_alternates &amp;quot;$1&amp;quot;&lt;br /&gt;
    add_to_supermodule_gitmodules &amp;quot;$1&amp;quot;&lt;br /&gt;
    run git add &amp;quot;$1&amp;quot;&lt;br /&gt;
  }&lt;br /&gt;
else&lt;br /&gt;
  add_to_supermodule() { true; }&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Directory hashes for change detection&lt;br /&gt;
&lt;br /&gt;
LAST_HASH=.last_dir_hash&lt;br /&gt;
&lt;br /&gt;
dir_hash() {&lt;br /&gt;
  find . \( -name $LAST_HASH -o -path ./.git -prune \) -o -type f -ls | sort | md5sum&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
dir_hash_changed() {&lt;br /&gt;
  $RECONFIGURE || [ ! -f $LAST_HASH ] || [ &amp;quot;`dir_hash`&amp;quot; != &amp;quot;`cat $LAST_HASH`&amp;quot; ]&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
save_dir_hash() {&lt;br /&gt;
  dir_hash &amp;gt; $LAST_HASH&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Fetching and building libDRM and DRM kernel drivers&lt;br /&gt;
&lt;br /&gt;
fetch_drm() {&lt;br /&gt;
  echo &amp;quot;########### Fetch DRM ###########&amp;quot;&lt;br /&gt;
  DRM_GIT=git://anongit.freedesktop.org/git/mesa&lt;br /&gt;
  fetch_from_git &amp;quot;$PIT&amp;quot; &amp;quot;$DRM_GIT&amp;quot; drm&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
build_libdrm() {&lt;br /&gt;
  echo &amp;quot;########### Build libdrm ###########&amp;quot;&lt;br /&gt;
  run cd $PIT/drm&lt;br /&gt;
  ! $GIT_CLEAN  || run git clean -x -d&lt;br /&gt;
  if dir_hash_changed; then&lt;br /&gt;
    run ./autogen.sh&lt;br /&gt;
    CFLAGS=&amp;quot;$FLAGS&amp;quot; run ./configure --prefix=$DEST --quiet&lt;br /&gt;
    save_dir_hash&lt;br /&gt;
  fi&lt;br /&gt;
  ! $MAKE_CLEAN || run make clean&lt;br /&gt;
  run make&lt;br /&gt;
  save_dir_hash&lt;br /&gt;
  run make install&lt;br /&gt;
  save_dir_hash&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
build_drm_modules() {&lt;br /&gt;
  echo &amp;quot;########### Build DRM kernel modules ###########&amp;quot;&lt;br /&gt;
  run cd $PIT/drm/linux-core&lt;br /&gt;
  ! $GIT_CLEAN  || run git clean -x -d&lt;br /&gt;
  ! $MAKE_CLEAN || run make clean&lt;br /&gt;
  run make DRM_MODULES=&amp;quot;radeon&amp;quot;&lt;br /&gt;
  run sudo sh -c \&lt;br /&gt;
    'rm -fv /lib/modules/`uname -r`/kernel/drivers/char/drm/*.ko; \&lt;br /&gt;
     cp -v *.ko /lib/modules/`uname -r`/extra/; \&lt;br /&gt;
     /sbin/depmod -a'&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Fetching Mesa&lt;br /&gt;
&lt;br /&gt;
fetch_mesa() {&lt;br /&gt;
  echo &amp;quot;########### Fetching Mesa ###########&amp;quot;&lt;br /&gt;
  MESA_GIT=git://anongit.freedesktop.org/git/mesa&lt;br /&gt;
  run mkdir -p $PIT&lt;br /&gt;
  run cd $PIT&lt;br /&gt;
  fetch_from_git &amp;quot;$PIT&amp;quot; &amp;quot;$MESA_GIT&amp;quot; mesa&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Building Mesa (do this after installing base X.org libraries&lt;br /&gt;
&lt;br /&gt;
build_mesa() { (&lt;br /&gt;
  echo &amp;quot;########### Building Mesa ###########&amp;quot;&lt;br /&gt;
  # This uses both old-style and new-style vars, to support older Mesa snapshots.&lt;br /&gt;
  run cd $PIT/mesa&lt;br /&gt;
  export DRM_SOURCE_PATH=$PIT/drm&lt;br /&gt;
  export PKG_CONFIG_PATH=&amp;quot;$DEST/lib/pkgconfig:$PKG_CONFIG_PATH&amp;quot;&lt;br /&gt;
  export DRM_SOURCE_PATH=&amp;quot;$PIT/drm&amp;quot;&lt;br /&gt;
  export DESTDIR=$DEST  INSTALL_DIR=$DEST&lt;br /&gt;
  export DRI_DRIVER_INSTALL_DIR=$DEST/lib/dri&lt;br /&gt;
  export DRI_DIRS='r300 r200 r128 radeon'&lt;br /&gt;
  export OPT_FLAGS=&amp;quot;$FLAGS&amp;quot;&lt;br /&gt;
  export PATH=&amp;quot;$DEST/bin:$PATH&amp;quot;&lt;br /&gt;
  run mkdir -p $DRI_DRIVER_INSTALL_DIR&lt;br /&gt;
  ! $GIT_CLEAN  || run git clean -x -d&lt;br /&gt;
  ! $MAKE_CLEAN || run make clean&lt;br /&gt;
  if [ -e configs/current ]; then&lt;br /&gt;
    run make -e&lt;br /&gt;
  else&lt;br /&gt;
    run make -e linux-dri-x86&lt;br /&gt;
  fi&lt;br /&gt;
  run make -e install&lt;br /&gt;
  run cp -v lib/*_dri.so $DRI_DRIVER_INSTALL_DIR&lt;br /&gt;
) }&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Fetching X.org&lt;br /&gt;
&lt;br /&gt;
fetch_xorg() {&lt;br /&gt;
  echo &amp;quot;########### Fetching (selected) X.org modules ###########&amp;quot;&lt;br /&gt;
  XORG_GIT=git://anongit.freedesktop.org/git&lt;br /&gt;
  run mkdir -p $PIT/xorg&lt;br /&gt;
  for D in &amp;quot;${XORG_MODULES[@]}&amp;quot;; do&lt;br /&gt;
    if [[ $D == xcb/* ]] &amp;amp;&amp;amp; ! $USE_XCB; then continue; fi&lt;br /&gt;
    fetch_from_git $PIT/xorg &amp;quot;$XORG_GIT&amp;quot; &amp;quot;$D&amp;quot; &amp;quot;${D#xorg/}&amp;quot;&lt;br /&gt;
  done&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Building and installing X.org&lt;br /&gt;
# (On repeated runs we avoid rerunning autotools if nothing changed.)&lt;br /&gt;
&lt;br /&gt;
build_x_module() { (&lt;br /&gt;
  D=&amp;quot;${1#xorg/}&amp;quot;&lt;br /&gt;
  echo &amp;quot;########### Building xorg/$D ###########&amp;quot;&lt;br /&gt;
  export PATH=&amp;quot;$DEST/bin:$PATH&amp;quot;&lt;br /&gt;
  export PKG_CONFIG_PATH=&amp;quot;$DEST/lib/pkgconfig:$PKG_CONFIG_PATH&amp;quot;&lt;br /&gt;
  export ACLOCAL=&amp;quot;${AC_LOCAL:-aclocal} -I $DEST/share/aclocal&amp;quot;&lt;br /&gt;
  export LD_LIBRARY_PATH=&amp;quot;$DEST/lib:$LD_LIBRARY_PATH&amp;quot;&lt;br /&gt;
&lt;br /&gt;
  if [ $D == &amp;quot;xserver&amp;quot; ]; then&lt;br /&gt;
    CONF_OPT=&amp;quot;--with-mesa-source=$PIT/mesa --enable-xorg --disable-dmx --disable-xvfb --disable-xnest --disable-xprint --disable-freetype --disable-xselinux&amp;quot;&lt;br /&gt;
  elif [ $D == &amp;quot;lib/libX11&amp;quot; ] &amp;amp;&amp;amp; ! $USE_XCB; then&lt;br /&gt;
    CONF_OPT=&amp;quot;--with-xcb=no&amp;quot;&lt;br /&gt;
  else&lt;br /&gt;
    CONF_OPT=&lt;br /&gt;
  fi&lt;br /&gt;
&lt;br /&gt;
  run cd $PIT/xorg/$D&lt;br /&gt;
  ! $GIT_CLEAN  || run git clean -x -d&lt;br /&gt;
  if dir_hash_changed; then&lt;br /&gt;
    CFLAGS=&amp;quot;$FLAGS&amp;quot; run sh autogen.sh --prefix=$DEST --quiet $CONF_OPT&lt;br /&gt;
      # --cache-file=$PIT/xorg/autoconf.cache &lt;br /&gt;
    save_dir_hash&lt;br /&gt;
  fi&lt;br /&gt;
  ! $MAKE_CLEAN || run make clean&lt;br /&gt;
  run make&lt;br /&gt;
  save_dir_hash&lt;br /&gt;
  run make install&lt;br /&gt;
  save_dir_hash&lt;br /&gt;
&lt;br /&gt;
  if [ $D == &amp;quot;pixman&amp;quot; ]; then # as of 2007-08-07 pixman needs this hack:&lt;br /&gt;
    [ -e $DEST/include/pixman.h ] || run ln -fs pixman-1/pixman.h $DEST/include/pixman.h&lt;br /&gt;
  fi&lt;br /&gt;
) }&lt;br /&gt;
&lt;br /&gt;
build_xorg() {&lt;br /&gt;
  run cd $PIT/xorg&lt;br /&gt;
  run mkdir -p $DEST/share/aclocal&lt;br /&gt;
  run mkdir -p $DEST/var/log&lt;br /&gt;
  for D in &amp;quot;${XORG_MODULES[@]}&amp;quot;; do&lt;br /&gt;
    if [[ $D == xcb/* ]] &amp;amp;&amp;amp; ! $USE_XCB; then continue; fi&lt;br /&gt;
    build_x_module $D || return 1&lt;br /&gt;
  done&lt;br /&gt;
  run sudo sh -c &amp;quot;chown -v root $DEST/bin/Xorg; \&lt;br /&gt;
                  chmod -v 4750 $DEST/bin/Xorg&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Fetching and building xkeyboard-config&lt;br /&gt;
&lt;br /&gt;
fetch_xkeyboard_config() {&lt;br /&gt;
  echo &amp;quot;########### Fetching xkeyboard-config ###########&amp;quot;&lt;br /&gt;
  XKBC_CVS=&amp;quot;:pserver:anoncvs@cvs.freedesktop.org:2401/cvs/xkeyboard-config&amp;quot;&lt;br /&gt;
  XKBC_DIR=xkeyboard-config&lt;br /&gt;
  XKBC_GITIGNORES='install-sh\nmissing\npo/stamp-it'&lt;br /&gt;
  fetch_from_cvs &amp;quot;$XKBC_CVS&amp;quot; &amp;quot;$XKBC_DIR&amp;quot; &amp;quot;$XKBC_GITIGNORES&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
build_xkeyboard_config() { (&lt;br /&gt;
  echo &amp;quot;########### Building xkeyboard-config ###########&amp;quot;&lt;br /&gt;
  run cd $PIT/xkeyboard-config&lt;br /&gt;
  run ./autogen.sh&lt;br /&gt;
  export PKG_CONFIG_PATH=&amp;quot;$DEST/lib/pkgconfig:$PKG_CONFIG_PATH&amp;quot;&lt;br /&gt;
  export PATH=&amp;quot;$DEST/bin:$PATH&amp;quot;&lt;br /&gt;
  CFLAGS=&amp;quot;$FLAGS&amp;quot; run ./configure --quiet --prefix=$DEST \&lt;br /&gt;
    --with-xkb-base=$DEST/share/X11/xkb --with-xkb-rules-symlink=xorg&lt;br /&gt;
  run make&lt;br /&gt;
  # &amp;quot;make install&amp;quot; replaces share/X11/xkb/compiled.tmp with a junk symlink, so override it:&lt;br /&gt;
  mv $DEST/share/X11/xkb/compiled $DEST/share/X11/xkb/compiled.tmp&lt;br /&gt;
  run make install&lt;br /&gt;
  rm -f $DEST/share/X11/xkb/compiled&lt;br /&gt;
  mv $DEST/share/X11/xkb/compiled.tmp $DEST/share/X11/xkb/compiled&lt;br /&gt;
) }&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Fetching and building the synaptics driver&lt;br /&gt;
&lt;br /&gt;
fetch_synaptics() {&lt;br /&gt;
  echo &amp;quot;########### Fetch synaptics ###########&amp;quot;&lt;br /&gt;
  SYN_GIT=http://web.telia.com/~u89404340/touchpad/synaptics/.git&lt;br /&gt;
  fetch_from_git &amp;quot;$PIT&amp;quot; &amp;quot;$SYN_GIT&amp;quot; '' synaptics&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
build_synaptics() { (&lt;br /&gt;
  echo &amp;quot;########### Build synaptics ###########&amp;quot;&lt;br /&gt;
  run cd $PIT/synaptics&lt;br /&gt;
  export PKG_CONFIG_PATH=&amp;quot;$DEST/lib/pkgconfig:$PKG_CONFIG_PATH&amp;quot;&lt;br /&gt;
  export PATH=&amp;quot;$DEST/bin:$PATH&amp;quot;&lt;br /&gt;
  export CPATH=&amp;quot;$DEST/include:$CPATH&amp;quot;&lt;br /&gt;
  ! $GIT_CLEAN  || run git clean -x -d&lt;br /&gt;
  ! $MAKE_CLEAN || run make clean&lt;br /&gt;
  run make&lt;br /&gt;
  run make install PREFIX=&amp;quot;$DEST&amp;quot; MANDIR=&amp;quot;$DEST/share/man&amp;quot;&lt;br /&gt;
  #run cp -v synaptics_drv.so $DEST/lib/xorg/modules/input/&lt;br /&gt;
) }&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Creating a script which sets env vars&lt;br /&gt;
&lt;br /&gt;
create_xsetenv() {&lt;br /&gt;
  echo &amp;quot;Creating $DEST/bin/xsetenv&amp;quot;&lt;br /&gt;
  cat &amp;lt;&amp;lt;EOF &amp;gt; $DEST/bin/xsetenv || die &amp;quot;Can't create $DEST/bin/xsetenv&amp;quot;&lt;br /&gt;
export PATH=&amp;quot;$DEST/bin:$PATH&amp;quot; &lt;br /&gt;
export LD_LIBRARY_PATH=&amp;quot;$DEST/lib:$LD_LIBRARY_PATH&amp;quot;&lt;br /&gt;
export LIBGL_DRIVERS_PATH=$DEST/lib/dri&lt;br /&gt;
EOF&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Actual fetching and building:&lt;br /&gt;
&lt;br /&gt;
if $FETCH; then&lt;br /&gt;
   fetch_drm&lt;br /&gt;
   fetch_mesa&lt;br /&gt;
   fetch_xorg&lt;br /&gt;
   fetch_xkeyboard_config&lt;br /&gt;
   fetch_synaptics&lt;br /&gt;
fi&lt;br /&gt;
if $BUILD; then&lt;br /&gt;
   build_libdrm&lt;br /&gt;
   build_drm_modules&lt;br /&gt;
   build_xorg&lt;br /&gt;
   build_mesa&lt;br /&gt;
   build_xkeyboard_config&lt;br /&gt;
   build_synaptics&lt;br /&gt;
   create_xsetenv&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
# Saving install and super state to git commits:&lt;br /&gt;
&lt;br /&gt;
if $BUILD; then&lt;br /&gt;
  echo &amp;quot;########### Record installation dir commit ###########&amp;quot;&lt;br /&gt;
  cd $DEST&lt;br /&gt;
  if [ ! -d .git ]; then&lt;br /&gt;
    run git init&lt;br /&gt;
    echo '/var/log' &amp;gt; .gitignore&lt;br /&gt;
    run git add .gitignore&lt;br /&gt;
    run git commit -a -m &amp;quot;initial&amp;quot;&lt;br /&gt;
  fi&lt;br /&gt;
  run git add .&lt;br /&gt;
  if ! nothing_to_commit; then&lt;br /&gt;
    run git commit -a -m &amp;quot;`date +'Installed at %Y-%m-%d %H:%M:%S'`&amp;quot;&lt;br /&gt;
    run git gc&lt;br /&gt;
  fi&lt;br /&gt;
  add_to_supermodule &amp;quot;$DEST_SUBDIR&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
if $SUPERMODULE; then&lt;br /&gt;
  echo &amp;quot;########### Record supermodule commit ###########&amp;quot;&lt;br /&gt;
  cd $PIT&lt;br /&gt;
  nothing_to_commit || run git commit -m &amp;quot;`date +'Snapshot at %Y-%m-%d %H:%M:%S'` `$FETCH &amp;amp;&amp;amp; echo fetch` `$BUILD &amp;amp;&amp;amp; echo build`&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
#############################################&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;Done.&amp;quot;&lt;br /&gt;
! $FETCH || echo &amp;quot;Run '. $DEST/bin/xsetenv' to point env vars to this installation.&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/ibm_acpi-extra-thermal.patch&amp;diff=62550</id>
		<title>Code/ibm acpi-extra-thermal.patch</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/ibm_acpi-extra-thermal.patch&amp;diff=62550"/>
		<updated>2025-04-11T07:27:02Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put patch in &amp;lt;pre&amp;gt; block&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
--- a/drivers/acpi/ibm_acpi.c   2006-03-20 06:53:29.000000000 +0100&lt;br /&gt;
+++ b/drivers/acpi/ibm_acpi.c   2006-07-19 01:55:52.000000000 +0200&lt;br /&gt;
@@ -1229,28 +1229,46 @@ static int thermal_read(char *p)&lt;br /&gt;
 	if (!thermal_tmp_supported)&lt;br /&gt;
 		len += sprintf(p + len, &amp;quot;temperatures:\tnot supported\n&amp;quot;);&lt;br /&gt;
 	else {&lt;br /&gt;
-		int i, t;&lt;br /&gt;
+		int i;&lt;br /&gt;
 		char tmpi[] = &amp;quot;TMPi&amp;quot;;&lt;br /&gt;
-		s8 tmp[8];&lt;br /&gt;
+		/* &lt;br /&gt;
+		 * A few ThinkPads (e.g. R52, T43) have 3 unnamed sensors. We&lt;br /&gt;
+		 * want their values as well.&lt;br /&gt;
+		 */&lt;br /&gt;
+		static const size_t named_count = 8;&lt;br /&gt;
+		static const size_t unnamed_count = 3;&lt;br /&gt;
+		static const size_t unnamed_addresses[] = { 0xC0, 0xC1, 0xC2 };&lt;br /&gt;
+		static const size_t total_count = named_count + unnamed_count;&lt;br /&gt;
+		s8 tmp[total_count];&lt;br /&gt;
 &lt;br /&gt;
 		if (thermal_updt_supported)&lt;br /&gt;
 			if (!acpi_evalf(ec_handle, NULL, &amp;quot;UPDT&amp;quot;, &amp;quot;v&amp;quot;))&lt;br /&gt;
 				return -EIO;&lt;br /&gt;
 &lt;br /&gt;
-		for (i = 0; i &amp;lt; 8; i++) {&lt;br /&gt;
+		for (i = 0; i &amp;lt; named_count; i++) {&lt;br /&gt;
+			int t;&lt;br /&gt;
 			tmpi[3] = '0' + i;&lt;br /&gt;
 			if (!acpi_evalf(ec_handle, &amp;amp;t, tmpi, &amp;quot;d&amp;quot;))&lt;br /&gt;
 				return -EIO;&lt;br /&gt;
-			if (thermal_updt_supported)&lt;br /&gt;
-				tmp[i] = (t - 2732 + 5) / 10;&lt;br /&gt;
-			else&lt;br /&gt;
-				tmp[i] = t;&lt;br /&gt;
+			tmp[i] = (s8)t;&lt;br /&gt;
 		}&lt;br /&gt;
 &lt;br /&gt;
-		len += sprintf(p + len,&lt;br /&gt;
-			       &amp;quot;temperatures:\t%d %d %d %d %d %d %d %d\n&amp;quot;,&lt;br /&gt;
-			       tmp[0], tmp[1], tmp[2], tmp[3],&lt;br /&gt;
-			       tmp[4], tmp[5], tmp[6], tmp[7]);&lt;br /&gt;
+		for (i = 0; i &amp;lt; unnamed_count; ++i) {&lt;br /&gt;
+			size_t address = unnamed_addresses[i];&lt;br /&gt;
+			u8 t;&lt;br /&gt;
+			if (!acpi_ec_read(address, &amp;amp;t))&lt;br /&gt;
+				return -EIO;&lt;br /&gt;
+			tmp[i+named_count] = (s8)t;&lt;br /&gt;
+		}&lt;br /&gt;
+&lt;br /&gt;
+		len += sprintf(p + len, &amp;quot;temperatures:\t&amp;quot; );&lt;br /&gt;
+		for (i = 0; i &amp;lt; total_count; ++i) {&lt;br /&gt;
+			int value = thermal_updt_supported &lt;br /&gt;
+			          ? (tmp[i] - 2732 + 5) / 10&lt;br /&gt;
+			          : tmp[i];&lt;br /&gt;
+			len += sprintf(p + len, &amp;quot;%d%c&amp;quot;, value,&lt;br /&gt;
+			               i == total_count - 1 ? '\n' : ' ');&lt;br /&gt;
+		}&lt;br /&gt;
 	}&lt;br /&gt;
 &lt;br /&gt;
 	return len;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/tp-bat-balance&amp;diff=62549</id>
		<title>Code/tp-bat-balance</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/tp-bat-balance&amp;diff=62549"/>
		<updated>2025-04-11T07:26:38Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put script in &amp;lt;pre&amp;gt; block, so it can be copy-pasted. Finally a good license.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/usr/bin/perl&lt;br /&gt;
# Keep two ThinkPad batteries (system battery and UltraBay) at similar charge levels&lt;br /&gt;
# during discharge by switching back and forth. This reduces wear on the UltraBay&lt;br /&gt;
# battery, compared to the hardware's default strategy of fully draining the UltraBay&lt;br /&gt;
# battery before switching to the system battery.&lt;br /&gt;
# WARNING: This script is experimental and uses undocumented hardware features.&lt;br /&gt;
# WARNING: If this script crashes, your battery may be forced to keep draining until empty.&lt;br /&gt;
# Distributed under the terms of the GNU General Public License v2 or later.&lt;br /&gt;
&lt;br /&gt;
use strict;&lt;br /&gt;
use warnings;&lt;br /&gt;
use File::Slurp;&lt;br /&gt;
&lt;br /&gt;
my $thresh = 3; # difference between battery charge levels that justifies switching (hysteresis)&lt;br /&gt;
&lt;br /&gt;
my $default_discharge = 0; # the battery that's discharged as first priority by the BIOS&lt;br /&gt;
my $smapi_dir = '/sys/devices/platform/smapi';&lt;br /&gt;
&lt;br /&gt;
my $ac_connected;&lt;br /&gt;
my @bat_installed;&lt;br /&gt;
my @bat_remaining;&lt;br /&gt;
my @bat_state;&lt;br /&gt;
my @bat_power_avg;&lt;br /&gt;
my @bat_force_discharge;&lt;br /&gt;
&lt;br /&gt;
$SIG{'INT'} = $SIG{'QUIT'} = $SIG{'TERM'} = sub { die(&amp;quot;# Killed by SIG$_[0]\n&amp;quot;); };&lt;br /&gt;
&lt;br /&gt;
sub read_chomp_file {&lt;br /&gt;
  my ($filename) = @_;&lt;br /&gt;
  my ($x) = read_file($filename) or die &amp;quot;Cannot read $filename\n&amp;quot;;&lt;br /&gt;
  chomp($x);&lt;br /&gt;
  return $x;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Read battery status from tp_smapi sysfs interface&lt;br /&gt;
sub read_status {&lt;br /&gt;
  $ac_connected = read_chomp_file(&amp;quot;$smapi_dir/ac_connected&amp;quot;);&lt;br /&gt;
  for my $b (0..1) {&lt;br /&gt;
    $bat_installed[$b] = read_chomp_file(&amp;quot;$smapi_dir/BAT$b/installed&amp;quot;);&lt;br /&gt;
    $bat_force_discharge[$b] = read_chomp_file(&amp;quot;$smapi_dir/BAT$b/force_discharge&amp;quot;);&lt;br /&gt;
    if ($bat_installed[$b]) {&lt;br /&gt;
      $bat_remaining[$b] = read_chomp_file(&amp;quot;$smapi_dir/BAT$b/remaining_percent&amp;quot;);&lt;br /&gt;
      $bat_state[$b] = read_chomp_file(&amp;quot;$smapi_dir/BAT$b/state&amp;quot;);&lt;br /&gt;
      $bat_power_avg[$b] = read_chomp_file(&amp;quot;$smapi_dir/BAT$b/power_avg&amp;quot;) / 1000.0;&lt;br /&gt;
    }&lt;br /&gt;
    else { $bat_state[$b] = 'none'; }  #This var needs to always have a value for print_bat to not break. This covers the case of starting the program without a battery in the bay/slot.&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Print status to stdout (ASCII graphics)&lt;br /&gt;
sub print_status {&lt;br /&gt;
  print &amp;quot;   &amp;quot;;&lt;br /&gt;
  sub print_bat {&lt;br /&gt;
    my ($b) = @_;&lt;br /&gt;
    my ($ll,$lr,$rl,$rr) = $b ? ('-','&amp;gt;','&amp;lt;','-') : ('&amp;lt;','-','-','&amp;gt;');&lt;br /&gt;
    my $icon = sprintf(&amp;quot;[%3s]&amp;quot;, $bat_installed[$b] ? $bat_remaining[$b].&amp;quot;%&amp;quot; : &amp;quot;&amp;quot;);&lt;br /&gt;
    my $arrow;&lt;br /&gt;
    my $state = $bat_state[$b];&lt;br /&gt;
    if ($state eq 'charging') {&lt;br /&gt;
      $arrow = sprintf(&amp;quot;$ll--%4.1f--$lr&amp;quot;, $bat_power_avg[$b]);&lt;br /&gt;
    } elsif ($state eq 'discharging') {&lt;br /&gt;
      $arrow = sprintf(&amp;quot;$rl--%4.1f--$rr&amp;quot;, -$bat_power_avg[$b]);&lt;br /&gt;
    } elsif ($state eq 'idle' || $state eq 'none') {  #Added none to cover case with no battery in slot when program was started.&lt;br /&gt;
      $arrow = &amp;quot;          &amp;quot;;&lt;br /&gt;
    } else {&lt;br /&gt;
      die &amp;quot;Unknown state $state for battery $b&amp;quot;;&lt;br /&gt;
    }&lt;br /&gt;
    print($b ? &amp;quot;$arrow$icon&amp;quot; : &amp;quot;$icon$arrow&amp;quot;);&lt;br /&gt;
  }&lt;br /&gt;
  print_bat(0);&lt;br /&gt;
  print($ac_connected ? ' {AC} ' : ' {  } ');&lt;br /&gt;
  print_bat(1);&lt;br /&gt;
  print(&amp;quot;\n&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Choose which battery to discharge&lt;br /&gt;
sub choose_discharge {&lt;br /&gt;
  sub set_force_discharge {&lt;br /&gt;
    my ($b,$on) = @_;&lt;br /&gt;
    return if $b!=$default_discharge; # the non-default battery will be discharged only when necessary anyway&lt;br /&gt;
    return if $bat_force_discharge[$b]==$on;&lt;br /&gt;
    write_file(&amp;quot;$smapi_dir/BAT$b/force_discharge&amp;quot;, ($on?'1':'0')) or die (&amp;quot;Cannot write to $smapi_dir/BAT$b/force_discharge: $!\n&amp;quot;);&lt;br /&gt;
    print(&amp;quot;# setting force_discharge on battery $b to $on\n&amp;quot;);&lt;br /&gt;
    $bat_force_discharge[$b] = $on;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  if ($ac_connected || !$bat_installed[0] || !$bat_installed[1]) {&lt;br /&gt;
    for $b (0..1) {&lt;br /&gt;
      set_force_discharge($b,0);&lt;br /&gt;
    }&lt;br /&gt;
  } else {&lt;br /&gt;
    if ($bat_remaining[0] &amp;gt; $bat_remaining[1] + $thresh) {&lt;br /&gt;
      set_force_discharge(0,1);&lt;br /&gt;
      set_force_discharge(1,0);&lt;br /&gt;
    } elsif ($bat_remaining[1] &amp;gt; $bat_remaining[0] + $thresh) {&lt;br /&gt;
      set_force_discharge(0,0);&lt;br /&gt;
      set_force_discharge(1,1);&lt;br /&gt;
    }&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
while (1) {&lt;br /&gt;
  read_status;&lt;br /&gt;
  print_status;&lt;br /&gt;
  choose_discharge;&lt;br /&gt;
  sleep(5);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
END {&lt;br /&gt;
  print(&amp;quot;# Cleanup\n&amp;quot;);&lt;br /&gt;
  write_file(&amp;quot;$smapi_dir/BAT0/force_discharge&amp;quot;, ('0'));&lt;br /&gt;
  write_file(&amp;quot;$smapi_dir/BAT1/force_discharge&amp;quot;, ('0'));&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/undervolt-pentium-m-2.6.13.1.patch&amp;diff=62548</id>
		<title>Code/undervolt-pentium-m-2.6.13.1.patch</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/undervolt-pentium-m-2.6.13.1.patch&amp;diff=62548"/>
		<updated>2025-04-11T07:25:46Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put patch in &amp;lt;pre&amp;gt; block&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
--- linux-2.6.13.1-vanilla/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c	2005-09-10 05:42:58.000000000 +0300&lt;br /&gt;
+++ linux-2.6.13.1/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c	2005-10-18 04:46:01.000000000 +0200&lt;br /&gt;
@@ -54,6 +54,7 @@ enum {&lt;br /&gt;
 	CPU_DOTHAN_A1,&lt;br /&gt;
 	CPU_DOTHAN_A2,&lt;br /&gt;
 	CPU_DOTHAN_B0,&lt;br /&gt;
+	CPU_DOTHAN_C0,&lt;br /&gt;
 	CPU_MP4HT_D0,&lt;br /&gt;
 	CPU_MP4HT_E0,&lt;br /&gt;
 };&lt;br /&gt;
@@ -63,6 +64,8 @@ static const struct cpu_id cpu_ids[] = {&lt;br /&gt;
 	[CPU_DOTHAN_A1]	= { 6, 13, 1 },&lt;br /&gt;
 	[CPU_DOTHAN_A2]	= { 6, 13, 2 },&lt;br /&gt;
 	[CPU_DOTHAN_B0]	= { 6, 13, 6 },&lt;br /&gt;
+	[CPU_DOTHAN_C0]	= { 6, 13, 8 },&lt;br /&gt;
 	[CPU_MP4HT_D0]	= {15,  3, 4 },&lt;br /&gt;
 	[CPU_MP4HT_E0]	= {15,  4, 1 },&lt;br /&gt;
 };&lt;br /&gt;
@@ -94,6 +97,12 @@ static struct cpufreq_driver centrino_dr&lt;br /&gt;
 		.frequency = (mhz) * 1000,				\&lt;br /&gt;
 		.index = (((mhz)/100) &amp;lt;&amp;lt; 8) | ((mv - 700) / 16)		\&lt;br /&gt;
 	}&lt;br /&gt;
+/* Likewise, for processors with 133MHz FSB. */&lt;br /&gt;
+#define OP133(mhz, mv)							\&lt;br /&gt;
+	{								\&lt;br /&gt;
+		.frequency = (mhz) * 1000,				\&lt;br /&gt;
+		.index = (((mhz)/133) &amp;lt;&amp;lt; 8) | ((mv - 700) / 16)		\&lt;br /&gt;
+	}&lt;br /&gt;
 &lt;br /&gt;
 /*&lt;br /&gt;
  * These voltage tables were derived from the Intel Pentium M&lt;br /&gt;
@@ -202,7 +211,26 @@ static struct cpufreq_frequency_table ba&lt;br /&gt;
 	OP(1700, 1484),&lt;br /&gt;
 	{ .frequency = CPUFREQ_TABLE_END }&lt;br /&gt;
 };&lt;br /&gt;
+&lt;br /&gt;
+/* Intel Pentium M 750, drastically undervoltaged */&lt;br /&gt;
+static struct cpufreq_frequency_table pentium_m_750[] =&lt;br /&gt;
+{&lt;br /&gt;
+	    /* MHz   mV */&lt;br /&gt;
+	OP133( 800,  700),&lt;br /&gt;
+	OP133(1066,  780),&lt;br /&gt;
+	OP133(1200,  828),&lt;br /&gt;
+	OP133(1333,  876),&lt;br /&gt;
+	OP133(1466,  924),&lt;br /&gt;
+	OP133(1600,  972),&lt;br /&gt;
+	OP133(1733, 1020),&lt;br /&gt;
+	OP133(1866, 1068),&lt;br /&gt;
+	{ .frequency = CPUFREQ_TABLE_END }&lt;br /&gt;
+};&lt;br /&gt;
+&lt;br /&gt;
 #undef OP&lt;br /&gt;
+#undef OP133&lt;br /&gt;
 &lt;br /&gt;
 #define _BANIAS(cpuid, max, name)	\&lt;br /&gt;
 {	.cpu_id		= cpuid,	\&lt;br /&gt;
@@ -225,6 +253,12 @@ static struct cpu_model models[] =&lt;br /&gt;
 	BANIAS(1500),&lt;br /&gt;
 	BANIAS(1600),&lt;br /&gt;
 	BANIAS(1700),&lt;br /&gt;
+	{&lt;br /&gt;
+		.cpu_id     =  &amp;amp;cpu_ids[CPU_DOTHAN_C0],&lt;br /&gt;
+		.model_name = &amp;quot;Intel(R) Pentium(R) M processor 1.86GHz&amp;quot;,&lt;br /&gt;
+		.max_freq   = 1866000,&lt;br /&gt;
+		.op_points  = pentium_m_750&lt;br /&gt;
+	},&lt;br /&gt;
 &lt;br /&gt;
 	/* NULL model_name is a wildcard */&lt;br /&gt;
 	{ &amp;amp;cpu_ids[CPU_DOTHAN_A1], NULL, 0, NULL },&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/ibm-acpi-0.12a-2.6.14-fan.patch&amp;diff=62547</id>
		<title>Code/ibm-acpi-0.12a-2.6.14-fan.patch</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/ibm-acpi-0.12a-2.6.14-fan.patch&amp;diff=62547"/>
		<updated>2025-04-11T07:25:21Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put patch in &amp;lt;pre&amp;gt; block&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
--- drivers/acpi/ibm_acpi.c.orig        2005-11-01 19:47:44.262270250 +0100&lt;br /&gt;
+++ drivers/acpi/ibm_acpi.c     2005-11-01 20:16:16.081252250 +0100&lt;br /&gt;
@@ -1465,6 +1465,7 @@ static int fan_read(char *p)&lt;br /&gt;
 {&lt;br /&gt;
        int len = 0;&lt;br /&gt;
        int s;&lt;br /&gt;
+       char status_read = 0;&lt;br /&gt;
        u8 lo, hi, status;&lt;br /&gt;
&lt;br /&gt;
        if (gfan_handle) {&lt;br /&gt;
@@ -1477,9 +1478,11 @@ static int fan_read(char *p)&lt;br /&gt;
                /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
                if (!acpi_ec_read(fan_status_offset, &amp;amp;status))&lt;br /&gt;
                        len += sprintf(p + len, &amp;quot;status:\t\tunreadable\n&amp;quot;);&lt;br /&gt;
-               else&lt;br /&gt;
+               else {&lt;br /&gt;
                        len += sprintf(p + len, &amp;quot;status:\t\t%s\n&amp;quot;,&lt;br /&gt;
-                                      enabled(status, 7));&lt;br /&gt;
+                                     status ? &amp;quot;enabled&amp;quot; : &amp;quot;disabled&amp;quot;);&lt;br /&gt;
+                       status_read = 1;&lt;br /&gt;
+               }&lt;br /&gt;
&lt;br /&gt;
                if (!acpi_ec_read(fan_rpm_offset, &amp;amp;lo) ||&lt;br /&gt;
                    !acpi_ec_read(fan_rpm_offset + 1, &amp;amp;hi))&lt;br /&gt;
@@ -1487,6 +1490,14 @@ static int fan_read(char *p)&lt;br /&gt;
                else&lt;br /&gt;
                        len += sprintf(p + len, &amp;quot;speed:\t\t%d\n&amp;quot;,&lt;br /&gt;
                                       (hi &amp;lt;&amp;lt; 8) + lo);&lt;br /&gt;
+               if (status_read) {&lt;br /&gt;
+                       if (status &amp;amp; 0x40)&lt;br /&gt;
+                               len += sprintf(p + len, &amp;quot;level:\t\tdisengaged\n&amp;quot;);&lt;br /&gt;
+                       else if (status &amp;amp; 0x80)&lt;br /&gt;
+                               len += sprintf(p + len, &amp;quot;level:\t\tauto\n&amp;quot;);&lt;br /&gt;
+                       else&lt;br /&gt;
+                               len += sprintf(p + len, &amp;quot;level:\t\t%d\n&amp;quot;, status);&lt;br /&gt;
+               }&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        if (sfan_handle)&lt;br /&gt;
@@ -1495,7 +1506,10 @@ static int fan_read(char *p)&lt;br /&gt;
                               &amp;quot; (&amp;lt;level&amp;gt; is 0-7)\n&amp;quot;);&lt;br /&gt;
        if (!gfan_handle)&lt;br /&gt;
                /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
-               len += sprintf(p + len, &amp;quot;commands:\tenable, disable\n&amp;quot;);&lt;br /&gt;
+               len += sprintf(p + len, &lt;br /&gt;
+                             &amp;quot;commands:\tenable, disable, level &amp;lt;level&amp;gt;\n&amp;quot;&lt;br /&gt;
+                             &amp;quot;         \t(&amp;lt;level&amp;gt; is 0-7, auto &amp;quot;&lt;br /&gt;
+                             &amp;quot;or disengaged)\n&amp;quot;);&lt;br /&gt;
        if (fans_handle)&lt;br /&gt;
                /* X31, X40 */&lt;br /&gt;
                len += sprintf(p + len, &amp;quot;commands:\tspeed &amp;lt;speed&amp;gt;&amp;quot;&lt;br /&gt;
@@ -1516,7 +1530,8 @@ static int fan_write(char *buf)&lt;br /&gt;
                        /* 570, 770x-JL */&lt;br /&gt;
                        if (!acpi_evalf(sfan_handle, NULL, NULL, &amp;quot;vd&amp;quot;, level))&lt;br /&gt;
                                return -EIO;&lt;br /&gt;
-               } else if (!gfan_handle &amp;amp;&amp;amp; strlencmp(cmd, &amp;quot;enable&amp;quot;) == 0) {&lt;br /&gt;
+               } else if (!gfan_handle &amp;amp;&amp;amp; ( (strlencmp(cmd, &amp;quot;enable&amp;quot;) == 0) || &lt;br /&gt;
+                               (strlencmp(cmd, &amp;quot;level auto&amp;quot;) == 0) ) ) {&lt;br /&gt;
                        /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
                        if (!acpi_ec_write(fan_status_offset, 0x80))&lt;br /&gt;
                                return -EIO;&lt;br /&gt;
@@ -1524,6 +1539,17 @@ static int fan_write(char *buf)&lt;br /&gt;
                        /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
                        if (!acpi_ec_write(fan_status_offset, 0x00))&lt;br /&gt;
                                return -EIO;&lt;br /&gt;
+               } else if (!gfan_handle &amp;amp;&amp;amp;&lt;br /&gt;
+                          strlencmp(cmd, &amp;quot;level disengaged&amp;quot;) == 0) {&lt;br /&gt;
+                       /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
+                       if (!acpi_ec_write(fan_status_offset, 0x40))&lt;br /&gt;
+                               return -EIO;&lt;br /&gt;
+               } else if (!gfan_handle &amp;amp;&amp;amp;&lt;br /&gt;
+                   sscanf(cmd, &amp;quot;level %d&amp;quot;, &amp;amp;level) == 1 &amp;amp;&amp;amp;&lt;br /&gt;
+                   level &amp;gt;=0 &amp;amp;&amp;amp; level &amp;lt;= 7) {&lt;br /&gt;
+                       /* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
+                       if (!acpi_ec_write(fan_status_offset, level))&lt;br /&gt;
+                               return -EIO;&lt;br /&gt;
                } else if (fans_handle &amp;amp;&amp;amp;&lt;br /&gt;
                           sscanf(cmd, &amp;quot;speed %d&amp;quot;, &amp;amp;speed) == 1 &amp;amp;&amp;amp;&lt;br /&gt;
                           speed &amp;gt;= 0 &amp;amp;&amp;amp; speed &amp;lt;= 65535) {&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/tp-fancontrol-basic&amp;diff=62546</id>
		<title>Code/tp-fancontrol-basic</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/tp-fancontrol-basic&amp;diff=62546"/>
		<updated>2025-04-11T07:24:42Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put script in &amp;lt;pre&amp;gt; block, so it can be copy-pasted&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
# This script dynamically controls fan speed on some ThinkPad models&lt;br /&gt;
# according to user-defined temperature thresholds.  It implements its&lt;br /&gt;
# own decision algorithm, overriding the ThinkPad embedded&lt;br /&gt;
# controller. It also implements a workaround for the fan noise pulse&lt;br /&gt;
# experienced every few seconds on some ThinkPads.&lt;br /&gt;
#&lt;br /&gt;
# The script requires the ibm_acpi patch at &lt;br /&gt;
# http://thinkwiki.org/wiki/Patch_for_controlling_fan_speed&lt;br /&gt;
#&lt;br /&gt;
# WARNING: This script relies on undocumented hardware features and&lt;br /&gt;
# overrides nominal hardware behavior. It may thus cause arbitrary&lt;br /&gt;
# damage to your laptop or data. Watch your temperatures!&lt;br /&gt;
#&lt;br /&gt;
# This file is placed in the public domain and may be freely distributed.&lt;br /&gt;
&lt;br /&gt;
LEVELS=(    0      2      4      7)  # Fan speed levels&lt;br /&gt;
UP_TEMPS=(      52     60     68  )  # Speed increase trip points&lt;br /&gt;
DOWN_TEMPS=(  48     56     64    )  # Speed decrease trip points&lt;br /&gt;
&lt;br /&gt;
ANTIPULSE=( 0      1      0      0)  # Prevent fan pulsing noise at this level&lt;br /&gt;
                                     #   (this also prevents fan speed updates)&lt;br /&gt;
&lt;br /&gt;
IBM_ACPI=/proc/acpi/ibm&lt;br /&gt;
FAN=$IBM_ACPI/fan&lt;br /&gt;
INTERVAL=3&lt;br /&gt;
VERBOSE=true&lt;br /&gt;
DRY_RUN=false&lt;br /&gt;
&lt;br /&gt;
[[ &amp;quot;$1&amp;quot; == &amp;quot;-t&amp;quot; ]] &amp;amp;&amp;amp; { DRY_RUN=true; echo &amp;quot;$0: Dry run, will not change fan state.&amp;quot;; }&lt;br /&gt;
&lt;br /&gt;
# Enable the fan in default mode if anything goes wrong:&lt;br /&gt;
set -e -E -u&lt;br /&gt;
$DRY_RUN || trap &amp;quot;echo enable &amp;gt; $FAN; exit 0&amp;quot; EXIT HUP INT ABRT QUIT SEGV TERM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
thermometer() { # output list of temperatures&lt;br /&gt;
    read X Y &amp;lt; $IBM_ACPI/thermal&lt;br /&gt;
    [[ &amp;quot;$X&amp;quot; == &amp;quot;temperatures:&amp;quot; ]] || { &lt;br /&gt;
	echo &amp;quot;$0: Bad temperatures: $X $Y&amp;quot; &amp;gt;&amp;amp;2 &lt;br /&gt;
	exit 1&lt;br /&gt;
    }&lt;br /&gt;
    echo &amp;quot;$Y&amp;quot;; &lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
speedometer() { # output fan speed&lt;br /&gt;
    cat $FAN | sed '/^speed/!d; s/speed:[ \t]*//'&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
IDX=0&lt;br /&gt;
MAX_IDX=$(( ${#LEVELS[@]} - 1 ))&lt;br /&gt;
SETTLE=0&lt;br /&gt;
&lt;br /&gt;
while true; do&lt;br /&gt;
    TEMPS=`thermometer`&lt;br /&gt;
    $VERBOSE &amp;amp;&amp;amp; SPEED=`speedometer`&lt;br /&gt;
&lt;br /&gt;
    # Calculate new level&lt;br /&gt;
    NEWIDX=$IDX&lt;br /&gt;
    DOWN=$(( IDX &amp;gt; 0 ))&lt;br /&gt;
    for TEMP in $TEMPS; do&lt;br /&gt;
        # Increase speed as much as needed&lt;br /&gt;
        while [[ $NEWIDX -lt $MAX_IDX ]] &amp;amp;&amp;amp; &lt;br /&gt;
              [[ $TEMP -ge ${UP_TEMPS[$NEWIDX]} ]]; do&lt;br /&gt;
            (( NEWIDX ++ ))&lt;br /&gt;
            DOWN=0&lt;br /&gt;
        done&lt;br /&gt;
        # Allow decrease (by one index)?&lt;br /&gt;
        if [[ $DOWN == 1 ]] &amp;amp;&amp;amp; &lt;br /&gt;
           [[ $TEMP -gt ${DOWN_TEMPS[$(( IDX - 1 ))]} ]]; then&lt;br /&gt;
            DOWN=0&lt;br /&gt;
        fi&lt;br /&gt;
    done&lt;br /&gt;
    if [[ $DOWN == 1 ]]; then&lt;br /&gt;
        NEWIDX=$(( IDX - 1 ))&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
    # Transition&lt;br /&gt;
    OLDLEVEL=${LEVELS[$IDX]}&lt;br /&gt;
    NEWLEVEL=${LEVELS[$NEWIDX]}&lt;br /&gt;
    $VERBOSE &amp;amp;&amp;amp; echo &amp;quot;tpfan: Temps: $TEMPS   Fan: $SPEED   Level: $OLDLEVEL-&amp;gt;$NEWLEVEL&amp;quot;&lt;br /&gt;
    $DRY_RUN || echo level $NEWLEVEL &amp;gt; $FAN&lt;br /&gt;
&lt;br /&gt;
    sleep $INTERVAL&lt;br /&gt;
&lt;br /&gt;
    # If needed, apply anti-pulsing hack after a settle-down period:&lt;br /&gt;
    if [[ ${ANTIPULSE[${NEWIDX}]} == 1 ]]; then&lt;br /&gt;
	if [[ $NEWLEVEL == $OLDLEVEL ]]; then&lt;br /&gt;
	    if [[ $SETTLE -ge 0 ]]; then&lt;br /&gt;
		(( SETTLE -= INTERVAL ))&lt;br /&gt;
	    else&lt;br /&gt;
		$DRY_RUN || echo level disengaged &amp;gt;&amp;gt; $FAN&lt;br /&gt;
		sleep 0.5&lt;br /&gt;
	    fi&lt;br /&gt;
	else&lt;br /&gt;
	    SETTLE=6&lt;br /&gt;
	fi&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
    IDX=$NEWIDX&lt;br /&gt;
done&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/fan-enable-extended&amp;diff=62545</id>
		<title>Code/fan-enable-extended</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/fan-enable-extended&amp;diff=62545"/>
		<updated>2025-04-11T07:23:59Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Script in &amp;lt;pre&amp;gt; block&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
&lt;br /&gt;
# fan control-script&lt;br /&gt;
#&lt;br /&gt;
# based upon ibm-acpi 0.11 (experimental=1 !)&lt;br /&gt;
#&lt;br /&gt;
# eliminates anoying &amp;quot;fan always on&amp;quot; in battery mode&lt;br /&gt;
# works with hysteresis (DELTA) so that always-turn-on/turn-off is avoided&lt;br /&gt;
# fan acivates at MAXTEMP and cools down CPU, GPU etc. to MAXTEMP-DELTA than the fan is turned off&lt;br /&gt;
# furthermore detects if AC is on and gives back fan control to default behaviour than&lt;br /&gt;
#&lt;br /&gt;
# one can change MAXTEMP and DELTA to individual values&lt;br /&gt;
# but take care of your THINKPAD don`t melt it!&lt;br /&gt;
#&lt;br /&gt;
# have fun!&lt;br /&gt;
# mk 05.05.05&lt;br /&gt;
&lt;br /&gt;
MAXTEMP=51&lt;br /&gt;
DELTA=4&lt;br /&gt;
&lt;br /&gt;
SWITCHTEMP=$MAXTEMP&lt;br /&gt;
&lt;br /&gt;
#make sure the script doesn't leave the fan off on error&lt;br /&gt;
trap &amp;quot;echo enable &amp;gt; /proc/acpi/ibm/fan&amp;quot; EXIT&lt;br /&gt;
&lt;br /&gt;
while [ 1 ];&lt;br /&gt;
do&lt;br /&gt;
  for ac in `sed s/state:// &amp;lt; /proc/acpi/ac_adapter/AC/state`&lt;br /&gt;
    do&lt;br /&gt;
     if [ &amp;quot;$ac&amp;quot; = &amp;quot;off-line&amp;quot; ]; then&lt;br /&gt;
         fan=no&lt;br /&gt;
         for temp in `sed s/temperatures:// &amp;lt; /proc/acpi/ibm/thermal`&lt;br /&gt;
           do&lt;br /&gt;
             test $temp -gt $SWITCHTEMP &amp;amp;&amp;amp; fan=yes&lt;br /&gt;
           done&lt;br /&gt;
&lt;br /&gt;
         if [ &amp;quot;$fan&amp;quot; = &amp;quot;yes&amp;quot; ]; then&lt;br /&gt;
           command='enable'&lt;br /&gt;
           SWITCHTEMP=`expr $MAXTEMP - $DELTA`&lt;br /&gt;
         else&lt;br /&gt;
           SWITCHTEMP=$MAXTEMP&lt;br /&gt;
           command='disable'&lt;br /&gt;
         fi&lt;br /&gt;
        else # ac-adapter on -&amp;gt; set fan control to standard behaviour&lt;br /&gt;
         command='enable'&lt;br /&gt;
       fi&lt;br /&gt;
&lt;br /&gt;
       echo $command &amp;gt; /proc/acpi/ibm/fan&lt;br /&gt;
       sleep 15&lt;br /&gt;
     done &lt;br /&gt;
  done&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/fan-enable-basic&amp;diff=62544</id>
		<title>Code/fan-enable-basic</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/fan-enable-basic&amp;diff=62544"/>
		<updated>2025-04-11T07:23:40Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Script in &amp;lt;pre&amp;gt; block&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
&lt;br /&gt;
MAXTEMP=50&lt;br /&gt;
&lt;br /&gt;
while [ 1 ];&lt;br /&gt;
do&lt;br /&gt;
       fan=no&lt;br /&gt;
&lt;br /&gt;
       for temp in `sed s/temperatures:// &amp;lt; /proc/acpi/ibm/thermal`&lt;br /&gt;
       do&lt;br /&gt;
               test $temp -gt $MAXTEMP &amp;amp;&amp;amp; fan=yes&lt;br /&gt;
       done&lt;br /&gt;
&lt;br /&gt;
       command='disable'&lt;br /&gt;
       test &amp;quot;$fan&amp;quot; = &amp;quot;yes&amp;quot; &amp;amp;&amp;amp; command='enable'&lt;br /&gt;
       echo $command &amp;gt; /proc/acpi/ibm/fan&lt;br /&gt;
&lt;br /&gt;
       sleep 20&lt;br /&gt;
done&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/fan-enable-safe&amp;diff=62543</id>
		<title>Code/fan-enable-safe</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/fan-enable-safe&amp;diff=62543"/>
		<updated>2025-04-11T07:23:16Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Script in &amp;lt;pre&amp;gt; block. Why is it proprietary?&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
&lt;br /&gt;
# july 2005 Erik Groeneveld, erik@cq2.nl&lt;br /&gt;
# It makes sure the fan is on in case of errors&lt;br /&gt;
# and only turns it off when all temps are ok.&lt;br /&gt;
&lt;br /&gt;
IBM_ACPI=/proc/acpi/ibm&lt;br /&gt;
THERMOMETER=$IBM_ACPI/thermal&lt;br /&gt;
FAN=$IBM_ACPI/fan&lt;br /&gt;
MAXTRIPPOINT=65&lt;br /&gt;
MINTRIPPOINT=60&lt;br /&gt;
TRIPPOINT=$MINTRIPPOINT&lt;br /&gt;
&lt;br /&gt;
echo fancontrol: Thermometer: $THERMOMETER, Fan: $FAN&lt;br /&gt;
echo fancontrol: Current `cat $THERMOMETER`&lt;br /&gt;
echo fancontrol: Controlling temperatures between $MINTRIPPOINT and $MAXTRIPPOINT degrees.&lt;br /&gt;
&lt;br /&gt;
# Make sure the fan is turned on when the script crashes or is killed&lt;br /&gt;
trap &amp;quot;echo enable &amp;gt; $FAN; exit 0&amp;quot; HUP KILL INT ABRT STOP QUIT SEGV TERM&lt;br /&gt;
&lt;br /&gt;
while [ 1 ];&lt;br /&gt;
do&lt;br /&gt;
       command=enable&lt;br /&gt;
       temperatures=`sed s/temperatures:// &amp;lt; $THERMOMETER`&lt;br /&gt;
       result=&lt;br /&gt;
       for temp in $temperatures&lt;br /&gt;
       do&lt;br /&gt;
               test $temp -le $TRIPPOINT &amp;amp;&amp;amp; result=$result.Ok&lt;br /&gt;
       done&lt;br /&gt;
       if [ &amp;quot;$result&amp;quot; = &amp;quot;.Ok.Ok.Ok.Ok.Ok.Ok.Ok.Ok&amp;quot; ]; then&lt;br /&gt;
               command=disable&lt;br /&gt;
               TRIPPOINT=$MAXTRIPPOINT&lt;br /&gt;
       else&lt;br /&gt;
               command=enable&lt;br /&gt;
               TRIPPOINT=$MINTRIPPOINT&lt;br /&gt;
      fi&lt;br /&gt;
       echo $command &amp;gt; $FAN&lt;br /&gt;
       # Temperature ramps up quickly, so pick this not too large:&lt;br /&gt;
       sleep 5&lt;br /&gt;
done&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/fan-enable.init&amp;diff=62542</id>
		<title>Code/fan-enable.init</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/fan-enable.init&amp;diff=62542"/>
		<updated>2025-04-11T07:21:50Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Script in pre block&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
&lt;br /&gt;
N=/etc/init.d/fan&lt;br /&gt;
&lt;br /&gt;
set -e&lt;br /&gt;
&lt;br /&gt;
case &amp;quot;$1&amp;quot; in&lt;br /&gt;
 start)&lt;br /&gt;
       # make sure privileges don't persist across reboots&lt;br /&gt;
       if [ -d /var/run/fan ] &amp;amp;&amp;amp; [ &amp;quot;x`ls /var/run/fan`&amp;quot; != x ]&lt;br /&gt;
       then&lt;br /&gt;
               touch -t 198501010000 /var/run/fan/*&lt;br /&gt;
       fi&lt;br /&gt;
       fan.sh &amp;amp;    # Script from above&lt;br /&gt;
       ;;&lt;br /&gt;
 stop|reload|restart|force-reload)&lt;br /&gt;
       killall fan.sh&lt;br /&gt;
       echo enable &amp;gt; /proc/acpi/ibm/fan&lt;br /&gt;
       ;;&lt;br /&gt;
 *)&lt;br /&gt;
       echo &amp;quot;Usage: $N {start|stop|restart|force-reload}&amp;quot; &amp;gt;&amp;amp;2&lt;br /&gt;
       exit 1&lt;br /&gt;
       ;;&lt;br /&gt;
esac&lt;br /&gt;
&lt;br /&gt;
exit 0&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/ibm-fancontrol.init&amp;diff=62541</id>
		<title>Code/ibm-fancontrol.init</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/ibm-fancontrol.init&amp;diff=62541"/>
		<updated>2025-04-11T07:21:24Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Everything in a pre block. GPLv2-only? Sad!&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/sbin/runscript&lt;br /&gt;
# 2005 Gilbert Tiefengruber&lt;br /&gt;
# Distributed under the terms of the GNU General Public License v2 &lt;br /&gt;
# IBM Fancontrol init script for IBM Thinkpad laptops (tested with R50)&lt;br /&gt;
# This init script was written for gentoo 2005.1, kernel 2.6.12&lt;br /&gt;
# You need the ibm_acpi kernel module version 0.11 or greater&lt;br /&gt;
# load the module with experimental=1 to enable the fan controls&lt;br /&gt;
&lt;br /&gt;
depend() {&lt;br /&gt;
        need localmount&lt;br /&gt;
}&lt;br /&gt;
checkconfig() {&lt;br /&gt;
        if [ ! -e /proc/acpi/ibm/fan ]; then&lt;br /&gt;
                eerror &amp;quot;The ibm_acpi module must be loaded with (experimental=1)&amp;quot;&lt;br /&gt;
                return 1&lt;br /&gt;
        fi&lt;br /&gt;
} &lt;br /&gt;
start() {&lt;br /&gt;
        checkconfig || return 1&lt;br /&gt;
        ebegin &amp;quot;Starting ibm-fancontrold&amp;quot;&lt;br /&gt;
        start-stop-daemon --quiet -p /var/run/ibm-fancontrold.pid -m -b --start -a /usr/sbin/ibm-fancontrold&lt;br /&gt;
        eend ${?}&lt;br /&gt;
} &lt;br /&gt;
stop() {&lt;br /&gt;
        ebegin &amp;quot;Stopping ibm-fancontrold&amp;quot;&lt;br /&gt;
        start-stop-daemon --stop --quiet -p /var/run/ibm-fancontrold.pid&lt;br /&gt;
        eend ${?}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/ibm-acpi-0.11-2.6.13-fan.patch&amp;diff=62540</id>
		<title>Code/ibm-acpi-0.11-2.6.13-fan.patch</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/ibm-acpi-0.11-2.6.13-fan.patch&amp;diff=62540"/>
		<updated>2025-04-11T07:20:41Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Everything in a pre block so it's readable.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
--- ibm-acpi-0.11-orig/ibm_acpi.c	2005-03-17 12:06:16.000000000 +0200&lt;br /&gt;
+++ ibm-acpi-0.11/ibm_acpi.c	2005-10-26 06:21:57.000000000 +0200&lt;br /&gt;
@@ -1488,11 +1488,18 @@ static int fan_read(char *p)&lt;br /&gt;
 	} else {&lt;br /&gt;
 		/* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
 		if (!acpi_ec_read(fan_status_offset, &amp;amp;status))&lt;br /&gt;
 			len += sprintf(p + len, &amp;quot;status:\t\tunreadable\n&amp;quot;);&lt;br /&gt;
-		else&lt;br /&gt;
+		else {&lt;br /&gt;
 			len += sprintf(p + len, &amp;quot;status:\t\t%s\n&amp;quot;,&lt;br /&gt;
-				       enabled(status, 7));&lt;br /&gt;
+			              status ? &amp;quot;enabled&amp;quot; : &amp;quot;disabled&amp;quot;);&lt;br /&gt;
+			if (status &amp;amp; 0x40)&lt;br /&gt;
+				len += sprintf(p + len, &amp;quot;level:\t\tdisengaged\n&amp;quot;);&lt;br /&gt;
+			else if (status &amp;amp; 0x80)&lt;br /&gt;
+				len += sprintf(p + len, &amp;quot;level:\t\tauto\n&amp;quot;);&lt;br /&gt;
+			else&lt;br /&gt;
+				len += sprintf(p + len, &amp;quot;level:\t\t%d\n&amp;quot;, status);&lt;br /&gt;
+		}&lt;br /&gt;
 &lt;br /&gt;
 		if (!acpi_ec_read(fan_rpm_offset,     &amp;amp;lo) ||&lt;br /&gt;
 		    !acpi_ec_read(fan_rpm_offset + 1, &amp;amp;hi))&lt;br /&gt;
 			len += sprintf(p + len, &amp;quot;speed:\t\tunreadable\n&amp;quot;);&lt;br /&gt;
@@ -1506,9 +1513,12 @@ static int fan_read(char *p)&lt;br /&gt;
 		len += sprintf(p + len, &amp;quot;commands:\tlevel &amp;lt;level&amp;gt;&amp;quot;&lt;br /&gt;
 			       &amp;quot; (&amp;lt;level&amp;gt; is 0-7)\n&amp;quot;);&lt;br /&gt;
 	if (!gfan_handle)&lt;br /&gt;
 		/* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
-		len += sprintf(p + len, &amp;quot;commands:\tenable, disable\n&amp;quot;);&lt;br /&gt;
+		len += sprintf(p + len, &lt;br /&gt;
+		              &amp;quot;commands:\tenable, disable, level &amp;lt;level&amp;gt;\n&amp;quot;&lt;br /&gt;
+		              &amp;quot;         \t(&amp;lt;level&amp;gt; is 0-7, auto&amp;quot;&lt;br /&gt;
+		              &amp;quot;or disengaged)\n&amp;quot;);&lt;br /&gt;
 	if (fans_handle)&lt;br /&gt;
 		/* X31, X40 */&lt;br /&gt;
 		len += sprintf(p + len, &amp;quot;commands:\tspeed &amp;lt;speed&amp;gt;&amp;quot;&lt;br /&gt;
 			       &amp;quot; (&amp;lt;speed&amp;gt; is 0-65535)\n&amp;quot;);&lt;br /&gt;
@@ -1528,17 +1538,29 @@ static int fan_write(char *buf)&lt;br /&gt;
 			/* 570, 770x-JL */&lt;br /&gt;
 			if (!acpi_evalf(sfan_handle, NULL, NULL, &amp;quot;vd&amp;quot;, level))&lt;br /&gt;
 				return -EIO;&lt;br /&gt;
 		} else if (!gfan_handle &amp;amp;&amp;amp;&lt;br /&gt;
-			   strlencmp(cmd, &amp;quot;enable&amp;quot;) == 0) {&lt;br /&gt;
+			   ( (strlencmp(cmd, &amp;quot;enable&amp;quot;) == 0) ||&lt;br /&gt;
+			     (strlencmp(cmd, &amp;quot;level auto&amp;quot;) == 0) ) ) {&lt;br /&gt;
 			/* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
 			if (!acpi_ec_write(fan_status_offset, 0x80))&lt;br /&gt;
 				return -EIO;&lt;br /&gt;
 		} else if (!gfan_handle &amp;amp;&amp;amp;&lt;br /&gt;
 			   strlencmp(cmd, &amp;quot;disable&amp;quot;) == 0) {&lt;br /&gt;
 			/* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
 			if (!acpi_ec_write(fan_status_offset, 0x00))&lt;br /&gt;
 				return -EIO;&lt;br /&gt;
+		} else if (!gfan_handle &amp;amp;&amp;amp;&lt;br /&gt;
+			   strlencmp(cmd, &amp;quot;level disengaged&amp;quot;) == 0) {&lt;br /&gt;
+			/* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
+			if (!acpi_ec_write(fan_status_offset, 0x40))&lt;br /&gt;
+				return -EIO;&lt;br /&gt;
+		} else if (!gfan_handle &amp;amp;&amp;amp;&lt;br /&gt;
+		    sscanf(cmd, &amp;quot;level %d&amp;quot;, &amp;amp;level) == 1 &amp;amp;&amp;amp;&lt;br /&gt;
+		    level &amp;gt;=0 &amp;amp;&amp;amp; level &amp;lt;= 7) {&lt;br /&gt;
+			/* all except 570, 600e/x, 770e, 770x */&lt;br /&gt;
+			if (!acpi_ec_write(fan_status_offset, level))&lt;br /&gt;
+				return -EIO;&lt;br /&gt;
 		} else if (fans_handle &amp;amp;&amp;amp;&lt;br /&gt;
 		    sscanf(cmd, &amp;quot;speed %d&amp;quot;, &amp;amp;speed) == 1 &amp;amp;&amp;amp;&lt;br /&gt;
 		    speed &amp;gt;= 0 &amp;amp;&amp;amp; speed &amp;lt;= 65535) {&lt;br /&gt;
 			/* X31, X40 */&lt;br /&gt;
@@ -1751,9 +1773,9 @@ static int __init setup_notify(struct ib&lt;br /&gt;
 &lt;br /&gt;
 	return 0;&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
-static int device_add(struct acpi_device *device)&lt;br /&gt;
+static int ibmacpi_device_add(struct acpi_device *device)&lt;br /&gt;
 {&lt;br /&gt;
 	return 0;&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
@@ -1769,9 +1791,9 @@ static int __init register_driver(struct&lt;br /&gt;
 &lt;br /&gt;
 	memset(ibm-&amp;gt;driver, 0, sizeof(struct acpi_driver));&lt;br /&gt;
 	sprintf(ibm-&amp;gt;driver-&amp;gt;name, &amp;quot;%s/%s&amp;quot;, IBM_NAME, ibm-&amp;gt;name);&lt;br /&gt;
 	ibm-&amp;gt;driver-&amp;gt;ids = ibm-&amp;gt;hid;&lt;br /&gt;
-	ibm-&amp;gt;driver-&amp;gt;ops.add = &amp;amp;device_add;&lt;br /&gt;
+	ibm-&amp;gt;driver-&amp;gt;ops.add = &amp;amp;ibmacpi_device_add;&lt;br /&gt;
 &lt;br /&gt;
 	ret = acpi_bus_register_driver(ibm-&amp;gt;driver);&lt;br /&gt;
 	if (ret &amp;lt; 0) {&lt;br /&gt;
 		printk(IBM_ERR &amp;quot;acpi_bus_register_driver(%s) failed: %d\n&amp;quot;,&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Code/tp-theft-basic&amp;diff=62539</id>
		<title>Code/tp-theft-basic</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Code/tp-theft-basic&amp;diff=62539"/>
		<updated>2025-04-11T07:19:28Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Put everything in a pre block, so that script is readable.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/usr/bin/perl&lt;br /&gt;
# tp-theft v0.1 (http://thinkwiki.org/wiki/Script_for_theft_alarm_using_HDAPS)&lt;br /&gt;
# This script uses the HDAPS accelerometer found on recent ThinkPad models&lt;br /&gt;
# to emit an audio alarm when the laptop is tilted. In sufficiently&lt;br /&gt;
# populated environments, it can be used as a laptop theft deterrent.&lt;br /&gt;
#&lt;br /&gt;
# This file is placed in the public domain and may be freely distributed.&lt;br /&gt;
&lt;br /&gt;
use strict;&lt;br /&gt;
use warnings;&lt;br /&gt;
&lt;br /&gt;
##############################&lt;br /&gt;
# Siren volume and content&lt;br /&gt;
&lt;br /&gt;
# Audio volume (0..100)&lt;br /&gt;
my $volume = 70;&lt;br /&gt;
&lt;br /&gt;
# Synthesize a siren for 1.0 seconds:&lt;br /&gt;
my $play_cmd = &amp;quot;sox -t nul /dev/null -t ossdsp /dev/dsp synth 1.0 sine 2000-4000 sine 4000-2000&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Play a file:&lt;br /&gt;
# my $play_cmd = &amp;quot;play keep_your_hands_off_me.wav&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
##############################&lt;br /&gt;
# Other tweakables&lt;br /&gt;
&lt;br /&gt;
my $thresh = 0.20;   # tilt threshold (increase value to decrease sensitivity)&lt;br /&gt;
my $interval = 0.1;  # sampling interval in seconds&lt;br /&gt;
my $depth = 10;      # number of recent samples to analyze&lt;br /&gt;
my $pos_file='/sys/devices/platform/hdaps/position';&lt;br /&gt;
my $verbose = 1;&lt;br /&gt;
&lt;br /&gt;
##############################&lt;br /&gt;
# Code&lt;br /&gt;
&lt;br /&gt;
sub get_pos {&lt;br /&gt;
    open(POS,&amp;quot;&amp;lt;&amp;quot;,$pos_file) or die &amp;quot;Can't open HDAPS file $pos_file: $!\n&amp;quot;;&lt;br /&gt;
    $_=&amp;lt;POS&amp;gt;;&lt;br /&gt;
    m/^\((-?\d+),(-?\d+)\)$/ or die &amp;quot;Can't parse $pos_file content\n&amp;quot;;&lt;br /&gt;
    return ($1,$2);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
sub stddev {&lt;br /&gt;
    my $sum=0;&lt;br /&gt;
    my $sumsq=0;&lt;br /&gt;
    my $n=$#_+1;&lt;br /&gt;
    for my $v (@_) {&lt;br /&gt;
	$sum += $v;&lt;br /&gt;
	$sumsq += $v*$v;&lt;br /&gt;
    }&lt;br /&gt;
    return sqrt($n*$sumsq - $sum*$sum)/($n*($n-1));&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
my (@XHIST, @YHIST);&lt;br /&gt;
my ($x,$y) = get_pos;&lt;br /&gt;
for (1..$depth) {&lt;br /&gt;
    push(@XHIST,$x);&lt;br /&gt;
    push(@YHIST,$y);&lt;br /&gt;
}&lt;br /&gt;
my $alarm_file; # flags ongoing alarm (and stores saved mixer settings)&lt;br /&gt;
&lt;br /&gt;
while (1) {&lt;br /&gt;
    my ($x,$y) = get_pos;&lt;br /&gt;
    shift(@XHIST); push(@XHIST,$x);&lt;br /&gt;
    shift(@YHIST); push(@YHIST,$y);&lt;br /&gt;
    my $xdev = stddev(@XHIST);&lt;br /&gt;
    my $ydev = stddev(@YHIST);&lt;br /&gt;
&lt;br /&gt;
    # Print variance and history&lt;br /&gt;
    print &amp;quot;X: v=$xdev (&amp;quot;.join(',',@XHIST).&amp;quot;)  Y: v=$ydev (&amp;quot;.join(&amp;quot;,&amp;quot;,@YHIST).&amp;quot;)\n&amp;quot; if $verbose&amp;gt;1;&lt;br /&gt;
&lt;br /&gt;
    my $tilted = $xdev&amp;gt;$thresh || $ydev&amp;gt;$thresh;&lt;br /&gt;
&lt;br /&gt;
    if ($tilted &amp;amp;&amp;amp; !(defined($alarm_file) &amp;amp;&amp;amp; -f $alarm_file)) {&lt;br /&gt;
	print &amp;quot;ALARM\n&amp;quot; if $verbose&amp;gt;0;&lt;br /&gt;
	$alarm_file = `mktemp /tmp/hdaps-tilt.XXXXXXXX` or die &amp;quot;mktemp: $?&amp;quot;;&lt;br /&gt;
	chomp($alarm_file);&lt;br /&gt;
	system('/bin/bash', '-c', &amp;lt;&amp;lt;&amp;quot;EOF&amp;quot;)==0 or die &amp;quot;Failed: $?&amp;quot;;&lt;br /&gt;
( trap \&amp;quot;aumix -L -f $alarm_file &amp;gt; /dev/null; rm -f $alarm_file&amp;quot; EXIT HUP QUIT TERM&lt;br /&gt;
  aumix -S -f $alarm_file &amp;amp;&amp;amp;&lt;br /&gt;
  aumix -v $volume -w 100 &amp;amp;&amp;amp;&lt;br /&gt;
  $play_cmd) &amp;amp;&lt;br /&gt;
EOF&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    select(undef, undef, undef, $interval); # sleep&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Lenovo_Security_Suite&amp;diff=62538</id>
		<title>Lenovo Security Suite</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Lenovo_Security_Suite&amp;diff=62538"/>
		<updated>2025-04-11T07:15:30Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: It appears there was never a screenshot available, so remove that section.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Description==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Software Requirements===&lt;br /&gt;
&lt;br /&gt;
* Windows 7 - 32 and 64 bits&lt;br /&gt;
&lt;br /&gt;
===Hardware Requirements===&lt;br /&gt;
&lt;br /&gt;
==Download==&lt;br /&gt;
* Windows 7 - Version 2.0.13.0 [http://support.lenovo.com/ec/en/downloads/ds018434]&lt;br /&gt;
&lt;br /&gt;
[[Category:Software]]&lt;br /&gt;
[[Category:Windows 7 Lenovo Software]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=Installing_openSuSE_10.3_on_a_ThinkPad_X61&amp;diff=62537</id>
		<title>Installing openSuSE 10.3 on a ThinkPad X61</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=Installing_openSuSE_10.3_on_a_ThinkPad_X61&amp;diff=62537"/>
		<updated>2025-04-11T07:11:56Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: Linux is not an OS like windows, it is a kernel.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This article describes installation of openSUSE 10.3 on a ThinkPad X61 performed in February 2008.&lt;br /&gt;
&lt;br /&gt;
(This is english translation of a [http://www.abclinuxu.cz/blog/linux/2008/3/lenovo-thinkpad-x61-3-instalace-opensuse-10.3 czech blogpost] originally published on [http://www.abclinuxu.cz Abclinuxu.cz])&lt;br /&gt;
== Hardware configuration ==&lt;br /&gt;
* Lenovo ThinkPad {{X61}} [http://www-307.ibm.com/pc/support/site.wss/product.do?template=/product.do?template=%2Fproductpage%2Flandingpages%2FproductPageLandingPage.vm&amp;amp;sitestyle=lenovo&amp;amp;brandind=10&amp;amp;familyind=374625&amp;amp;machineind=374632&amp;amp;modelind=375122&amp;amp;partnumberind=0&amp;amp;subcategoryind=0&amp;amp;doctypeind=100&amp;amp;doccategoryind=0&amp;amp;operatingsystemind=49979&amp;amp;validate=true 7675-7KU]&lt;br /&gt;
* Intel [[Intel_Core_2_Duo_(Merom)|Core 2 Duo]] T7300 2.0GHz CPU&lt;br /&gt;
* 4 GiB DDR2 667 MHz RAM&lt;br /&gt;
* 12.1&amp;quot; 1024x768 TN LCD&lt;br /&gt;
* Intel [http://en.wikipedia.org/wiki/Intel_GMA#GMA_X3100 GMA X3100] graphics&lt;br /&gt;
* Hitachi 120 GB 5400 RPM SATA HDD&lt;br /&gt;
* [[AD1984|AD1984 HD Audio 1.0]] aka Intel HD Audio integrated soundcard&lt;br /&gt;
* Intel [http://www.intel.com/design/network/products/lan/controllers/82566.htm 82566 Gigabit Ethernet] (Intel PRO/1000)&lt;br /&gt;
* Intel [[Intel_PRO/Wireless_4965AGN_Mini-PCI_Express_Adapter|Wireless WiFi Link 4965AGN]]&lt;br /&gt;
* [[ThinkPad_Bluetooth_with_Enhanced_Data_Rate_(BDC-2)|Bluetooth 2.0 EDR]]&lt;br /&gt;
* SGS Thomson [[Integrated_Fingerprint_Reader|fingerprint reader]]&lt;br /&gt;
* 8-cell 5.2 Ah Li-Ion battery&lt;br /&gt;
* [[UltraBase X6]] docking station with a DVD-RAM/R/RW drive&lt;br /&gt;
&lt;br /&gt;
{{cmdroot|lspci}}&lt;br /&gt;
&amp;lt;pre&amp;gt;00:00.0 Host bridge: Intel Corporation Mobile PM965/GM965/GL960 Memory Controller Hub (rev 0c)&lt;br /&gt;
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)&lt;br /&gt;
00:02.1 Display controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)&lt;br /&gt;
00:19.0 Ethernet controller: Intel Corporation 82566MM Gigabit Network Connection (rev 03)&lt;br /&gt;
00:1a.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Contoller #4 (rev 03)&lt;br /&gt;
00:1a.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #5 (rev 03)&lt;br /&gt;
00:1a.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #2 (rev 03)&lt;br /&gt;
00:1b.0 Audio device: Intel Corporation 82801H (ICH8 Family) HD Audio Controller (rev 03)&lt;br /&gt;
00:1c.0 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 1 (rev 03)&lt;br /&gt;
00:1c.1 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 2 (rev 03)&lt;br /&gt;
00:1d.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #1 (rev 03)&lt;br /&gt;
00:1d.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #2 (rev 03)&lt;br /&gt;
00:1d.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #1 (rev 03)&lt;br /&gt;
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f3)&lt;br /&gt;
00:1f.0 ISA bridge: Intel Corporation 82801HBM (ICH8M-E) LPC Interface Controller (rev 03)&lt;br /&gt;
00:1f.1 IDE interface: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) IDE Controller (rev 03)&lt;br /&gt;
00:1f.2 SATA controller: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) SATA AHCI Controller (rev 03)&lt;br /&gt;
00:1f.3 SMBus: Intel Corporation 82801H (ICH8 Family) SMBus Controller (rev 03)&lt;br /&gt;
02:00.0 Memory controller: Intel Corporation Turbo Memory Controller (rev 01)&lt;br /&gt;
03:00.0 Network controller: Intel Corporation PRO/Wireless 4965 AG or AGN Network Connection (rev 61)&lt;br /&gt;
05:00.0 CardBus bridge: Ricoh Co Ltd RL5c476 II (rev ba)&lt;br /&gt;
05:00.1 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 04)&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{cmdroot|hwinfo --short}}&lt;br /&gt;
&amp;lt;pre&amp;gt;cpu:&lt;br /&gt;
                       Intel(R) Core(TM)2 Duo CPU     T7300  @ 2.00GHz, 2000 MHz&lt;br /&gt;
                       Intel(R) Core(TM)2 Duo CPU     T7300  @ 2.00GHz, 2000 MHz&lt;br /&gt;
keyboard:&lt;br /&gt;
  /dev/input/event0    AT Translated Set 2 keyboard&lt;br /&gt;
mouse:&lt;br /&gt;
  /dev/input/mice      TPPS/2 IBM TrackPoint&lt;br /&gt;
monitor:&lt;br /&gt;
                       Generic Monitor&lt;br /&gt;
graphics card:&lt;br /&gt;
                       Lenovo 965 GM&lt;br /&gt;
                       Lenovo Mobile GM965/GL960 Integrated Graphics Controller&lt;br /&gt;
sound:&lt;br /&gt;
                       Lenovo Thinkpad T61&lt;br /&gt;
storage:&lt;br /&gt;
                       Lenovo 82801HBM/HEM (ICH8M/ICH8M-E) IDE Controller&lt;br /&gt;
                       Lenovo 82801HBM/HEM (ICH8M/ICH8M-E) SATA AHCI Controller&lt;br /&gt;
network:&lt;br /&gt;
  eth0                 Lenovo 82566MM Gigabit Network Connection&lt;br /&gt;
  wlan0                Intel Lenovo Thinkpad T61&lt;br /&gt;
network interface:&lt;br /&gt;
  lo                   Loopback network interface&lt;br /&gt;
  eth0                 Ethernet network interface&lt;br /&gt;
  wmaster0             Network Interface&lt;br /&gt;
  wlan0                WLAN network interface&lt;br /&gt;
disk:&lt;br /&gt;
  /dev/sda             SAMSUNG HM250JI (the original Toshiba has been replaced)&lt;br /&gt;
partition:&lt;br /&gt;
  /dev/sda1            Partition&lt;br /&gt;
  /dev/sda2            Partition&lt;br /&gt;
  /dev/sda3            Partition&lt;br /&gt;
cdrom:&lt;br /&gt;
  /dev/sr0             HL-DT-ST DVDRAM GSA-U10N&lt;br /&gt;
usb controller:&lt;br /&gt;
                       Lenovo Thinkpad T61&lt;br /&gt;
                       Lenovo Thinkpad T60&lt;br /&gt;
                       Lenovo Thinkpad T61&lt;br /&gt;
                       Lenovo 82801H (ICH8 Family) USB UHCI Controller #1&lt;br /&gt;
                       Lenovo 82801H (ICH8 Family) USB UHCI Controller #2&lt;br /&gt;
                       Lenovo 82801H (ICH8 Family) USB2 EHCI Controller #1&lt;br /&gt;
bios:&lt;br /&gt;
                       BIOS&lt;br /&gt;
bridge:&lt;br /&gt;
                       Lenovo Mobile PM965/GM965/GL960 Memory Controller Hub&lt;br /&gt;
                       Intel 82801H (ICH8 Family) PCI Express Port 1&lt;br /&gt;
                       Intel 82801H (ICH8 Family) PCI Express Port 2&lt;br /&gt;
                       Intel 82801 Mobile PCI Bridge&lt;br /&gt;
                       Lenovo 82801HBM (ICH8M-E) LPC Interface Controller&lt;br /&gt;
                       Lenovo RL5c476 II&lt;br /&gt;
hub:&lt;br /&gt;
                       Linux 2.6.22.17-0.1-default uhci_hcd UHCI Host Controller&lt;br /&gt;
                       Linux 2.6.22.17-0.1-default uhci_hcd UHCI Host Controller&lt;br /&gt;
                       Linux 2.6.22.17-0.1-default ehci_hcd EHCI Host Controller&lt;br /&gt;
                       Linux 2.6.22.17-0.1-default ehci_hcd EHCI Host Controller&lt;br /&gt;
                       Linux 2.6.22.17-0.1-default uhci_hcd UHCI Host Controller&lt;br /&gt;
                       Linux 2.6.22.17-0.1-default uhci_hcd UHCI Host Controller&lt;br /&gt;
memory:&lt;br /&gt;
                       Main Memory&lt;br /&gt;
firewire controller:&lt;br /&gt;
                       Lenovo R5C832 IEEE 1394 Controller&lt;br /&gt;
bluetooth:&lt;br /&gt;
                       Broadcom BCM2045B&lt;br /&gt;
unknown:&lt;br /&gt;
                       FPU&lt;br /&gt;
                       DMA controller&lt;br /&gt;
                       PIC&lt;br /&gt;
                       Timer&lt;br /&gt;
                       RTC&lt;br /&gt;
                       Keyboard controller&lt;br /&gt;
                       PS/2 Controller&lt;br /&gt;
                       Lenovo 82801H (ICH8 Family) SMBus Controller&lt;br /&gt;
                       Intel Turbo Memory Controller&lt;br /&gt;
                       Lenovo R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{cmdroot|cat /proc/cpuinfo}}&lt;br /&gt;
&amp;lt;pre&amp;gt;processor       : 0 [the second core says '1']&lt;br /&gt;
vendor_id       : GenuineIntel&lt;br /&gt;
cpu family      : 6&lt;br /&gt;
model           : 15&lt;br /&gt;
model name      : Intel(R) Core(TM)2 Duo CPU     T7300  @ 2.00GHz&lt;br /&gt;
stepping        : 10&lt;br /&gt;
cpu MHz         : 2001.000&lt;br /&gt;
cache size      : 4096 KB&lt;br /&gt;
physical id     : 0&lt;br /&gt;
siblings        : 2&lt;br /&gt;
core id         : 0&lt;br /&gt;
cpu cores       : 2&lt;br /&gt;
fpu             : yes&lt;br /&gt;
fpu_exception   : yes&lt;br /&gt;
cpuid level     : 10&lt;br /&gt;
wp              : yes&lt;br /&gt;
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov&lt;br /&gt;
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm syscall nx lm constant_tsc&lt;br /&gt;
 pni monitor ds_cpl vmx est tm2 ssse3 cx16 xtpr lahf_lm&lt;br /&gt;
bogomips        : 3994.33&lt;br /&gt;
clflush size    : 64&lt;br /&gt;
cache_alignment : 64&lt;br /&gt;
address sizes   : 36 bits physical, 48 bits virtual&lt;br /&gt;
power management:&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== {{OpenSUSE}}: What does and what doesn't work ==&lt;br /&gt;
The following list is applicable to a openSUSE-patched kernel 2.6.22.17-0.1.&lt;br /&gt;
=== Working HW ===&lt;br /&gt;
* (+) CPU frequency changing&lt;br /&gt;
* (+) graphical interface (X.org) including brightness setting&lt;br /&gt;
* (-) save to RAM (needs small fix to get working) and save to disk (works)&lt;br /&gt;
* (-) docking station&lt;br /&gt;
* (+) DVD burner in the UltraBay slot (hotplug not tested)&lt;br /&gt;
* (+) USB 2.0&lt;br /&gt;
* (+) wired Ethernet&lt;br /&gt;
* (+) wireless Ethernet, with some minor problems&lt;br /&gt;
* (+) sound (hda_intel) -- modem needs to be enabled in BIOS&lt;br /&gt;
* (-) Fn keyboard shortcuts&lt;br /&gt;
* (+) Bluetooth (including indication LED)&lt;br /&gt;
* (+) TrackPoint&lt;br /&gt;
* (+) Firewire&lt;br /&gt;
* (+) Cardbus slot&lt;br /&gt;
* (+) fingerprint reader (with ThinkFinger, KDM &amp;amp; KScreensaver is unusable)&lt;br /&gt;
* (+) SD card reader&lt;br /&gt;
* (+) serial and parallel port on the docking station&lt;br /&gt;
* (+) wireless killswitch&lt;br /&gt;
* (-) other power management functions&lt;br /&gt;
&lt;br /&gt;
=== Not working/not tested HW ===&lt;br /&gt;
* (N/T) winmodem ([http://gentoo-wiki.com/HOWTO_slmodem should work with slmodem driver])&lt;br /&gt;
* (N/T, don't have) WWAN modem (GrmlWiki says [http://wiki.grml.org/doku.php?id=lenovo_x61s#wan at least one version is supported])&lt;br /&gt;
* (N/W) [[HDAPS|Lenovo Harddrive Active Protection System]] (missing support in the openSUSE kernel)&lt;br /&gt;
* (N/T, don't have) [http://en.wikipedia.org/wiki/Turbo_Memory Intel Turbo Memory] (the driver doesn't exist; maybe it works as a drive cache =&amp;gt; no driver needed)&lt;br /&gt;
* (N/T) [http://en.wikipedia.org/wiki/Trusted_Platform_Module Trusted Platform Module] (supported by the [[Tpmdd|Linux TPM Driver]], in kernel since version 2.6.10)&lt;br /&gt;
{{HINT|(+) sign means that the HW works right out of the box, (-) that the HW needs some (mostly simple) configuration, was not tested (N/T) or doesn't work at all (N/W).}}&lt;br /&gt;
== X.Org configuration ==&lt;br /&gt;
The following configuration reflects Clone setting with Samsung 245B, a low-end WUXGA (1920x1200) TN LCD using &amp;lt;code&amp;gt;intel&amp;lt;/code&amp;gt; driver from X.org connected via VGA. If you're not planning to use external display, you can use the default &amp;lt;code&amp;gt;xorg.conf&amp;lt;/code&amp;gt; generated by SaX during installation, it just works (TM) ;-)&lt;br /&gt;
&lt;br /&gt;
{{path|/etc/X11/xorg.conf}} (display settings part)&lt;br /&gt;
&amp;lt;pre&amp;gt;Section &amp;quot;Monitor&amp;quot;&lt;br /&gt;
  DisplaySize  518 323&lt;br /&gt;
  HorizSync    30-81&lt;br /&gt;
  Identifier   &amp;quot;ExternalLCD&amp;quot;&lt;br /&gt;
  ModelName    &amp;quot;SyncMaster 245B&amp;quot;&lt;br /&gt;
  Option       &amp;quot;DPMS&amp;quot;&lt;br /&gt;
  VendorName   &amp;quot;Samsung&amp;quot;&lt;br /&gt;
  VertRefresh  60-75&lt;br /&gt;
  Modeline     &amp;quot;1920x1200&amp;quot; 154.00 1920 1968 2000 2080 1200 1203 1209 1235&lt;br /&gt;
  Option       &amp;quot;DPI&amp;quot; &amp;quot;96x96&amp;quot;&lt;br /&gt;
EndSection&lt;br /&gt;
&lt;br /&gt;
Section &amp;quot;Monitor&amp;quot;&lt;br /&gt;
  DisplaySize   245 184&lt;br /&gt;
  HorizSync     30-81&lt;br /&gt;
  Identifier    &amp;quot;InternalLCD&amp;quot;&lt;br /&gt;
  ModelName     &amp;quot;ThinkPad LCD 1024x768&amp;quot;&lt;br /&gt;
  Option        &amp;quot;DPMS&amp;quot;&lt;br /&gt;
  VendorName    &amp;quot;Lenovo&amp;quot;&lt;br /&gt;
  VertRefresh   60-75&lt;br /&gt;
  Modeline      &amp;quot;1024x768&amp;quot; 69.71 1024 1080 1184 1344 768 769 772 798&lt;br /&gt;
  Modeline      &amp;quot;800x600&amp;quot; 48.91 800 840 920 1040 600 601 604 627&lt;br /&gt;
  Modeline      &amp;quot;640x480&amp;quot; 24.70 640 656 720 800 480 481 484 498&lt;br /&gt;
EndSection&lt;br /&gt;
&lt;br /&gt;
Section &amp;quot;Screen&amp;quot;&lt;br /&gt;
  DefaultDepth 24&lt;br /&gt;
  SubSection &amp;quot;Display&amp;quot;&lt;br /&gt;
    ViewPort   0 0&lt;br /&gt;
    Depth      16&lt;br /&gt;
    Modes      &amp;quot;1024x768&amp;quot; &amp;quot;800x600&amp;quot; &amp;quot;640x480&amp;quot;&lt;br /&gt;
  EndSubSection&lt;br /&gt;
  SubSection &amp;quot;Display&amp;quot;&lt;br /&gt;
    ViewPort   0 0&lt;br /&gt;
    Depth      24&lt;br /&gt;
    Modes      &amp;quot;1024x768&amp;quot; &amp;quot;800x600&amp;quot; &amp;quot;640x480&amp;quot;&lt;br /&gt;
  EndSubSection&lt;br /&gt;
  Device       &amp;quot;Device0&amp;quot;&lt;br /&gt;
  Identifier   &amp;quot;InternalScreen&amp;quot;&lt;br /&gt;
  Monitor      &amp;quot;InternalLCD&amp;quot;&lt;br /&gt;
EndSection&lt;br /&gt;
&lt;br /&gt;
Section &amp;quot;Screen&amp;quot;&lt;br /&gt;
  DefaultDepth 24&lt;br /&gt;
  SubSection &amp;quot;Display&amp;quot;&lt;br /&gt;
    ViewPort   0 0&lt;br /&gt;
    Depth      16&lt;br /&gt;
    Modes      &amp;quot;1920x1200&amp;quot; &amp;quot;1024x768&amp;quot; &amp;quot;800x600&amp;quot; &amp;quot;640x480&amp;quot;&lt;br /&gt;
  EndSubSection&lt;br /&gt;
  SubSection &amp;quot;Display&amp;quot;&lt;br /&gt;
    ViewPort   0 0&lt;br /&gt;
    Depth      24&lt;br /&gt;
    Modes      &amp;quot;1920x1200&amp;quot; &amp;quot;1024x768&amp;quot; &amp;quot;800x600&amp;quot; &amp;quot;640x480&amp;quot;&lt;br /&gt;
  EndSubSection&lt;br /&gt;
  Device       &amp;quot;Device1&amp;quot;&lt;br /&gt;
  Identifier   &amp;quot;ExternalScreen&amp;quot;&lt;br /&gt;
  Monitor      &amp;quot;ExternalLCD&amp;quot;&lt;br /&gt;
EndSection&amp;lt;/pre&amp;gt;&lt;br /&gt;
This screen configuration requires two graphic adapters. One physical and the second virtual. Configuration excerpt follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;Section &amp;quot;Device&amp;quot;&lt;br /&gt;
  BoardName    &amp;quot;X3100&amp;quot;&lt;br /&gt;
  Driver       &amp;quot;intel&amp;quot;&lt;br /&gt;
  Identifier   &amp;quot;Device0&amp;quot;&lt;br /&gt;
  Screen        0&lt;br /&gt;
  Option        &amp;quot;MonitorLayout&amp;quot; &amp;quot;CRT,LFP&amp;quot;&lt;br /&gt;
  Option        &amp;quot;MetaModes&amp;quot;     &amp;quot;1920x1200,1024x768&amp;quot;&lt;br /&gt;
  VendorName   &amp;quot;Intel&amp;quot;&lt;br /&gt;
  Option        &amp;quot;FramebufferCompression&amp;quot; &amp;quot;on&amp;quot;&lt;br /&gt;
  #Option       &amp;quot;AccelMethod&amp;quot;   &amp;quot;exa&amp;quot;&lt;br /&gt;
EndSection&lt;br /&gt;
&lt;br /&gt;
Section &amp;quot;Device&amp;quot;&lt;br /&gt;
  BoardName    &amp;quot;X3100&amp;quot;&lt;br /&gt;
  Driver       &amp;quot;intel&amp;quot;&lt;br /&gt;
  Identifier   &amp;quot;Device1&amp;quot;&lt;br /&gt;
  Screen        1&lt;br /&gt;
  Option        &amp;quot;MonitorLayout&amp;quot; &amp;quot;CRT,LFP&amp;quot;&lt;br /&gt;
  VendorName   &amp;quot;Intel&amp;quot;&lt;br /&gt;
EndSection&amp;lt;/pre&amp;gt;&lt;br /&gt;
You can also download the whole [http://akela.mendelu.cz/~xgrmela1/recenze-x61/files/xorg.conf xorg.conf]. Setting X.org with this configuration causes some problem to Mplayer, you need to add &amp;lt;code&amp;gt;xineramascreen=0&amp;lt;/code&amp;gt; to your Mplayer config. The other problem is that my KDE seems no to accept screen size reported by the second LCD. Therefore, the DPI is set too low and fonts are '''huge'''. This could be solved (at least in KDE) by setting force 96x96 DPI in KDE Control center (Fonts setttings).&lt;br /&gt;
&lt;br /&gt;
{{NOTE|The 3D output using this configuration is pretty slow, for example the Tuxracer is hardly playable. When the external display is disconnected, it runs perfectly}}&lt;br /&gt;
&lt;br /&gt;
=== Screen brightness &amp;amp; flickering problem ===&lt;br /&gt;
You maybe heard about the brightness problem on recent Lenovo machines. The problems are mainly cause by a different count of supported brightness levels what causes the screen to be too dark. This is solved in recent &amp;lt;code&amp;gt;thinkpad_acpi&amp;lt;/code&amp;gt; kernel module, the openSUSE kernel includes this fix. The other problem is a [[Problem_with_display_remaining_black_after_resume|blank screen after resume from suspend to RAM]], however this could be fixed easily by changing &amp;lt;code&amp;gt;s2ram&amp;lt;/code&amp;gt; configuration.&lt;br /&gt;
&lt;br /&gt;
Some users report screen flickering when changing brightness. This is caused by the way X.org changes brightness level, on a recent X, you should be able to solve this by calling {{cmduser|xrandr --output LVDS --set BACKLIGHT_CONTROL native}}.&lt;br /&gt;
{{NOTE|OpenSUSE 10.3 uses probably too old X.Org for this command to work, exits &amp;lt;code&amp;gt;X Error of failed request: BadName (named color or font does not exist)&amp;lt;/code&amp;gt;}}.&lt;br /&gt;
&lt;br /&gt;
The older BIOSes had a bug which not only affected Windows but GNU/Linux too. The laptop had, when resumed from suspend to ram, turned the backlight at maximum. Installing [http://www-307.ibm.com/pc/support/site.wss/document.do?lndocid=MIGR-67983 newer BIOSes] from Lenovo's site solves this. The newer BIOSes also solve weird USB interrupt bug which looks in &amp;lt;code&amp;gt;dmesg&amp;lt;/code&amp;gt; like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;irq 21: nobody cared (try booting with the &amp;quot;irqpoll&amp;quot; option)&lt;br /&gt;
 [&amp;amp;lt;c014e3b6&amp;amp;gt;] __report_bad_irq+0x36/0x75&lt;br /&gt;
 [&amp;amp;lt;c014e5d0&amp;amp;gt;] note_interrupt+0x1db/0x217&lt;br /&gt;
 [&amp;amp;lt;f885fa1e&amp;amp;gt;] usb_hcd_irq+0x21/0x4e [usbcore]&lt;br /&gt;
 [&amp;amp;lt;c014dadd&amp;amp;gt;] handle_IRQ_event+0x23/0x51&lt;br /&gt;
 [&amp;amp;lt;c014ed3d&amp;amp;gt;] handle_fasteoi_irq+0x86/0xa6&lt;br /&gt;
 [&amp;amp;lt;c0106552&amp;amp;gt;] do_IRQ+0x55/0x6f&lt;br /&gt;
 [&amp;amp;lt;c0127fa0&amp;amp;gt;] irq_exit+0x53/0x6b&lt;br /&gt;
 [&amp;amp;lt;c0115d1b&amp;amp;gt;] smp_apic_timer_interrupt+0x71/0x7d&lt;br /&gt;
 [&amp;amp;lt;c010487b&amp;amp;gt;] common_interrupt+0x23/0x28&lt;br /&gt;
 =======================&lt;br /&gt;
handlers:&lt;br /&gt;
[&amp;amp;lt;f885f9fd&amp;amp;gt;] (usb_hcd_irq+0x0/0x4e [usbcore])&lt;br /&gt;
Disabling IRQ #21&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Suspend ==&lt;br /&gt;
=== Save to disk ===&lt;br /&gt;
Save to disk works perfectly out-of-box. You only need to have enough swap (i've got 4 gigs of RAM and 1 gig of swap...thought it should't, it works :-))&lt;br /&gt;
&lt;br /&gt;
=== Save to RAM ===&lt;br /&gt;
Save to RAM doesn't work right out-of-the-box, [http://en.opensuse.org/Projects_KPowersave KPowersave] when asked to suspend the PC, reports an error. The problem is in the way [http://en.opensuse.org/S2ram S2ram] works. The developers maitain [http://suspend.cvs.sourceforge.net/suspend/suspend/whitelist.c?view=markup a whitelist] with needed switches for the exact machine (or event it's model) and my ThinkPad was not listed. I've reported it and now, models 7673, 7674 and 7675 are present in the whitelist (= no need to edit anything, it should just work).&lt;br /&gt;
&lt;br /&gt;
When your model is not listed, you can try launching the &amp;lt;code&amp;gt;s2ram&amp;lt;/code&amp;gt; with -f (force) switch, it will ignore the whitelist. 61-series ThinkPads with 64-bit are supposed to be suspended with &amp;lt;code&amp;gt;-a 3&amp;lt;/code&amp;gt; parameter (&amp;lt;code&amp;gt;acpi_sleep&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;s3_mode&amp;lt;/code&amp;gt;), the whole command will look like this:&lt;br /&gt;
{{cmdroot|s2ram -f -a 3}}&lt;br /&gt;
&lt;br /&gt;
{{HINT|When you got Suspend to RAM working on you laptop, [http://en.opensuse.org/S2ram#How_to_contact_the_authors_of_s2ram.3F let the developers know] so they can add your model to the whitelist.}}&lt;br /&gt;
&lt;br /&gt;
When you try it and the laptop seems to resume from sleep fine, you can edit {{path|/etc/pm/config.d/sleep}} to tell the S2ram, how it should suspend your particulral laptop.&lt;br /&gt;
&amp;lt;pre&amp;gt;# cat /etc/pm/config.d/sleep&lt;br /&gt;
S2RAM_OPTS=&amp;quot;-f -a 3&amp;quot;&amp;lt;/pre&amp;gt;&lt;br /&gt;
You can also use the &amp;lt;code&amp;gt;SUSPEND_MODULES=&amp;quot;&amp;amp;lt;module names&amp;amp;gt;&amp;quot;&amp;lt;/code&amp;gt; option to set which modules should be unloaded before suspend. This was not needed on my configuration.&lt;br /&gt;
&lt;br /&gt;
After this, the suspend to RAM will work from utilities like KPowersave. When using docking station, it is useful to disable suspend based on lid closing. The laptop consumes about 160 mW of power when in suspend state.&lt;br /&gt;
&lt;br /&gt;
== Trackpoint ==&lt;br /&gt;
The configuration is described in [[Trackpoint]] site, here on ThinkWiki. My own configuration follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;:&lt;br /&gt;
:&lt;br /&gt;
Section &amp;quot;InputDevice&amp;quot;&lt;br /&gt;
  Driver       &amp;quot;mouse&amp;quot;&lt;br /&gt;
  Identifier   &amp;quot;Mouse[1]&amp;quot;&lt;br /&gt;
  Option       &amp;quot;Buttons&amp;quot; &amp;quot;11&amp;quot;&lt;br /&gt;
  Option       &amp;quot;Device&amp;quot; &amp;quot;/dev/input/mice&amp;quot;&lt;br /&gt;
  Option       &amp;quot;Name&amp;quot; &amp;quot;ThinkPad Trackpoint&amp;quot;&lt;br /&gt;
  Option       &amp;quot;Protocol&amp;quot; &amp;quot;explorerps/2&amp;quot;&lt;br /&gt;
  Option       &amp;quot;Vendor&amp;quot; &amp;quot;Lenovo&amp;quot;&lt;br /&gt;
  Option       &amp;quot;EmulateWheel&amp;quot;        &amp;quot;on&amp;quot;&lt;br /&gt;
  Option       &amp;quot;EmulateWheelTimeOut&amp;quot; &amp;quot;200&amp;quot;&lt;br /&gt;
  Option       &amp;quot;EmulateWheelButton&amp;quot;  &amp;quot;2&amp;quot;&lt;br /&gt;
  Option       &amp;quot;YAxisMapping&amp;quot;        &amp;quot;4 5&amp;quot;&lt;br /&gt;
  Option       &amp;quot;XAxisMapping&amp;quot;        &amp;quot;6 7&amp;quot;&lt;br /&gt;
  Option       &amp;quot;ZAxisMapping&amp;quot;        &amp;quot;4 5&amp;quot;&lt;br /&gt;
EndSection&lt;br /&gt;
:&lt;br /&gt;
:&lt;br /&gt;
Section &amp;quot;ServerLayout&amp;quot;&lt;br /&gt;
  InputDevice  &amp;quot;Mouse[1]&amp;quot; &amp;quot;CorePointer&amp;quot;&lt;br /&gt;
EndSection&lt;br /&gt;
:&lt;br /&gt;
:&amp;lt;/pre&amp;gt;&lt;br /&gt;
The wheel emulation works fine, but it has problem with some web browsers (probably fixable by disabling the middle button in the browser). The press-to-select ({{cmdroot|echo -n 1 &amp;gt; /sys/devices/platform/i8042/serio1/press_to_select}}) feature works also fine but requires more power for the mouse to generate click than the regular touchpad.&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
The computer includes a integrated soundcard, Intel High Definition Audio, particularly Analog Device 82801H chip. This soundcard could be used with AD1984 driver included in ALSA 1.0.15 (Linux 2.6.23). Thought openSUSE 10.3 only includes ALSA 1.0.14, the sound does work (ALSA is probably patched) out of box.&lt;br /&gt;
&lt;br /&gt;
{{NOTE|The winmodem must be enabled in BIOS for soundcard to work}}&lt;br /&gt;
&lt;br /&gt;
Internal mic does work, you're only required to set Internal Mic volume in some sound utility (like &amp;lt;code&amp;gt;alsamixer&amp;lt;/code&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
== SD card reader ==&lt;br /&gt;
SD/SDHC/SDIO card reader works out-of-box including indication LED. It's [[SD_Card_slot|Ricoh Co Ltd R5C822]] reader and it's connected to the PCI bus. The reader is supported by the &amp;lt;code&amp;gt;sdhci&amp;lt;/code&amp;gt; module from kernel 2.6.17-rc1 what means that openSUSE 10.3 supports it. The sequential read speed it about 3.5 MiB/s, nothing special.&lt;br /&gt;
&lt;br /&gt;
== CardBus slot ==&lt;br /&gt;
Nearby the SD card reader, the Cardbus slot could be found. Lenovo declares that it should support even the ExpressCard cards using an adapter (but this is gonna be probably some kind of emulation). Regardless of the ExpressCard support, it runs 32-bit CardBus and older 16-bit PCMCIA cards fine.&lt;br /&gt;
&lt;br /&gt;
== Wired Ethernet ==&lt;br /&gt;
The laptop has a quite common gigabit Ethernet adapter Intel 82566MM, better known as Intel PRO/1000 Gigabit Ethernet. The &amp;lt;code&amp;gt;e1000&amp;lt;/code&amp;gt; driver is in the kernel, network connection works out-of-box.&lt;br /&gt;
&lt;br /&gt;
== Wireless Ethernet ==&lt;br /&gt;
The wireless Ethernet adapter Intel Wireless WiFi Link 4965ANG works immediately with kernel module &amp;lt;code&amp;gt;iwlwifi&amp;lt;/code&amp;gt; after installation but the problem is the openSUSE driver is too old. After Online Update, the installed version is 1.1.10 which works pretty good [http://bughost.org/bugzilla/show_bug.cgi?id=1581 unless your're planning to use WPA Enterprise authentication] (EAP-TLS, EAP-TTLS). This is solved in the latest GIT unstable versions (no stable version works fine). Refer to the [http://intellinuxwireless.org/?p=iwlwifi Intel site] for more info how to get the newest code. &lt;br /&gt;
&lt;br /&gt;
{{HINT|Some users choose to replace the Intel WiFi card with Atheros one, distributed as [[ThinkPad 11a/b/g Wireless LAN Mini Express Adapter]]. The &amp;lt;code&amp;gt;madwifi&amp;lt;/code&amp;gt; seems to be more stable and since the Atheros adapter is distributed by Lenovo, there are no [[Problem_with_unauthorized_MiniPCI_network_card|problems with unathorized MiniPCI network card]]}}&lt;br /&gt;
&lt;br /&gt;
The [http://bughost.org/bugzilla/show_bug.cgi?id=1209 LED indicatior does work] in kernels after 2.6.24.&lt;br /&gt;
&lt;br /&gt;
I've tested the adapter even with the [http://ndiswrapper.sourceforge.net/joomla/ NDISwrapper] but with no usable result. Because i've got 64-bit kernel, i've got to use 64-bit Windows drivers. Sadly, when the drivers are installed, the NDISwrapper crashes with a SEGFAULT.&lt;br /&gt;
&lt;br /&gt;
== Bluetooth ==&lt;br /&gt;
Lenovo used the Bluetooth adapter BCM2045B made by Broadcom and connected to the USB bus. The hardware is correctly recognized, no configuration is required. The {{key|Fn}}{{key|F5}} keyboard shortcut doesn't work out of box but you can enable it using script on page [[ThinkPad Bluetooth with Enhanced Data Rate (BDC-2)]].&lt;br /&gt;
&lt;br /&gt;
== Fingerprint reader ==&lt;br /&gt;
The [[Integrated_Fingerprint_Reader|fingerprint reader]] (made by SGS Thomson Microelectronics) works out of box and could be even [http://en.opensuse.org/Using_Fingerprint_Authentication configured in YasT]. You only need to set the fingerprints in every user account that will be using this device. After that, you can login using your fingers :-)&lt;br /&gt;
&lt;br /&gt;
How easy and working this seems to be, the truth is that you cannot use KDM to login and KScreensaver (resp. &amp;lt;code&amp;gt;kdesktop_lock&amp;lt;/code&amp;gt;) to lock your desktop. The KDM just don't know you have some fingerprint reader and the KScreensaver crashes and needs to be killed from the terminal. Also, the KDE password dialogs (&amp;lt;code&amp;gt;kdesu&amp;lt;/code&amp;gt;) don't know how to use the fingerprint reader. Fingerpint works correctly when used from console. There is already a [http://bugs.kde.org/show_bug.cgi?id=116682 KDE bug] filled at the Bugzilla.&lt;br /&gt;
&lt;br /&gt;
{{HINT|You can use GDM instead of KDM to be able to login using fingerprint reader}}&lt;br /&gt;
&lt;br /&gt;
The alternative binary driver [http://www.upek.com/support/dl_linux_bsp.asp &amp;lt;code&amp;gt;bioapi&amp;lt;/code&amp;gt;] seems to solve all the problems but it's installation is [[How_to_enable_the_integrated_fingerprint_reader_with_BioAPI|a bit complicated]]. &lt;br /&gt;
&lt;br /&gt;
You can also use [[How to enable the integrated fingerprint reader with fprint|fprint]].&lt;br /&gt;
&lt;br /&gt;
== ACPI -- hotkeys ==&lt;br /&gt;
(HW) does mean that the key works independently on the operating system installed. Some (for example {{key|Fn}}{{key|F4}}) are captured by the KPowersave utility.&lt;br /&gt;
=== Working keys ===&lt;br /&gt;
These keys work automatically out-of-box, after installation.&lt;br /&gt;
* {{key|Fn}}{{key|F2}} lock screen (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001002&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F4}} save to RAM (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001004&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F12}} save to disk (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 0000100c&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|PgUp}} enable display LED ([[ThinkLight]]) (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001012&amp;lt;/code&amp;gt;, HW)&lt;br /&gt;
* {{key|Volume Up}} turn Volume Up (HW)&lt;br /&gt;
* {{key|Volume Down}} turn Volume Down (HW)&lt;br /&gt;
* {{key|Disable sound}} disable sound (X11 -- &amp;lt;code&amp;gt;XF86AudioMute&amp;lt;/code&amp;gt;, HW)&lt;br /&gt;
{{NOTE|The sound needs to be enabled after installation using Volume Up key, the software mixer is not enough}}&lt;br /&gt;
&lt;br /&gt;
=== Working, but not assigned keys ===&lt;br /&gt;
These keys are working but aren't assignet to any application. The ACPI keycodes could be caputured using &amp;lt;code&amp;gt;acpid&amp;lt;/code&amp;gt;, the X11 keycodes could be used in some application as keyboard shortcuts.&lt;br /&gt;
* {{key|Fn}}{{key|F8}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001008&amp;lt;/code&amp;gt;) &lt;br /&gt;
* {{key|Fn}}{{key|F9}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001009&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|Up}} stop playback (X11 -- &amp;lt;code&amp;gt;XF86AudioStop&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|Down}} start playback / pause (X11 -- &amp;lt;code&amp;gt;XF86AudioPlay&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|Left}} previous track (X11 -- &amp;lt;code&amp;gt;XF86AudioPrev&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|Right}} next track (X11 -- &amp;lt;code&amp;gt;XF86AudioNext&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Page right}} page left (X11 -- &amp;lt;code&amp;gt;XF86Back&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Page left}} page right (X11 -- &amp;lt;code&amp;gt;XF86Forward&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|Home}} backlight up (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001010&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|End}} backlight down (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001011&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{ibmkey|ThinkVantage|#495988}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001018&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F1}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001001&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F3}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001003&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F5}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001005&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F6}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001006&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F7}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001007&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F8}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001008&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F9}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 00001009&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F10}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 0000100a&amp;lt;/code&amp;gt;)&lt;br /&gt;
* {{key|Fn}}{{key|F11}} (ACPI -- &amp;lt;code&amp;gt;ibm/hotkey HKEY 00000080 0000100b&amp;lt;/code&amp;gt;)&lt;br /&gt;
&lt;br /&gt;
The {{key|Fn}}{{key|Home}} and {{key|Fn}}{{key|End}} keys should work again without the need to configure them in kernel 2.6.24 using &amp;lt;code&amp;gt;thinkpad_acpi&amp;lt;/code&amp;gt; 0.18.&lt;br /&gt;
&lt;br /&gt;
== Docking station ==&lt;br /&gt;
This particlar model is shipped with a [[UltraBase X6]] docking station. The dock works mostly out of box, but it needs to be configured to work perfectly (eg. automatically change screen resolution after docking). OpenSUSE has a utility set called [http://en.opensuse.org/Dockutils Dockutils] which handles the docking process. If you want to get you dock working better, please see the [[UltraBase X6]] article.&lt;br /&gt;
&lt;br /&gt;
== Power management ==&lt;br /&gt;
The CPU frequency scaling works automatically after installation and could be set using KPowersave or sys filesystem (more on this in [[How to make use of Dynamic Frequency Scaling]]).&lt;br /&gt;
&lt;br /&gt;
The [http://www.lesswatts.org/ LessWatts.org] gives some examples, how one can make the laptop even more power-saving. I use the follwing combination of settings:&lt;br /&gt;
&lt;br /&gt;
{{cmdroot|cat /etc/rc.d/boot.local}}&lt;br /&gt;
&amp;lt;pre&amp;gt;#! /bin/sh&lt;br /&gt;
&lt;br /&gt;
# Linux Powersave&lt;br /&gt;
# scheduler power savings&lt;br /&gt;
echo 1 &amp;gt; /sys/devices/system/cpu/sched_mc_power_savings&lt;br /&gt;
&lt;br /&gt;
# power on the WiFi adapter&lt;br /&gt;
echo 5 &amp;gt; /sys/bus/pci/drivers/iwl4965/0000\:03\:00.0/power_level&lt;br /&gt;
&lt;br /&gt;
# HDD power management, sleep after 5 mins&lt;br /&gt;
hdparm -B128 -S60 /dev/sda &amp;gt; /dev/null&lt;br /&gt;
&lt;br /&gt;
# HDD writebacks after 5 mins&lt;br /&gt;
echo 3000 &amp;gt; /proc/sys/vm/dirty_writeback_centisecs&lt;br /&gt;
&lt;br /&gt;
# HDD I/O grouping&lt;br /&gt;
echo 5 &amp;gt; /proc/sys/vm/laptop_mode&lt;br /&gt;
&lt;br /&gt;
# disable Wake On LAN&lt;br /&gt;
ethtool -s eth0 wol d&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following configuration results in:&lt;br /&gt;
* brightness 44%, Bluetooth + WiFi enabled, CPU in Powersave mode: 14.6 W ([http://www.lesswatts.org/projects/powertop/ PowerTOP] long-term 13.2 W)&lt;br /&gt;
* brightness 44%, Bluetooth + WiFi disabled, CPU in Powersave mode: 12.4 W&lt;br /&gt;
* brightness 44%, Bluetooth + WiFi disabled, CPU in Powersave mode, [[ACPI_fan_control_script|fan disabled]]: 11.2 W&lt;br /&gt;
{{HINT|More power savings could be achieved using tickless kernel and various SATA, ACPI and USB patches. Intel says that it could save up to 2 watts more.}}&lt;br /&gt;
&lt;br /&gt;
== Used files list ==&lt;br /&gt;
* [http://akela.mendelu.cz/~xgrmela1/recenze-x61/files/xorg.conf /etc/X11/xorg.conf]&lt;br /&gt;
* [http://akela.mendelu.cz/~xgrmela1/recenze-x61/files/sleep /etc/pm/config.d/sleep]&lt;br /&gt;
* [http://akela.mendelu.cz/~xgrmela1/recenze-x61/files/10x61 /etc/X11/xinit/xinitrc.d/10x61]&lt;br /&gt;
* [http://akela.mendelu.cz/~xgrmela1/recenze-x61/files/boot.local /etc/rc.d/boot.local]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
	<entry>
		<id>https://www.thinkwiki.org/w/index.php?title=CT-65550&amp;diff=62536</id>
		<title>CT-65550</title>
		<link rel="alternate" type="text/html" href="https://www.thinkwiki.org/w/index.php?title=CT-65550&amp;diff=62536"/>
		<updated>2025-04-11T07:09:15Z</updated>

		<summary type="html">&lt;p&gt;ThinkGNU: X.Org is not Linux. Linux's terminal emulator is fbcon.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin: 0; margin-right:10px; border: 1px solid #dfdfdf; padding: 0em 1em 1em 1em; background-color:#F8F8FF; align:right;&amp;quot;&amp;gt;&lt;br /&gt;
=== CT-65550 ===&lt;br /&gt;
This is a Chips and Technologies video adapter&lt;br /&gt;
&lt;br /&gt;
=== Features ===&lt;br /&gt;
* Chipset: CT HiQV&lt;br /&gt;
* PCI ID: 102c:00e0&lt;br /&gt;
* 1MB EDO DRAM&lt;br /&gt;
* Interface: PCI 2.1&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|style=&amp;quot;vertical-align:top&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== X.Org driver ===&lt;br /&gt;
This chip is supported by the 'chips' driver as part of the X.Org distribution&lt;br /&gt;
&lt;br /&gt;
==== ThinkPad LCD ====&lt;br /&gt;
Display on the internal LCD works as long as you set the monitor settings correct.&lt;br /&gt;
&lt;br /&gt;
==== External VGA port ====&lt;br /&gt;
??&lt;br /&gt;
=== Linux fbcon Framebuffer driver ===&lt;br /&gt;
??&lt;br /&gt;
&lt;br /&gt;
=== ThinkPads this chip may be found in ===&lt;br /&gt;
* {{310}}, {{310D}}, {{310E}}, {{310ED}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Video Controllers]]&lt;/div&gt;</summary>
		<author><name>ThinkGNU</name></author>
		
	</entry>
</feed>