Re: BETA4 installer doesn't attach my HDD controller; BETA3 did

From: Andrey V. Elsukov <bu7cher_at_yandex.ru>
Date: Fri, 07 Dec 2007 10:53:56 +0300
Todd Wasson wrote:
>> Todd Wasson wrote:
>>> I've got a Maxtor 6Y080L0 YAR41VW0 drive on a JMicron JMB368 UDMA133
>>> controller, and in the BETA4 installer the controller doesn't seem to
>>> be properly attaching, which leads to the drive not being found.  The
>>> relevant sections from dmesg (as I'm not sure where else to look while
>>> running the installer CD) are:
>>
>> Did you try "Safe Boot" key 3.

I think this changes may create a regression:

1. the BETA3's version:

         ctlr->r_type2 = SYS_RES_MEMORY;
         ctlr->r_rid2 = PCIR_BAR(5);
         if ((ctlr->r_res2 = bus_alloc_resource_any(dev, ctlr->r_type2,
                                           &ctlr->r_rid2, RF_ACTIVE))){
             if ((error = ata_ahci_chipinit(dev)))
                 return error;
         }
We have two checks here. Probably your controller doesn't allocate a
memory resource for the AHCI, but it works because it skips second
checks.

2. the BETA4's version:

         if ((error = ata_ahci_chipinit(dev)))
             return error;

In this version driver doesn't pass it. I've already sent patch
for test to your PR, but i attach it again.
May be Soren can comment it?

-- 
WBR, Andrey V. Elsukov

--- src/sys/dev/ata/ata-chipset.c	2007-11-22 00:15:00.000000000 +0300
+++ src/sys/dev/ata/ata-chipset.c	2007-12-07 10:07:21.000000000 +0300
_at__at_ -2243,7 +2243,7 _at__at_ ata_jmicron_chipinit(device_t dev)
 	return ENXIO;
 
     /* do we have multiple PCI functions ? */
-    if (pci_read_config(dev, 0xdf, 1) & 0x40) {
+    if ((pci_read_config(dev, 0xdf, 1) & 0x40) || ctlr->chip->cfg1 == 0) {
 	/* are we on the AHCI part ? */
 	if (ata_ahci_chipinit(dev) != ENXIO)
 	    return 0;
Received on Fri Dec 07 2007 - 06:54:05 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:23 UTC