[PATCH] fix too short span of sil24_issue_SRST() loop to reset non-native hard drives

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

 



  Hi,

  I use the ASI ARAID99 2000 connected with Sil3124 pci card.  
However, the Linux driver (sata_sil24.c) cannot finish phy_reset.
The dmesg is displayed as follows:

========
ata1: SRST failed, disabling port
========

and ...

========
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
sata_sil24: interrupt form disabled port 0
irq XX: nobody cared (try booting with the "irqpoll" option)
========

  This problem is fixed by this patch;  the span of loop
in sil24_issue_SRST() is too short to reset non-native hard
drive like my RAID subsystem.

*** drivers/scsi/sata_sil24.c._orig_	2006-03-02 07:37:27.000000000 +0900
--- drivers/scsi/sata_sil24.c	2006-03-05 21:22:44.000000000 +0900
***************
*** 452,458 ****
  
  	writel((u32)paddr, port + PORT_CMD_ACTIVATE);
  
! 	for (cnt = 0; cnt < 100; cnt++) {
  		irq_stat = readl(port + PORT_IRQ_STAT);
  		writel(irq_stat, port + PORT_IRQ_STAT);		/* clear irq */
  
--- 493,499 ----
  
  	writel((u32)paddr, port + PORT_CMD_ACTIVATE);
  
! 	for (cnt = 0; cnt < 1000; cnt++) {
  		irq_stat = readl(port + PORT_IRQ_STAT);
  		writel(irq_stat, port + PORT_IRQ_STAT);		/* clear irq */
  
***************
*** 460,466 ****
  		if (irq_stat & (PORT_IRQ_COMPLETE | PORT_IRQ_ERROR))
  			break;
  
! 		msleep(1);
  	}
  
  	/* restore IRQs */
--- 501,507 ----
  		if (irq_stat & (PORT_IRQ_COMPLETE | PORT_IRQ_ERROR))
  			break;
  
! 		msleep(10);
  	}
  
  	/* restore IRQs */



==  Chisato Yamauchi  =================================
-
: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux