NetBSD-Bugs archive

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

kern/38011: sata disks not found on Nvidia MCP55/viaide3: couldn't map sata regs



>Number:         38011
>Category:       kern
>Synopsis:       sata disks not found on Nvidia MCP55/viaide3: couldn't map 
>sata regs
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Tue Feb 12 11:55:00 +0000 2008
>Originator:     Kurt Schreiner
>Release:        -current as of 2008-02-12
>Organization:
Uni Mainz
>Environment:
uname -a
NetBSD ibetty 4.99.54 NetBSD 4.99.54 (ULTRA40) #13: Tue Feb 12 10:42:07 MET 
2008  ks@ibetty:/u/NetBSD/arch/amd64/obj/sys/arch/amd64/compile/ULTRA40 amd64

>Description:
>From dmesg:

viaide3 at pci8 dev 5 function 0
viaide3: NVIDIA MCP55 Serial ATA Controller (rev. 0xa3)
viaide3: couldn't map sata regs
viaide4 at pci8 dev 5 function 1
viaide4: NVIDIA MCP55 Serial ATA Controller (rev. 0xa3)
viaide4: couldn't map sata regs

and none of the 4 disks is found..,

after applying the patch below I get:

viaide3 at pci8 dev 5 function 0
viaide3: NVIDIA MCP55 Serial ATA Controller (rev. 0xa3)
viaide3: using ioapic1 pin 16 (irq 11) for native-PCI interrupt
atabus5 at viaide3 channel 0
atabus6 at viaide3 channel 1
viaide4 at pci8 dev 5 function 1
viaide4: NVIDIA MCP55 Serial ATA Controller (rev. 0xa3)
viaide4: using ioapic1 pin 17 (irq 10) for native-PCI interrupt
atabus7 at viaide4 channel 0
atabus8 at viaide4 channel 1
[...]viaide3 port 0: device present, speed: 3.0Gb/s
viaide4 port 0: device present, speed: 3.0Gb/s
viaide3 port 1: device present, speed: 3.0Gb/s
viaide4 port 1: device present, speed: 3.0Gb/s
wd0 at atabus5 drive 0: <SEAGATE ST32500NSSUN250G 0740B568NH>
wd0: 232 GB, 484514 cyl, 16 head, 63 sec, 512 bytes/sect x 488390625 sectors
wd1 at atabus6 drive 0: <SEAGATE ST32500NSSUN250G 0741B58XWL>
wd1: 232 GB, 484514 cyl, 16 head, 63 sec, 512 bytes/sect x 488390625 sectors
wd2 at atabus7 drive 0: <SEAGATE ST32500NSSUN250G 0741B58YZ6>
wd2: 232 GB, 484514 cyl, 16 head, 63 sec, 512 bytes/sect x 488390625 sectors
wd3 at atabus8 drive 0: <SEAGATE ST32500NSSUN250G 0740B568QJ>
wd3: 232 GB, 484514 cyl, 16 head, 63 sec, 512 bytes/sect x 488390625 sectors




after applying the patch below I get:

>How-To-Repeat:
Take a Sun Ultra40 M2 and try to use SATA-disks in the upper 4-disk bay.
>Fix:
cvs diff -u sys/dev/pci/viaide.c 
Index: sys/dev/pci/viaide.c
===================================================================
RCS file: /cvsroot/src/sys/dev/pci/viaide.c,v
retrieving revision 1.51
diff -u -r1.51 viaide.c
--- sys/dev/pci/viaide.c        18 Jan 2008 01:33:40 -0000      1.51
+++ sys/dev/pci/viaide.c        12 Feb 2008 11:41:22 -0000
@@ -837,6 +837,21 @@
        pciide_mapreg_dma(sc, pa);
        aprint_verbose("\n");
 
+       /*
+        * enable memory-space access. sometimes memory space is
+        * _not_ enabled so "just do it" to get things going!
+        */
+       {
+       pcireg_t csr;
+       if (pa->pa_memt) {
+           pa->pa_flags |= PCI_FLAGS_MEM_ENABLED;
+           sc->sc_ba5_st = pa->pa_memt;
+       }
+       csr = pci_conf_read(pa->pa_pc, pa->pa_tag, PCI_COMMAND_STATUS_REG);
+       pci_conf_write(pa->pa_pc, pa->pa_tag, PCI_COMMAND_STATUS_REG,
+           csr | PCI_COMMAND_MEM_ENABLE);
+       }
+
        if (sc->sc_dma_ok) {
                sc->sc_wdcdev.sc_atac.atac_cap |= ATAC_CAP_UDMA | ATAC_CAP_DMA;
                sc->sc_wdcdev.irqack = pciide_irqack;



Home | Main Index | Thread Index | Old Index