[PATCH 1/5] ata: ahci: fix wrong link check

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The following commit accidently bailed out if the link is up, not
when it's down as stated in the commit message.

| commit a3f74d928ce73f37eab5b398e018aaeb42fd2ba4
| Author: Rob Herring <rob.herring@xxxxxxxxxxx>
| Date:   Mon Feb 11 18:02:00 2013 +0100
|
|     ahci: handle COMINIT received during spin-up
|
|     Some Intel SSDs can send a COMINIT after the initial COMRESET. This causes
|     the link to go down and we need to re-initialize the link.
|
|     Signed-off-by: Rob Herring <rob.herring@xxxxxxxxxxx>
|     Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@xxxxxxxxxxxx>
|     Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>
|

Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>
---
 drivers/ata/ahci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
index 4d5b52a..1712006 100644
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
@@ -387,7 +387,7 @@ static int ahci_init_port(struct ahci_port *ahci_port)
 	ret = wait_on_timeout(WAIT_SPINUP,
 			((readl(port_mmio + PORT_TFDATA) &
 			 (ATA_STATUS_BUSY | ATA_STATUS_DRQ)) == 0)
-			|| !((readl(port_mmio + PORT_SCR_STAT) & 0xf) == 1));
+			|| ((readl(port_mmio + PORT_SCR_STAT) & 0xf) == 1));
 	if (ret) {
 		ahci_port_info(ahci_port, "timeout.\n");
 		ret = -ENODEV;
-- 
1.8.2.rc2


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox


[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux