diff options
author | gibbs <gibbs@FreeBSD.org> | 1999-03-05 23:37:07 +0000 |
---|---|---|
committer | gibbs <gibbs@FreeBSD.org> | 1999-03-05 23:37:07 +0000 |
commit | c7f60ce1412423b912c54cac7b6077b6bf057f99 (patch) | |
tree | 2e13f27fcdbb9773275f4f3bcc6ca2059ee30d38 /sys/i386 | |
parent | 399fca227c07db6ebbd4f852a6c928eb69d23ad1 (diff) | |
download | FreeBSD-src-c7f60ce1412423b912c54cac7b6077b6bf057f99.zip FreeBSD-src-c7f60ce1412423b912c54cac7b6077b6bf057f99.tar.gz |
Poll for bus reset completion instead of assuming that our interrupt
is enabled.
Diffstat (limited to 'sys/i386')
-rw-r--r-- | sys/i386/eisa/ahb.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/i386/eisa/ahb.c b/sys/i386/eisa/ahb.c index 21edd2e..f86e82e 100644 --- a/sys/i386/eisa/ahb.c +++ b/sys/i386/eisa/ahb.c @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: ahb.c,v 1.5 1999/01/28 01:33:02 dillon Exp $ + * $Id: ahb.c,v 1.6 1999/01/28 03:30:02 gibbs Exp $ */ #include "eisa.h" @@ -1160,12 +1160,17 @@ ahbaction(struct cam_sim *sim, union ccb *ccb) case XPT_RESET_DEV: /* Bus Device Reset the specified SCSI device */ { int i; + int s; + s = splcam(); ahb->immed_cmd = IMMED_RESET; ahbqueuembox(ahb, IMMED_RESET, ATTN_IMMED|ccb->ccb_h.target_id); /* Poll for interrupt completion */ - for (i = 1000; ahb->immed_cmd != 0 && i != 0; i--) + for (i = 1000; ahb->immed_cmd != 0 && i != 0; i--) { DELAY(1000); + ahbintr(cam_sim_softc(sim)); + } + splx(s); break; } case XPT_CALC_GEOMETRY: |