tech-kern archive

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

Re: ataraid(4) controllers with AHCI



In article <20080209124520.a5f1af50.juan%xtrarom.org@localhost>,
Juan RP  <juan%xtrarom.org@localhost> wrote:
>Hi,
>
>I'm adding support for the JMicron and Intel Matrix RAID metadata formats
>to the ataraid(4) driver and I got both attaching and working with
>the character device (when I use the block device the system hungs
>and I'm not able to debug it)... back to the issue, to detect the drives
>on the controllers while it's in RAID mode through AHCI, I had to make the 
>following changes:
>
>Index: dev/ic/ahcisata_core.c
>===================================================================
>RCS file: /cvsroot/src/sys/dev/ic/ahcisata_core.c,v
>retrieving revision 1.11
>diff -b -u -p -r1.11 ahcisata_core.c
>--- dev/ic/ahcisata_core.c     25 Jan 2008 21:41:48 -0000      1.11
>+++ dev/ic/ahcisata_core.c     9 Feb 2008 11:36:30 -0000
>@@ -245,7 +245,8 @@ ahci_attach(struct ahci_softc *sc)
>       aprint_normal(", %d ports, %d command slots, features 0x%x\n",
>           sc->sc_atac.atac_nchannels, sc->sc_ncmds,
>           ahci_cap & ~(AHCI_CAP_NPMASK|AHCI_CAP_NCS));
>-      sc->sc_atac.atac_cap = ATAC_CAP_DATA16 | ATAC_CAP_DMA | ATAC_CAP_UDMA;
>+      sc->sc_atac.atac_cap |= ATAC_CAP_DATA16 | ATAC_CAP_DMA | ATAC_CAP_UDMA;
>+      sc->sc_atac.atac_cap |= sc->sc_atac_capflags;

The first |= might be wrong; is atac_cap initialized?

christos




Home | Main Index | Thread Index | Old Index