Bug 175002

Summary: AHCI or ATA-ATI bug on BSD 8 and above (ATI SB600; ahci timeout; on BSD 7 - no bug)
Product: Base System Reporter: NIKA <ngovoruha>
Component: kernAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.txt none

Description NIKA 2013-01-05 11:40:00 UTC
I get a bug when I run install program FreeBSD 9.1 on my ASUS A7U notebook (ATI RS690 chipset; ATI SB600 south bridge; Seagate SATAI harddrive; BIOS a7uas.206, if it's important).

This bug have been posted already two times (first - after which I guessed to turn on Verbose option and wrote detailed dmesg, and second - because of formatting problem, no dmesg was posted). So, previous two PRs (kern/174880 and kern/174985) are about the same bug and can be closed.

The bug is the following. FreeBSD 9.1 (FreeBSD 8.3 too) can not see my harddrive. The message is: "ahcich1: Timeout on slot 0 port 0". So, install program can not resume - no hard drive in the system. My BIOS does not have option to switch drive to PATA mode, so AHCI is required.

At the same time, FreeBSD 7.4 can see it. With FreeBSD 7.4 is no problem. Clearly, some bug in AHCI or ATA-ATI driver appeared in 8R.

I am interested to use PCBSD, but can not do it. Please, help.

Below - messages from verbosed dmesg, which can relate to this bug (FreeBSD 9.1):

*************************************************
*
*
*
ahcich1: AHCI reset...
ahcich1: SATA connect time=1800us status=00000113
ahcich1: AHCI reset: device found
*
*
*
ata0: reset tp1 mask=03 ostat0=50 ostat1=00
ahcich1: AHCI reset: device ready after 100ms
(aprobe0:ahcich1:0:15:0): NOP. ACB: 00 00 00 00 00 00 00 00 00 00 00 00
(aprobe0:ahcich1:0:15:0): CAM status: Command timeout
(aprobe0:ahcich1:0:15:0): Error 5, Retries exhausted
ata0: stat0=0x00 err=0x01 lsb=0x14 msb=0xeb
ata0: stat1=0x00 err=0x00 lsb=0x00 msb=0x00
ata0: reset tp2 stat0=00 stat1=00 devices=0x10000
*
*
*
ahcich1: Timeout on slot 0 port 0
ahcich1: is 00000002 cs 00000000 ss 00000000 rs 00000001 tfd 50 serr 00000000 cmd 00042017
ahcich1: AHCI reset...
ahcich1: SATA connect time=1800us status=00000113
ahcich1: AHCI reset: device found
(aprobe0:ahcich1:0:0:0): ATA_IDENTIFY. ACB: ec 00 00 00 00 40 00 00 00 00 00 00
(aprobe0:ahcich1:0:0:0): CAM status: Command timeout
(aprobe0:ahcich1:0:0:0): Error 5, Retry was blocked
*
*
*
ahcich1: AHCI reset: device ready after 100ms
*
*
*
*************************************************

Fix: Patch attached with submission follows:
How-To-Repeat: Try to run FreeBSD 9.1 on ASUS A7U. I can test solves on my notebook.
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2013-01-07 03:56:11 UTC
State Changed
From-To: open->closed

Duplicate of ports/174985.
Comment 2 dfilter service freebsd_committer freebsd_triage 2013-01-24 09:34:02 UTC
Author: mav
Date: Thu Jan 24 09:33:43 2013
New Revision: 245875
URL: http://svnweb.freebsd.org/changeset/base/245875

Log:
  Disable MSI interrupts for SB600 chipset.  According to the report they are
  not functional.
  
  PR:		kern/174880, kern/174985, kern/175002
  MFC after:	1 week

Modified:
  head/sys/dev/ahci/ahci.c

Modified: head/sys/dev/ahci/ahci.c
==============================================================================
--- head/sys/dev/ahci/ahci.c	Thu Jan 24 09:30:42 2013	(r245874)
+++ head/sys/dev/ahci/ahci.c	Thu Jan 24 09:33:43 2013	(r245875)
@@ -114,8 +114,9 @@ static struct {
 #define AHCI_Q_NOAA	512
 #define AHCI_Q_NOCOUNT	1024
 #define AHCI_Q_ALTSIG	2048
+#define AHCI_Q_NOMSI	4096
 } ahci_ids[] = {
-	{0x43801002, 0x00, "ATI IXP600",	0},
+	{0x43801002, 0x00, "ATI IXP600",	AHCI_Q_NOMSI},
 	{0x43901002, 0x00, "ATI IXP700",	0},
 	{0x43911002, 0x00, "ATI IXP700",	0},
 	{0x43921002, 0x00, "ATI IXP700",	0},
@@ -634,6 +635,8 @@ ahci_setup_interrupt(device_t dev)
 	int i, msi = 1;
 
 	/* Process hints. */
+	if (ctlr->quirks & AHCI_Q_NOMSI)
+		msi = 0;
 	resource_int_value(device_get_name(dev),
 	    device_get_unit(dev), "msi", &msi);
 	if (msi < 0)
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
Comment 3 dfilter service freebsd_committer freebsd_triage 2013-01-31 20:47:43 UTC
Author: mav
Date: Thu Jan 31 20:47:35 2013
New Revision: 246156
URL: http://svnweb.freebsd.org/changeset/base/246156

Log:
  MFC r245875:
  Disable MSI interrupts for SB600 chipset.  According to the report they are
  not functional.
  
  PR:		kern/174880, kern/174985, kern/175002

Modified:
  stable/9/sys/dev/ahci/ahci.c
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/dev/   (props changed)

Modified: stable/9/sys/dev/ahci/ahci.c
==============================================================================
--- stable/9/sys/dev/ahci/ahci.c	Thu Jan 31 20:32:11 2013	(r246155)
+++ stable/9/sys/dev/ahci/ahci.c	Thu Jan 31 20:47:35 2013	(r246156)
@@ -120,8 +120,9 @@ static struct {
 #define AHCI_Q_NOAA	512
 #define AHCI_Q_NOCOUNT	1024
 #define AHCI_Q_ALTSIG	2048
+#define AHCI_Q_NOMSI	4096
 } ahci_ids[] = {
-	{0x43801002, 0x00, "ATI IXP600",	0},
+	{0x43801002, 0x00, "ATI IXP600",	AHCI_Q_NOMSI},
 	{0x43901002, 0x00, "ATI IXP700",	0},
 	{0x43911002, 0x00, "ATI IXP700",	0},
 	{0x43921002, 0x00, "ATI IXP700",	0},
@@ -638,6 +639,8 @@ ahci_setup_interrupt(device_t dev)
 	int i, msi = 1;
 
 	/* Process hints. */
+	if (ctlr->quirks & AHCI_Q_NOMSI)
+		msi = 0;
 	resource_int_value(device_get_name(dev),
 	    device_get_unit(dev), "msi", &msi);
 	if (msi < 0)
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
Comment 4 dfilter service freebsd_committer freebsd_triage 2013-01-31 20:49:09 UTC
Author: mav
Date: Thu Jan 31 20:48:56 2013
New Revision: 246157
URL: http://svnweb.freebsd.org/changeset/base/246157

Log:
  MFC r245875:
  Disable MSI interrupts for SB600 chipset.  According to the report they are
  not functional.
  
  PR:		kern/174880, kern/174985, kern/175002

Modified:
  stable/8/sys/dev/ahci/ahci.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/dev/   (props changed)
  stable/8/sys/dev/ahci/   (props changed)

Modified: stable/8/sys/dev/ahci/ahci.c
==============================================================================
--- stable/8/sys/dev/ahci/ahci.c	Thu Jan 31 20:47:35 2013	(r246156)
+++ stable/8/sys/dev/ahci/ahci.c	Thu Jan 31 20:48:56 2013	(r246157)
@@ -120,8 +120,9 @@ static struct {
 #define AHCI_Q_NOAA	512
 #define AHCI_Q_NOCOUNT	1024
 #define AHCI_Q_ALTSIG	2048
+#define AHCI_Q_NOMSI	4096
 } ahci_ids[] = {
-	{0x43801002, 0x00, "ATI IXP600",	0},
+	{0x43801002, 0x00, "ATI IXP600",	AHCI_Q_NOMSI},
 	{0x43901002, 0x00, "ATI IXP700",	0},
 	{0x43911002, 0x00, "ATI IXP700",	0},
 	{0x43921002, 0x00, "ATI IXP700",	0},
@@ -641,6 +642,8 @@ ahci_setup_interrupt(device_t dev)
 	int i, msi = 1;
 
 	/* Process hints. */
+	if (ctlr->quirks & AHCI_Q_NOMSI)
+		msi = 0;
 	resource_int_value(device_get_name(dev),
 	    device_get_unit(dev), "msi", &msi);
 	if (msi < 0)
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"