From 7c5409295cae978e6a89844de57f142a72e40a06 Mon Sep 17 00:00:00 2001 From: fvdl Date: Mon, 21 Apr 2003 16:52:07 +0000 Subject: [PATCH] Set/report DT a bit more correctly. --- sys/dev/ic/aic79xx_osm.c | 6 +++--- sys/dev/ic/aic7xxx_osm.c | 8 +++++--- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/sys/dev/ic/aic79xx_osm.c b/sys/dev/ic/aic79xx_osm.c index 2bd41d2ee69b..d1d1711e8850 100644 --- a/sys/dev/ic/aic79xx_osm.c +++ b/sys/dev/ic/aic79xx_osm.c @@ -1,4 +1,4 @@ -/* $NetBSD: aic79xx_osm.c,v 1.1 2003/04/21 00:14:52 fvdl Exp $ */ +/* $NetBSD: aic79xx_osm.c,v 1.2 2003/04/21 16:52:07 fvdl Exp $ */ /* * Bus independent NetBSD shim for the aic7xxx based adaptec SCSI controllers @@ -389,7 +389,7 @@ ahd_action(struct scsipi_channel *chan, scsipi_adapter_req_t req, void *arg) } else first = 0; - if (xm->xm_mode & PERIPH_CAP_WIDE16) + if (xm->xm_mode & (PERIPH_CAP_WIDE16 | PERIPH_CAP_DT)) width = MSG_EXT_WDTR_BUS_16_BIT; else width = MSG_EXT_WDTR_BUS_8_BIT; @@ -399,7 +399,7 @@ ahd_action(struct scsipi_channel *chan, scsipi_adapter_req_t req, void *arg) width = tinfo->user.width; tinfo->goal.width = width; - if (!(xm->xm_mode & PERIPH_CAP_SYNC)) { + if (!(xm->xm_mode & (PERIPH_CAP_SYNC | PERIPH_CAP_DT))) { tinfo->goal.period = 0; tinfo->goal.offset = 0; tinfo->goal.ppr_options = 0; diff --git a/sys/dev/ic/aic7xxx_osm.c b/sys/dev/ic/aic7xxx_osm.c index a7bd357e3cec..7a2a43651b48 100644 --- a/sys/dev/ic/aic7xxx_osm.c +++ b/sys/dev/ic/aic7xxx_osm.c @@ -1,4 +1,4 @@ -/* $NetBSD: aic7xxx_osm.c,v 1.5 2003/04/20 21:25:59 fvdl Exp $ */ +/* $NetBSD: aic7xxx_osm.c,v 1.6 2003/04/21 16:52:07 fvdl Exp $ */ /* * Bus independent FreeBSD shim for the aic7xxx based adaptec SCSI controllers @@ -371,7 +371,7 @@ ahc_action(struct scsipi_channel *chan, scsipi_adapter_req_t req, void *arg) } else first = 0; - if (xm->xm_mode & PERIPH_CAP_WIDE16) + if (xm->xm_mode & (PERIPH_CAP_WIDE16 | PERIPH_CAP_DT)) width = MSG_EXT_WDTR_BUS_16_BIT; else width = MSG_EXT_WDTR_BUS_8_BIT; @@ -381,7 +381,7 @@ ahc_action(struct scsipi_channel *chan, scsipi_adapter_req_t req, void *arg) width = tinfo->user.width; tinfo->goal.width = width; - if (!(xm->xm_mode & PERIPH_CAP_SYNC)) { + if (!(xm->xm_mode & (PERIPH_CAP_SYNC | PERIPH_CAP_DT))) { tinfo->goal.period = 0; tinfo->goal.offset = 0; tinfo->goal.ppr_options = 0; @@ -1045,6 +1045,8 @@ ahc_send_async(struct ahc_softc *ahc, char channel, u_int target, u_int lun, xm.xm_mode |= PERIPH_CAP_SYNC; if (tstate->tagenable & devinfo.target_mask) xm.xm_mode |= PERIPH_CAP_TQING; + if (tinfo->curr.ppr_options & MSG_EXT_PPR_DT_REQ) + xm.xm_mode |= PERIPH_CAP_DT; scsipi_async_event(chan, ASYNC_EVENT_XFER_MODE, &xm); break; case AC_BUS_RESET: