Difference between revisions of "Problems with SATA and Linux"
m (→No disk information) |
(libata status) |
||
Line 11: | Line 11: | ||
*ThinkPad {{R52}} | *ThinkPad {{R52}} | ||
*ThinkPad {{X41}}, {{X41T}} | *ThinkPad {{X41}}, {{X41T}} | ||
− | |||
− | {{NOTE|Some of these problems will be solved in Linux 2.6.15. See [http://linux.yyz.us/sata/software-status.html | + | {{NOTE|Some of these problems will be solved in Linux 2.6.15. See the SATA driver [http://linux.yyz.us/sata/features.html features], [http://linux.yyz.us/sata/software-status.html software status] and [http://linux.yyz.us/sata/sata-status.html hardware status].}} |
+ | |||
==Hang on resume from suspend to RAM== | ==Hang on resume from suspend to RAM== | ||
Revision as of 10:24, 15 December 2005
Contents
|
Some ThinkPad models use a SATA controller for the system hard disk. This causes several complications for Linux installation. The following lists these problems and known workarounds. Note that the details are often version- and distribution-specific. Models using a SATA disk interfaceModels using a SATA controller and a SATA system disk: Models using a SATA controller and a PATA (IDE) system disk with a SATA-to-PATA bridge:
NOTE!
Some of these problems will be solved in Linux 2.6.15. See the SATA driver features, software status and hardware status.
Hang on resume from suspend to RAMLinux kernels (as of 2.6.15-rc3) 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 (LKML posting) fixes this by adding SATA power management support. Patches
Some distributions already include this patch (e.g., Ubuntu Breezy), but some don't (e.g., Fedora 4). Links
Failed resume from suspend to diskSuspend 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. DVD drive not recognizedThe ata_piix SATA driver grabs ownership over the IDE ports when it is loaded, but (by default) does not support PATA ATAPI devices such as the Ultrabay optical drives. Thus, if the ide driver is compiled as a module and loaded after ata_piix, the DVD drive will not be recognized by either driver. Either of the following configurations will work:
Note that the optical drive must be in the Ultrabay during system boot (Ultrabay device swapping is currently unsupported). No DMA on DVD driveUsing the IDE driver, DMA support cannot be enabled on an Ultrabay optical drive: # hdparm -d1 /dev/hdc /dev/hdc: setting using_dma to 1 (on) HDIO_SET_DMA failed: Operation not permitted using_dma = 0 (off) As a result, the optical drive is slow, and in particular, too slow to play video DVDs. One workaround is to use employ the SATA driver (instead of the IDE driver) for the optical drive. This requires enabling two featues of the SATA driver, namely ATAPI support and PATA support, which are both in active development and far from stable. Using this will probably devour all your data and go on to eat all the food in your fridge. But if you have full backups and an empty fridge, do the following:
If this doesn't work, use
If yes, enable support for these chipsets has to be enabled by setting #define ATA_ENABLE_PATA in include/linux/libata.h (and report your ThinkPad model in the discussion page). 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). Links
No DMA on system hard diskIn some Linux kernels, both the SATA driver and the IDE driver can handle the system hard disk. With the SATA driver, it shows as /dev/sda and DMA is enabled. With the IDE driver, it shows as /dev/hda and DMA is disabled. The simplest way to enable DMA is to force the IDE driver to ignore the system hard disk by passing the (Observed on a ThinkPad T43 with Fedora Core kernel 2.6.13-1.1526_FC4.) No SMART supportPrior to kernel 2.6.15, the Linux SATA system did not support SMART commands (e.g., via smartctl). The capability was incorporated into Linux 2.6.15-rc1, and a patch is available for older kernels:
After applying the patch, run smartctl with the "-d ata" parameter:
No disk power managementPrior to kernel 2.6.15, the Linux SATA system did not support power management commands on these models. The above patches for SMART support resolves this, and in particular enables the following commands:
Note that this command is still rejected:
(Tested with patched kernels 2.6.13.1 and 2.6.12-4 and a 60GB 7200RPM disk model HTS726060M9AT00.) Note that even when Laptop-mode is used, the "hddtemp" daemon (as shipped with Fedora Core 4) will wake up the disk every minute, and must thus be disabled for power management to be effective. Its accesses are not visibile through the /proc/sys/vm/block_dump facility. It is unclear whether disk temperature can be monitored without causing the disk to spin up (on the T43, none of the /proc/acpi/ibm/thermal values corresponds to the disk's built-in temperature sensor). No disk informationPrior to kernel 2.6.15, on these models the disk information could not be read by the standard commands such as:
The latter is fixed by the above patch for SMART support. No swapping of UltraBay deviceThe libata driver does not yet hot-swapping (or warm-swapping) of PATA devices. If you use a DVD or 2nd PATA HDD via the libata (SATA) driver, to swap them in or out you must power down the machine. If you use the ide driver for a PATA UltraBay device, hot-swapping might work using hdparm, idectl or hotswap (please report). However, DMA will be disabled on these models (see above). If you use a SATA device in the UltraBay, libata hot-swapping might work (please report). Swapping of the UltraBay Slim Battery does work. BIOS error 2010 on user-installed hard diskWhile not a Linux issue, note that there is an issue with installing alternative PATA (IDE) hard disks as the system drive. 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. |