diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2006-12-10 16:15:38 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2006-12-10 16:15:38 +0000 |
commit | 96ec28030eb63b58b9fe231a1097535ce2043f22 (patch) | |
tree | 3ad2e8f29d716ace821b113545013cc6a8a33ad3 /sys | |
parent | 00837375957866052a8f7727039f2edb1371f432 (diff) |
Do not attempt to access scsi_xfer fields after scsi_done() has been invoked.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/ic/ncr5380sbc.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/dev/ic/ncr5380sbc.c b/sys/dev/ic/ncr5380sbc.c index b6afc0239d0..66ec5b0b6c3 100644 --- a/sys/dev/ic/ncr5380sbc.c +++ b/sys/dev/ic/ncr5380sbc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ncr5380sbc.c,v 1.18 2005/11/12 20:29:45 brad Exp $ */ +/* $OpenBSD: ncr5380sbc.c,v 1.19 2006/12/10 16:15:37 miod Exp $ */ /* $NetBSD: ncr5380sbc.c,v 1.13 1996/10/13 01:37:25 christos Exp $ */ /* @@ -671,9 +671,11 @@ new: } if (flags & SCSI_POLL) { +#ifdef DIAGNOSTIC /* Make sure ncr5380_sched() finished it. */ - if ((xs->flags & ITSDONE) == 0) + if (sc->sc_state != NCR_IDLE) panic("ncr5380_scsi_cmd: poll didn't finish"); +#endif rv = COMPLETE; } @@ -882,7 +884,7 @@ next_job: /* Another hack (Er.. hook!) for the sun3 si: */ if (sc->sc_intr_on) { NCR_TRACE("sched: ret, intr ON\n", 0); - sc->sc_intr_on(sc); + sc->sc_intr_on(sc); } return; /* No more work to do. */ |