Subject: Re: Booting a Compaq ProLiant ML370
To: Mark Davies <mark@MCS.VUW.AC.NZ>
From: Andrew Doran <ad@netbsd.org>
List: current-users
Date: 01/09/2001 14:56:54
Mark Davies <mark@MCS.VUW.AC.NZ> wrote:
> Thanks for that, it now gets a little further but not all the way:
>
> cac0 at pci1 dev 3 function 0: Compaq Smart Array 431
> cac0: interrupting at irq 10
> cac0: CAC_CMD_GET_CTRL_INFO failed.
>
> any further suggestions?
Try this patch in a addition:
Index: cac_pci.c
===================================================================
RCS file: /cvsroot/syssrc/sys/dev/pci/cac_pci.c,v
retrieving revision 1.9
diff -u -r1.9 cac_pci.c
--- dev/pci/cac_pci.c 2000/12/28 22:59:11 1.9
+++ dev/pci/cac_pci.c 2001/01/09 14:52:28
@@ -236,8 +260,7 @@
cac_pci_l0_intr_pending(struct cac_softc *sc)
{
- return (cac_inl(sc, CAC_42REG_INTR_PENDING) &
- cac_inl(sc, CAC_42REG_STATUS));
+ return ((cac_inl(sc, CAC_42REG_STATUS) & CAC_42_EXTINT) != 0);
}
static void
@@ -251,5 +274,5 @@
cac_pci_l0_fifo_full(struct cac_softc *sc)
{
- return (~cac_inl(sc, CAC_42REG_CMD_FIFO));
+ return (cac_inl(sc, CAC_42REG_CMD_FIFO) != 0);
}
Index: cac.c
===================================================================
RCS file: /cvsroot/syssrc/sys/dev/ic/cac.c,v
retrieving revision 1.16
diff -u -r1.16 cac.c
--- dev/ic/cac.c 2000/12/11 13:19:50 1.16
+++ dev/ic/cac.c 2001/01/09 14:52:51
@@ -327,6 +327,7 @@
/* Synchronous commands musn't wait. */
if ((*sc->sc_cl->cl_fifo_full)(sc)) {
+ printf("ZZZ: fifo full\n");
cac_ccb_free(sc, ccb);
rv = -1;
} else {
@@ -334,6 +335,7 @@
ccb->ccb_flags |= CAC_CCB_ACTIVE;
#endif
(*sc->sc_cl->cl_submit)(sc, ccb);
+ printf("ZZZ: %p CCB submitted\n", ccb);
rv = cac_ccb_poll(sc, ccb, 2000);
cac_ccb_free(sc, ccb);
}
@@ -359,8 +361,10 @@
do {
for (; timo != 0; timo--) {
- if ((ccb = (*sc->sc_cl->cl_completed)(sc)) != NULL)
+ if ((ccb = (*sc->sc_cl->cl_completed)(sc)) != NULL) {
+ printf("ZZZ: %p CCB completed\n", ccb);
break;
+ }
DELAY(100);
}
Index: cacreg.h
===================================================================
RCS file: /cvsroot/syssrc/sys/dev/ic/cacreg.h,v
retrieving revision 1.4
diff -u -r1.4 cacreg.h
--- dev/ic/cacreg.h 2000/09/01 12:10:21 1.4
+++ dev/ic/cacreg.h 2001/01/09 14:54:07
@@ -76,7 +76,8 @@
#define CAC_42REG_DONE_FIFO 0x44
#define CAC_42REG_INTR_MASK 0x34
#define CAC_42REG_STATUS 0x30
-#define CAC_42REG_INTR_PENDING 0x08
+
+#define CAC_42_EXTINT 0x08
#define CAC_EISAREG_INTR_MASK 0x01
#define CAC_EISAREG_LOCAL_MASK 0x04