You are not logged in.

#1 2006-09-26 13:48:16

Chocobo
Member
Registered: 2006-09-26
Posts: 26

ata2: port failed to respond (30 secs) and ata2: SRST failed

Hello,

I just upgraded from 2.6.17.13-3 to 2.6.18-4 (testing) and when I am booting I hang temporarily with an ATA problem.  Here is a snippet from dmesg...

ata1: SATA max UDMA/133 cmd 0xFE00 ctl 0xFE12 bmdma 0xFEA0 irq 18
ata2: SATA max UDMA/133 cmd 0xFE20 ctl 0xFE32 bmdma 0xFEA8 irq 18
scsi0 : ata_piix
ata1.00: ATA-6, max UDMA/133, 156250000 sectors: LBA48
ata1.00: ata1: dev 0 multi count 8
ata1.01: ATA-7, max UDMA/133, 312581808 sectors: LBA48
ata1.01: ata1: dev 1 multi count 8
ata1.00: configured for UDMA/133
ata1.01: configured for UDMA/133
scsi1 : ata_piix
ata2: port is slow to respond, please be patient
ata2: port failed to respond (30 secs)
ata2: SRST failed (status 0xFF)
ata2: SRST failed (err_mask=0x100)
ata2: softreset failed, retrying in 5 secs
ata2: SRST failed (status 0xFF)
ata2: SRST failed (err_mask=0x100)
ata2: softreset failed, retrying in 5 secs
ata2: SRST failed (status 0xFF)
ata2: SRST failed (err_mask=0x100)
ata2: reset failed, giving up
  Vendor: ATA       Model: ST380013AS        Rev: 8.05
  Type:   Direct-Access                      ANSI SCSI revision: 05
  Vendor: ATA       Model: WDC WD1600JS-00M  Rev: 02.0
  Type:   Direct-Access                      ANSI SCSI revision: 05

Any ideas?  Thanks.

Offline

#2 2006-09-27 16:39:12

Chocobo
Member
Registered: 2006-09-26
Posts: 26

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

OK, I think I am going to post this as a bug.

Offline

#3 2006-09-29 08:29:40

zezaz
Member
From: Bordeaux, France
Registered: 2004-04-26
Posts: 80
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Same problem here (Dell Optiplex GX270), since the upgrade to 2.6.18.

Offline

#4 2006-09-29 08:37:28

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Are you all using ata_piix?

Offline

#5 2006-09-29 12:09:46

zezaz
Member
From: Bordeaux, France
Registered: 2004-04-26
Posts: 80
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Hi phrakture,

I hope this answers your question:

# lsmod | grep ata
ata_piix               10760  0
libata                 85908  1 ata_piix

And in case it helps too:

# grep ^MOD /etc/rc.conf
MOD_AUTOLOAD="yes"
MOD_BLACKLIST=()
MODULES=(tun capability)

Offline

#6 2006-09-29 15:07:32

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Ok, there's a bit of a kernel-level goof-up with ata_piix and piix.
For pata drives, you have the option to use _either_ of them.

Try the following:
run "mkinitcpio -M" (post it here).  Take all the modules listed and add the to MODULES in /etc/mkinitcpio.conf.  Replace the "ata_piix" module with just "piix".  Comment out the HOOKS line and use HOOKS="base udev filesystems".

Now run "mkinitcpio -g /boot/kernel26-test.img" as root, and set your bootloader to use that image.

Offline

#7 2006-09-29 16:49:39

ralvez
Member
From: Canada
Registered: 2005-12-06
Posts: 1,694
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

phrakture

I have the same problem as some of the other users that posted before me.
I followed your instructrions 'to the letter' but I have the same problem after rebooting.  :cry:

Just for the record I'm using lilo and a Dell Precision 670. If it is of any help I can send my config files.

Thanks a bunch!!

Offline

#8 2006-09-29 17:00:01

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Hmmm, try the above instructions with only ata_piix, maybe it's having both modules that causes the issue, not ata_piix itself.

Offline

#9 2006-09-29 18:15:46

ralvez
Member
From: Canada
Registered: 2005-12-06
Posts: 1,694
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Nope ... looks that this one will take a bit more that that... I made the changes but I get the very same error.

Oh well!! At least it boots  tongue ... so, we are still cooking here!

Offline

#10 2006-09-29 21:23:52

yankees26
Member
From: Connecticut, USA
Registered: 2006-09-29
Posts: 190

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Not sure if it helps, but I was having the same problem and did what phrakture said and it worked although it seems to take a little longer when it gets to

:: Loading UDev uevents                [BUSY]

Offline

#11 2006-09-30 14:29:57

twiistedkaos
Member
Registered: 2006-05-20
Posts: 666

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

I've tried phis instructions and it doesn't work for me. Hmm seems deeper then just changing the modules.

Offline

#12 2006-10-02 12:56:40

zezaz
Member
From: Bordeaux, France
Registered: 2004-04-26
Posts: 80
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Here is the output of "mkinitcpio -M" (normal mode):

# mkinitcpio -M
Modules autodetected:
cdrom
ide-cd
ide-core
ide-disk
generic
piix
e1000
ata_piix
libata
usbcore
ehci-hcd
uhci-hcd
usbhid
ext2
jbd
ext3

I built the image as suggested; i tried with just "piix" (and of course cdrom, ide-cd, ...) and then with just "ata_piix".

piix: the linux startup runs quickly through the drivers messages dump, then the UDev uevents loading is quite long (same as yankees26).
ata_piix: the dreaded "ata2: SRST failed..." messages reappear, and i can't boot at the end of the driver messages. The root partition can't be mounted.

So from what i see ata_piix is faulty, at least on my setup (Dell Optiplex GX270). However, there is still the long Udev uevents loading time if i force piix; i don't know where it comes from.

Offline

#13 2006-10-02 16:18:21

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

I had a desktop somewhere with similar symptoms, though it was on kernel 2.6.15 or something... it fixed itself, but now it seems like it's back...

I will try to find it (in a closet somewhere) and try to diagnose this better.

Offline

#14 2006-10-02 17:23:41

Neuro
Member
From: Poland
Registered: 2005-10-12
Posts: 352

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

My friend just bought a notebook with a ICH7 SATA bridge. His disk is SATA and I think that his cdrom is also.

He must use the ata_piix4 module (libata 2.0), and the kernel 2.6.18 has a bit of a hick-up loading. It detects the disk without problem, but it has some problems with the cdrom. It tries three times to detect it (each time with a retry after 5 secs) and it succeeds the third time. Always.

I can't post the dmesg now, but I will as soon as I'll be able.

Offline

#15 2006-10-02 19:53:02

Neuro
Member
From: Poland
Registered: 2005-10-12
Posts: 352

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Ok, got it:

libata version 2.00 loaded.
ata_piix 0000:00:1f.2: version 2.00
ata_piix 0000:00:1f.2: MAP [ P0 P2 IDE IDE ]
ACPI: PCI Interrupt 0000:00:1f.2[B] -> GSI 19 (level, low) -> IRQ 19
PCI: Setting latency timer of device 0000:00:1f.2 to 64
ata1: SATA max UDMA/133 cmd 0x1F0 ctl 0x3F6 bmdma 0x18B0 irq 14
scsi0 : ata_piix
ata1.00: ATA-7, max UDMA/100, 117210240 sectors: LBA48 NCQ (depth 0/32)
ata1.00: ata1: dev 0 multi count 16
ata1.00: configured for UDMA/100
  Vendor: ATA       Model: HTS541060G9SA00   Rev: MB3O
  Type:   Direct-Access                      ANSI SCSI revision: 05
ata2: PATA max UDMA/100 cmd 0x170 ctl 0x376 bmdma 0x18B8 irq 15
scsi1 : ata_piix
ata2.00: ATAPI, max UDMA/33
ata2.01: qc timeout (cmd 0xa1)
ata2.01: failed to IDENTIFY (I/O error, err_mask=0x4)
ata2: failed to recover some devices, retrying in 5 secs
ata2.01: qc timeout (cmd 0xa1)
ata2.01: failed to IDENTIFY (I/O error, err_mask=0x4)
ata2: failed to recover some devices, retrying in 5 secs
ata2.01: qc timeout (cmd 0xa1)
ata2.01: failed to IDENTIFY (I/O error, err_mask=0x4)
ata2: failed to recover some devices, retrying in 5 secs
ata2.00: configured for UDMA/33
  Vendor: PHILIPS   Model: DVD+-RW SDVD8441  Rev: PX43
  Type:   CD-ROM                             ANSI SCSI revision: 05
Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
SCSI device sda: 117210240 512-byte hdwr sectors (60012 MB)
sda: Write Protect is off
sda: Mode Sense: 00 3a 00 00
SCSI device sda: drive cache: write back
SCSI device sda: 117210240 512-byte hdwr sectors (60012 MB)
sda: Write Protect is off
sda: Mode Sense: 00 3a 00 00
SCSI device sda: drive cache: write back
 sda: sda1 sda2 sda3 sda4 <sda5>
sd 0:0:0:0: Attached scsi disk sda
sr0: scsi3-mmc drive: 24x/24x writer cd/rw xa/form2 cdda tray
Uniform CD-ROM driver Revision: 3.20
sr 1:0:0:0: Attached scsi CD-ROM sr0

As you can see, it has problems to identify this drive. It misidentifies it twice, and then the 3rd time has completely no problems.

If you (the kernel devs) can't help with it, please tell me where to report this.

Offline

#16 2006-10-02 19:58:51

zezaz
Member
From: Bordeaux, France
Registered: 2004-04-26
Posts: 80
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

It looks like the problem has been reported upstream too (i.e. on the Linux kernel mailing list).

Offline

#17 2006-10-02 20:33:13

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

I'm going to default to what the business world calls an "accountabilty matrix" and blame this on someone else.  It's all Dusty's fault!

Seriously though, this looks like an upstream problem... if anyone comes across a patch, let me know and we can apply/test that out.  Or, if circumstances are dire, I can hack at it myself.

Offline

#18 2006-10-08 14:14:02

twm
Member
From: Penn. USA
Registered: 2004-02-14
Posts: 5

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

I've got the same problem here on a ASUS P4P800SE motherboard sporting an ICH5 IDE controller.  DIfference is it hangs forever in ata2, so upgrading to 2.6.18 is impossible at this time.

LKM has posts on this same issue and it appears to be limited to ICH5/6/7 controllers, but I may be wrong.  We may have to just wait this one out and hope the kernel guys get it fixed.  Reading the release notes for the RC series you can see that much updating in the IDE/ATA stuff was done.


-twm

Offline

#19 2006-10-09 23:31:13

yankees26
Member
From: Connecticut, USA
Registered: 2006-09-29
Posts: 190

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

I read that LKM thing and it seems they found a patch if you continue reading, against 2.6.18.  Don't know if anyone wants to try it out, but here:

diff --git a/drivers/scsi/libata-core.c b/drivers/scsi/libata-core.c
index 427b73a..3bc7f57 100644
--- a/drivers/scsi/libata-core.c
+++ b/drivers/scsi/libata-core.c
@@ -2271,11 +2271,14 @@ static inline void ata_tf_to_host(struct
  *    Sleep until ATA Status register bit BSY clears,
  *    or a timeout occurs.
  *
- *    LOCKING: None.
+ *    LOCKING:
+ *    Kernel thread context (may sleep).
+ *
+ *    RETURNS:
+ *    0 on success, -errno otherwise.
  */
-
-unsigned int ata_busy_sleep (struct ata_port *ap,
-                 unsigned long tmout_pat, unsigned long tmout)
+int ata_busy_sleep(struct ata_port *ap,
+           unsigned long tmout_pat, unsigned long tmout)
 {
     unsigned long timer_start, timeout;
     u8 status;
@@ -2283,25 +2286,30 @@ unsigned int ata_busy_sleep (struct ata_
     status = ata_busy_wait(ap, ATA_BUSY, 300);
     timer_start = jiffies;
     timeout = timer_start + tmout_pat;
-    while ((status & ATA_BUSY) && (time_before(jiffies, timeout))) {
+    while (status != 0xff && (status & ATA_BUSY) &&
+           time_before(jiffies, timeout)) {
         msleep(50);
         status = ata_busy_wait(ap, ATA_BUSY, 3);
     }
 
-    if (status & ATA_BUSY)
+    if (status != 0xff && (status & ATA_BUSY))
         ata_port_printk(ap, KERN_WARNING,
                 "port is slow to respond, please be patientn");
 
     timeout = timer_start + tmout;
-    while ((status & ATA_BUSY) && (time_before(jiffies, timeout))) {
+    while (status != 0xff && (status & ATA_BUSY) &&
+           time_before(jiffies, timeout)) {
         msleep(50);
         status = ata_chk_status(ap);
     }
 
+    if (status == 0xff)
+        return -ENODEV;
+
     if (status & ATA_BUSY) {
         ata_port_printk(ap, KERN_ERR, "port failed to respond "
                 "(%lu secs)n", tmout / HZ);
-        return 1;
+        return -EBUSY;
     }
 
     return 0;
@@ -2392,10 +2400,8 @@ static unsigned int ata_bus_softreset(st
      * the bus shows 0xFF because the odd clown forgets the D7
      * pulldown resistor.
      */
-    if (ata_check_status(ap) == 0xFF) {
-        ata_port_printk(ap, KERN_ERR, "SRST failed (status 0xFF)n");
-        return AC_ERR_OTHER;
-    }
+    if (ata_check_status(ap) == 0xFF)
+        return 0;
 
     ata_bus_post_reset(ap, devmask);
 
diff --git a/include/linux/libata.h b/include/linux/libata.h
index 66c3100..eb7d90f 100644
--- a/include/linux/libata.h
+++ b/include/linux/libata.h
@@ -702,9 +702,8 @@ extern int ata_host_set_suspend(struct a
                 pm_message_t mesg);
 extern void ata_host_set_resume(struct ata_host_set *host_set);
 extern int ata_ratelimit(void);
-extern unsigned int ata_busy_sleep(struct ata_port *ap,
-                   unsigned long timeout_pat,
-                   unsigned long timeout);
+extern int ata_busy_sleep(struct ata_port *ap,
+              unsigned long timeout_pat, unsigned long timeout);
 extern void ata_port_queue_task(struct ata_port *ap, void (*fn)(void *),
                 void *data, unsigned long delay);
 extern u32 ata_wait_register(void __iomem *reg, u32 mask, u32 val,
@@ -1019,7 +1018,7 @@ static inline u8 ata_busy_wait(struct at
         udelay(10);
         status = ata_chk_status(ap);
         max--;
-    } while ((status & bits) && (max > 0));
+    } while (status != 0xff && (status & bits) && (max > 0));
 
     return status;
 }
@@ -1040,7 +1039,7 @@ static inline u8 ata_wait_idle(struct at
 {
     u8 status = ata_busy_wait(ap, ATA_BUSY | ATA_DRQ, 1000);
 
-    if (status & (ATA_BUSY | ATA_DRQ)) {
+    if (status != 0xff && (status & (ATA_BUSY | ATA_DRQ))) {
         unsigned long l = ap->ioaddr.status_addr;
         if (ata_msg_warn(ap))
             printk(KERN_WARNING "ATA: abnormal status 0x%X on port 0x%lXn",

EDIT: patch didn't work for me sad

Offline

#20 2006-10-26 13:05:04

Jacek Poplawski
Member
From: Poland
Registered: 2006-01-10
Posts: 736
Website

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

Same problem here, on two different systems with Arch and 2.6.18.1.

Offline

#21 2006-12-11 21:48:57

ralvy
Member
From: Santa Monica, California
Registered: 2004-12-06
Posts: 275

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

After appending 'earlymodules=piix' to my kernel command line, all these problems went away. However, I use an intel chip and did get a kernel panic after all those extraneous ata lines.

Offline

#22 2006-12-12 02:04:45

vasdee
Member
Registered: 2006-07-15
Posts: 55

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

i was using the 2.6.19 kernel from testing and i did encounter some problems with my cd drive getting recognised however i managed to get it work by loading the pata module. Now that the kernel has gone current i have the same problem again and can't get it back has anything changed since the kernel was moved to current?

I'm also getting those:

ATA: abnormal status 0xFF on port 0x177
ata1.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x2 frozen
ata1.00: (BMDMA stat 0x24)
ata1.00: tag 0 cmd 0xa0 Emask 0x4 stat 0x40 err 0x0 (timeout)
ata1: soft resetting port
ata1.00: configured for UDMA/66
ata1: EH complete
ata1.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x2 frozen
ata1.00: (BMDMA stat 0x24)
ata1.00: tag 0 cmd 0xa0 Emask 0x4 stat 0x40 err 0x0 (timeout)
ata1: soft resetting port

messages during boot but unlike Neuro my drive doesn't get detected sad

everything else works fine for me, what can i do to get my device restored again?

Offline

#23 2006-12-12 04:03:54

ralvy
Member
From: Santa Monica, California
Registered: 2004-12-06
Posts: 275

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

I'm not sure I understand all that is going on with this issue here. In my office, I must use the 'earlymodules=piix' kernel command line option, or else I get all those odd ata lines, with a long boot process that eventually panics. But at home, I don't have to use that kernel command line option and everything boots as usual. In each case I have the same device naming scheme I have always had: hda, hdb, etc.

Is the difference in the two boxes the BIOS in the motherboard? Each box has an Intel P4 chip.

When I do an 'mkinitcpio -M' on each box, I see piix stuff on the office box, but not on the home box, even though I set up both boxes myself and both are fully updated Arch boxes.

I'd love to understand more what's going on here, as I first heard of piix when this problem arose in the office today after updating Arch. Can someone point me in a good direction for further reading?

Offline

#24 2006-12-12 06:02:13

twiistedkaos
Member
Registered: 2006-05-20
Posts: 666

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

@ralvy
As far as I know, this problem only consist with computers that require the piix module, I am not positivie but I think it has to do with certain ide devices, can anyone confirm this?

Offline

#25 2006-12-12 12:47:57

soylent_green_is_hamster
Member
Registered: 2006-11-15
Posts: 109

Re: ata2: port failed to respond (30 secs) and ata2: SRST failed

I also get the same cd drive recognition problems on my IDE box
All my problems go away when I force piix with the kernel command line option but, like ralvy, I would like to know more about what is going on here.
I'm especially not sure what hooks to put in my mkinitcpio.conf. Should I be using pata (or ide) with ata_piix (and remove the scsi and sata ones)?
is there some handy further reading?
google isn't much help here

Offline

Board footer

Powered by FluxBB