Program the 53c96's interrupt routing info into the VIA before doing

anything that might cause an interrupt (e.g. the SCSI bus reset in
ncr53c9x_attach()).  If we don't do this, the initial interrupt is
lost, thus causing the state machine to never enter IDLE state, thus
causing SCSI commands to never be executed.

Fixes kern/8544, reported by Erik Bertelsen <erik@mediator.uni-c.dk>.
This commit is contained in:
thorpej 1999-10-19 17:00:41 +00:00
parent 78cc55b359
commit d3c33c1744
1 changed files with 8 additions and 8 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: esp.c,v 1.23 1999/06/27 23:43:37 briggs Exp $ */
/* $NetBSD: esp.c,v 1.24 1999/10/19 17:00:41 thorpej Exp $ */
/*
* Copyright (c) 1997 Jason R. Thorpe.
@ -306,13 +306,6 @@ espattach(parent, self, aux)
/* Really no limit, but since we want to fit into the TCR... */
sc->sc_maxxfer = 8 * 1024; /*64 * 1024; XXX */
/*
* Now try to attach all the sub-devices
*/
sc->sc_adapter.scsipi_cmd = ncr53c9x_scsi_cmd;
sc->sc_adapter.scsipi_minphys = minphys;
ncr53c9x_attach(sc, &esp_dev);
/*
* Configure interrupts.
*/
@ -321,6 +314,13 @@ espattach(parent, self, aux)
via2_reg(vIFR) = esc->irq_mask;
via2_reg(vIER) = 0x80 | esc->irq_mask;
}
/*
* Now try to attach all the sub-devices
*/
sc->sc_adapter.scsipi_cmd = ncr53c9x_scsi_cmd;
sc->sc_adapter.scsipi_minphys = minphys;
ncr53c9x_attach(sc, &esp_dev);
}
/*