Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 10 Jan 2010 01:50:45 +0200
From:      Alexander Motin <mav@FreeBSD.org>
To:        Abdullah Ibn Hamad Al-Marri <wearabnet@yahoo.ca>
Cc:        FreeBSD STABLE <freebsd-stable@freebsd.org>, FreeBSD Questions <freebsd-questions@freebsd.org>
Subject:   Re: FreeBSD 8.0 STABLE sata regression
Message-ID:  <4B491655.5020103@FreeBSD.org>
In-Reply-To: <268178.64598.qm@web111315.mail.gq1.yahoo.com>
References:  <1263046981.00204595.1263034801@10.7.7.3> <4B4892DA.1060305@FreeBSD.org> <268178.64598.qm@web111315.mail.gq1.yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------040307070800060508070806
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

Abdullah Ibn Hamad Al-Marri wrote:
>> Abdullah Ibn Hamad Al-Marri wrote:
>>> My servers are alright with FreeBSD 8.0-RELEASE, but not with -STABLE.
>>>
>>> FreeBSD NOC.WEArab.Net 8.0-STABLE FreeBSD 8.0-STABLE #0: Fri Jan  8 18:26:13 
>> UTC 2010    admin@localhost.localdomain:/usr/obj/usr/src/sys/GENERIC  amd64
>>> atapci0: port 
>> 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0x20a0-0x20af mem 0x90200000-0x902003ff irq 
>> 19 at device 31.2 on pci0
>>> ata0: on atapci0
>>> ata0: [ITHREAD]
>>> ata1: on atapci0
>>> ata1: [ITHREAD]
>>>
>>> when I upgraded to FreeBSD 8.0-STABLE it got many issues.
>>>
>>> ad2: 381554MB at ata1-master UDMA100 
>> If UDMA mode reported instead of SATA speed is the only issue, then it
>> is not an issue, but only a cosmetic change. It doesn't mean that your
>> drives will work slower.
>>
>> Thanks for report, I'll plug ICH7 board a bit later to check this.
>> To get more info about the problem, try `atacontrol mode ad2` command.
> 
> Here is the result,
> 
> VB# atacontrol mode ad4
> current mode = UDMA100 
> VB# atacontrol mode ad6
> current mode = UDMA100 
> VB# 

OK. I have attached my ICH7 board and found where is the problem. This
chipset doesn't provide access to SATA control registers. As result,
driver can't get SATA connection info and so doesn't report it. If you
wish, you can restore previous behavior by applying attached patch. Here
is what I have with it:

%atacontrol mode ad0
current mode = UDMA100
%atacontrol mode ad4
current mode = UDMA100 SATA 1.5Gb/s
%atacontrol mode ad5
current mode = UDMA100 SATA 1.5Gb/s
%atacontrol mode ad6
current mode = UDMA100 SATA 1.5Gb/s
%atacontrol mode ad7
current mode = UDMA100 SATA 1.5Gb/s

But as I have said before, it is only a cosmetics.

-- 
Alexander Motin

--------------040307070800060508070806
Content-Type: text/plain;
 name="ugly.sata.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="ugly.sata.patch"

--- ata-pci.c.prev	2010-01-10 01:25:45.000000000 +0200
+++ ata-pci.c	2010-01-10 01:25:49.000000000 +0200
@@ -714,9 +714,12 @@ static int
 ata_pcichannel_getrev(device_t dev, int target)
 {
 	struct ata_pci_controller *ctlr = device_get_softc(device_get_parent(dev));
+	struct ata_channel *ch = device_get_softc(dev);
 
 	if (ctlr->getrev)
 		return (ctlr->getrev(dev, target));
+	else if (ch->flags & ATA_SATA)
+		return (1);
 	else
 		return (0);
 }

--------------040307070800060508070806--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4B491655.5020103>