rpms/kernel/F-8 linux-2.6-libata-force-hardreset-in-sleep-mode.patch, NONE, 1.1 kernel.spec, 1.450, 1.451 linux-2.6-libata-ali-atapi-dma.patch, 1.1, NONE

Chuck Ebbert (cebbert) fedora-extras-commits at redhat.com
Tue May 27 17:37:31 UTC 2008


Author: cebbert

Update of /cvs/pkgs/rpms/kernel/F-8
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv2804

Modified Files:
	kernel.spec 
Added Files:
	linux-2.6-libata-force-hardreset-in-sleep-mode.patch 
Removed Files:
	linux-2.6-libata-ali-atapi-dma.patch 
Log Message:
* Thu May 22 2008 Chuck Ebbert <cebbert at redhat.com> 2.6.25.4-11
- Remove already-merged libata pata_ali DMA disable patch.
- Add missing libata patch from the F9 kernel.


linux-2.6-libata-force-hardreset-in-sleep-mode.patch:

--- NEW FILE linux-2.6-libata-force-hardreset-in-sleep-mode.patch ---
Currently, libata doesn't support link powersave modes and always
disables link PS modes.  However, if the link is already in powersave
mode when libata begis probing, inhibiting powersave modes by setting
IPM isn't enough.  Link should be manually transited into active mode
using SPM or hardreset.

As SPM isn't avalable on all controllers and we're gonna prefer
hardreset in future anyway, force hardreset if link is in powersave
mode.

Reported-by: Paul Collins <paul at burly.ondioline.org>
Signed-off-by: Tejun Heo <htejun at gmail.com>
---
Jeff, this isn't necessary for #upstream.

drivers/ata/libata-core.c |   15 +++++++++++++++
1 file changed, 15 insertions(+)

index be95fdb..e3ddefd 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -3966,11 +3966,26 @@ int ata_std_prereset(struct ata_link *link, unsigned long deadline)
 
 	/* if SATA, resume link */
 	if (ap->flags & ATA_FLAG_SATA) {
+		u32 sstatus;
+
 		rc = sata_link_resume(link, timing, deadline);
 		/* whine about phy resume failure but proceed */
 		if (rc && rc != -EOPNOTSUPP)
 			ata_link_printk(link, KERN_WARNING, "failed to resume "
 					"link for reset (errno=%d)\n", rc);
+
+		/* force hardreset if the link is sleeping */
+		if (sata_scr_read(link, SCR_STATUS, &sstatus) == 0) {
+			u8 ipm = sstatus >> 8;
+
+			if (ipm == 2 || ipm == 6) {
+				ata_link_printk(link, KERN_INFO,
+						"link in %s mode, forcing hardreset\n",
+						ipm == 2 ? "partial" : "slumber");
+				ehc->i.action |= ATA_EH_HARDRESET;
+				return 0;
+			}
+		}
 	}
 
 	/* Wait for !BSY if the controller can wait for the first D2H



Index: kernel.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-8/kernel.spec,v
retrieving revision 1.450
retrieving revision 1.451
diff -u -r1.450 -r1.451
--- kernel.spec	23 May 2008 02:21:37 -0000	1.450
+++ kernel.spec	27 May 2008 17:36:32 -0000	1.451
@@ -634,8 +634,9 @@
 Patch610: linux-2.6-defaults-fat-utf8.patch
 Patch620: linux-2.6-defaults-unicode-vt.patch
 Patch640: linux-2.6-defaults-pci_no_msi.patch
-Patch660: linux-2.6-libata-ali-atapi-dma.patch
+
 Patch670: linux-2.6-ata-quirk.patch
+Patch671: linux-2.6-libata-force-hardreset-in-sleep-mode.patch
 Patch674: linux-2.6-sata-eeepc-faster.patch
 
 Patch680: linux-2.6-wireless.patch
@@ -1139,10 +1140,10 @@
 
 # libata
 #
-# Disable ATAPI DMA on ALI chipsets.
-ApplyPatch linux-2.6-libata-ali-atapi-dma.patch
 # ia64 ata quirk
 ApplyPatch linux-2.6-ata-quirk.patch
+# force hard reset when ahci links are asleep at init time
+ApplyPatch linux-2.6-libata-force-hardreset-in-sleep-mode.patch
 # make eeepc ata go faster
 ApplyPatch linux-2.6-sata-eeepc-faster.patch
 
@@ -1820,6 +1821,10 @@
 
 
 %changelog
+* Thu May 22 2008 Chuck Ebbert <cebbert at redhat.com> 2.6.25.4-11
+- Remove already-merged libata pata_ali DMA disable patch.
+- Add missing libata patch from the F9 kernel.
+
 * Thu May 22 2008 Chuck Ebbert <cebbert at redhat.com> 2.6.25.4-10
 - Revert to the "old" RTC driver for F8.
 


--- linux-2.6-libata-ali-atapi-dma.patch DELETED ---




More information about the fedora-extras-commits mailing list