diff options
| author | thorpej <thorpej@NetBSD.org> | 2001-03-07 23:07:12 +0000 |
|---|---|---|
| committer | thorpej <thorpej@NetBSD.org> | 2001-03-07 23:07:12 +0000 |
| commit | fd7ed72be10effbaa920ca7dfd19c8388549e759 (patch) | |
| tree | cb13e61dbcaaef1eddebe05d1a4c853ad241498d /sys | |
| parent | 4e453153779dbc6890aba3b910f00dc2c69c601a (diff) | |
Add BUS_DMA_STREAMING to data transfer maps.
Diffstat (limited to 'sys')
| -rw-r--r-- | sys/dev/ic/adv.c | 16 | ||||
| -rw-r--r-- | sys/dev/ic/adw.c | 18 | ||||
| -rw-r--r-- | sys/dev/ic/aha.c | 10 | ||||
| -rw-r--r-- | sys/dev/ic/aic7xxx.c | 7 | ||||
| -rw-r--r-- | sys/dev/ic/bha.c | 10 | ||||
| -rw-r--r-- | sys/dev/ic/cac.c | 5 | ||||
| -rw-r--r-- | sys/dev/ic/dpt.c | 14 | ||||
| -rw-r--r-- | sys/dev/ic/mlx.c | 4 | ||||
| -rw-r--r-- | sys/dev/ic/siop.c | 5 | ||||
| -rw-r--r-- | sys/dev/ic/uha.c | 10 | ||||
| -rw-r--r-- | sys/dev/pci/isp_pci.c | 6 | ||||
| -rw-r--r-- | sys/dev/pci/twe.c | 4 |
12 files changed, 58 insertions, 51 deletions
diff --git a/sys/dev/ic/adv.c b/sys/dev/ic/adv.c index eb8a481b7d5..f55f341f455 100644 --- a/sys/dev/ic/adv.c +++ b/sys/dev/ic/adv.c @@ -1,4 +1,4 @@ -/* $NetBSD: adv.c,v 1.20 2000/11/14 18:21:00 thorpej Exp $ */ +/* $NetBSD: adv.c,v 1.21 2001/03/07 23:07:12 thorpej Exp $ */ /* * Generic driver for the Advanced Systems Inc. Narrow SCSI controllers @@ -675,15 +675,17 @@ adv_scsi_cmd(xs) */ #ifdef TFS if (flags & SCSI_DATA_UIO) { - error = bus_dmamap_load_uio(dmat, - ccb->dmamap_xfer, (struct uio *) xs->data, - (flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : BUS_DMA_WAITOK); + error = bus_dmamap_load_uio(dmat, ccb->dmamap_xfer, + (struct uio *) xs->data, + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } else #endif /* TFS */ { - error = bus_dmamap_load(dmat, - ccb->dmamap_xfer, xs->data, xs->datalen, NULL, - (flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : BUS_DMA_WAITOK); + error = bus_dmamap_load(dmat, ccb->dmamap_xfer, + xs->data, xs->datalen, NULL, + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } if (error) { diff --git a/sys/dev/ic/adw.c b/sys/dev/ic/adw.c index f50fc1faf5c..26067d534f0 100644 --- a/sys/dev/ic/adw.c +++ b/sys/dev/ic/adw.c @@ -1,4 +1,4 @@ -/* $NetBSD: adw.c,v 1.27 2001/02/11 23:40:03 hpeyerl Exp $ */ +/* $NetBSD: adw.c,v 1.28 2001/03/07 23:07:13 thorpej Exp $ */ /* * Generic driver for the Advanced Systems Inc. SCSI controllers @@ -784,17 +784,17 @@ adw_build_req(xs, ccb, flags) */ #ifdef TFS if (xs->xs_control & SCSI_DATA_UIO) { - error = bus_dmamap_load_uio(dmat, - ccb->dmamap_xfer, (struct uio *) xs->data, - (flags & XS_CTL_NOSLEEP) ? - BUS_DMA_NOWAIT : BUS_DMA_WAITOK); + error = bus_dmamap_load_uio(dmat, ccb->dmamap_xfer, + (struct uio *) xs->data, + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } else #endif /* TFS */ { - error = bus_dmamap_load(dmat, - ccb->dmamap_xfer, xs->data, xs->datalen, NULL, - (flags & XS_CTL_NOSLEEP) ? - BUS_DMA_NOWAIT : BUS_DMA_WAITOK); + error = bus_dmamap_load(dmat, ccb->dmamap_xfer, + xs->data, xs->datalen, NULL, + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } if (error) { diff --git a/sys/dev/ic/aha.c b/sys/dev/ic/aha.c index 6b013b0c790..8d7c91903fb 100644 --- a/sys/dev/ic/aha.c +++ b/sys/dev/ic/aha.c @@ -1,4 +1,4 @@ -/* $NetBSD: aha.c,v 1.29 2000/11/14 18:21:00 thorpej Exp $ */ +/* $NetBSD: aha.c,v 1.30 2001/03/07 23:07:13 thorpej Exp $ */ #include "opt_ddb.h" @@ -1287,15 +1287,15 @@ aha_scsi_cmd(xs) if (flags & XS_CTL_DATA_UIO) { error = bus_dmamap_load_uio(dmat, ccb->dmamap_xfer, (struct uio *)xs->data, - (flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : - BUS_DMA_WAITOK); + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } else #endif { error = bus_dmamap_load(dmat, ccb->dmamap_xfer, xs->data, xs->datalen, NULL, - (flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : - BUS_DMA_WAITOK); + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } if (error) { diff --git a/sys/dev/ic/aic7xxx.c b/sys/dev/ic/aic7xxx.c index 162e3e5265c..d05a0e27f86 100644 --- a/sys/dev/ic/aic7xxx.c +++ b/sys/dev/ic/aic7xxx.c @@ -1,4 +1,4 @@ -/* $NetBSD: aic7xxx.c,v 1.66 2001/02/24 00:01:22 cgd Exp $ */ +/* $NetBSD: aic7xxx.c,v 1.67 2001/03/07 23:07:13 thorpej Exp $ */ /* * Generic driver for the aic7xxx based adaptec SCSI controllers @@ -4262,8 +4262,9 @@ ahc_setup_data(struct ahc_softc *ahc, struct scsipi_xfer *xs, error = bus_dmamap_load(ahc->parent_dmat, scb->dmamap, xs->data, xs->datalen, NULL, - (xs->xs_control & XS_CTL_NOSLEEP) ? - BUS_DMA_NOWAIT : BUS_DMA_WAITOK); + ((xs->xs_control & XS_CTL_NOSLEEP) ? + BUS_DMA_NOWAIT : BUS_DMA_WAITOK) | + BUS_DMA_STREAMING); if (error) { if (!ahc_istagged_device(ahc, xs, 0)) ahc_index_busy_tcl(ahc, hscb->tcl, TRUE); diff --git a/sys/dev/ic/bha.c b/sys/dev/ic/bha.c index b190c6c48ef..ca9cd31c016 100644 --- a/sys/dev/ic/bha.c +++ b/sys/dev/ic/bha.c @@ -1,4 +1,4 @@ -/* $NetBSD: bha.c,v 1.40 2000/11/21 05:23:37 soren Exp $ */ +/* $NetBSD: bha.c,v 1.41 2001/03/07 23:07:14 thorpej Exp $ */ #include "opt_ddb.h" #undef BHADIAG @@ -1400,15 +1400,15 @@ bha_scsi_cmd(xs) if (flags & XS_CTL_DATA_UIO) { error = bus_dmamap_load_uio(dmat, ccb->dmamap_xfer, (struct uio *)xs->data, - (flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : - BUS_DMA_WAITOK); + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } else #endif /* TFS */ { error = bus_dmamap_load(dmat, ccb->dmamap_xfer, xs->data, xs->datalen, NULL, - (flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : - BUS_DMA_WAITOK); + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } if (error) { diff --git a/sys/dev/ic/cac.c b/sys/dev/ic/cac.c index 7066cb9d96f..b4a56371d63 100644 --- a/sys/dev/ic/cac.c +++ b/sys/dev/ic/cac.c @@ -1,4 +1,4 @@ -/* $NetBSD: cac.c,v 1.16 2000/12/11 13:19:50 ad Exp $ */ +/* $NetBSD: cac.c,v 1.17 2001/03/07 23:07:15 thorpej Exp $ */ /*- * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -288,7 +288,8 @@ cac_cmd(struct cac_softc *sc, int command, void *data, int datasize, if ((flags & (CAC_CCB_DATA_IN | CAC_CCB_DATA_OUT)) != 0) { bus_dmamap_load(sc->sc_dmat, ccb->ccb_dmamap_xfer, - (void *)data, datasize, NULL, BUS_DMA_NOWAIT); + (void *)data, datasize, NULL, BUS_DMA_NOWAIT | + BUS_DMA_STREAMING); bus_dmamap_sync(sc->sc_dmat, ccb->ccb_dmamap_xfer, 0, datasize, (flags & CAC_CCB_DATA_IN) != 0 ? BUS_DMASYNC_PREREAD : diff --git a/sys/dev/ic/dpt.c b/sys/dev/ic/dpt.c index 5579fa2f807..9553d1ab5f4 100644 --- a/sys/dev/ic/dpt.c +++ b/sys/dev/ic/dpt.c @@ -1,4 +1,4 @@ -/* $NetBSD: dpt.c,v 1.25 2001/02/24 00:03:12 cgd Exp $ */ +/* $NetBSD: dpt.c,v 1.26 2001/03/07 23:07:15 thorpej Exp $ */ /*- * Copyright (c) 1997, 1998, 1999, 2000 The NetBSD Foundation, Inc. @@ -55,7 +55,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: dpt.c,v 1.25 2001/02/24 00:03:12 cgd Exp $"); +__KERNEL_RCSID(0, "$NetBSD: dpt.c,v 1.26 2001/03/07 23:07:15 thorpej Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -902,14 +902,16 @@ dpt_scsi_cmd(xs) #ifdef TFS if ((flags & XS_CTL_DATA_UIO) != 0) { error = bus_dmamap_load_uio(dmat, xfer, - (struct uio *)xs->data, (flags & XS_CTL_NOSLEEP) ? - BUS_DMA_NOWAIT : BUS_DMA_WAITOK); + (struct uio *)xs->data, ((flags & XS_CTL_NOSLEEP) ? + BUS_DMA_NOWAIT : BUS_DMA_WAITOK) | + BUS_DMA_STREAMING); } else #endif /* TFS */ { error = bus_dmamap_load(dmat, xfer, xs->data, - xs->datalen, NULL, (flags & XS_CTL_NOSLEEP) ? - BUS_DMA_NOWAIT : BUS_DMA_WAITOK); + xs->datalen, NULL, ((flags & XS_CTL_NOSLEEP) ? + BUS_DMA_NOWAIT : BUS_DMA_WAITOK) | + BUS_DMA_STREAMING); } if (error) { diff --git a/sys/dev/ic/mlx.c b/sys/dev/ic/mlx.c index fc76fc60911..b8b53b15bc5 100644 --- a/sys/dev/ic/mlx.c +++ b/sys/dev/ic/mlx.c @@ -1,4 +1,4 @@ -/* $NetBSD: mlx.c,v 1.4 2001/02/12 19:04:35 ad Exp $ */ +/* $NetBSD: mlx.c,v 1.5 2001/03/07 23:07:15 thorpej Exp $ */ /*- * Copyright (c) 2001 The NetBSD Foundation, Inc. @@ -1872,7 +1872,7 @@ mlx_ccb_map(struct mlx_softc *mlx, struct mlx_ccb *mc, void *data, int size, xfer = mc->mc_xfer_map; rv = bus_dmamap_load(mlx->mlx_dmat, xfer, data, size, NULL, - BUS_DMA_NOWAIT); + BUS_DMA_NOWAIT | BUS_DMA_STREAMING); if (rv != 0) return (rv); diff --git a/sys/dev/ic/siop.c b/sys/dev/ic/siop.c index 8579b74c7cd..dfd10dae617 100644 --- a/sys/dev/ic/siop.c +++ b/sys/dev/ic/siop.c @@ -1,4 +1,4 @@ -/* $NetBSD: siop.c,v 1.40 2001/03/01 22:10:57 thorpej Exp $ */ +/* $NetBSD: siop.c,v 1.41 2001/03/07 23:07:15 thorpej Exp $ */ /* * Copyright (c) 2000 Manuel Bouyer. @@ -1331,7 +1331,8 @@ siop_scsicmd(xs) } if (xs->xs_control & (XS_CTL_DATA_IN | XS_CTL_DATA_OUT)) { error = bus_dmamap_load(sc->sc_dmat, siop_cmd->dmamap_data, - xs->data, xs->datalen, NULL, BUS_DMA_NOWAIT); + xs->data, xs->datalen, NULL, BUS_DMA_NOWAIT | + BUS_DMA_STREAMING); if (error) { printf("%s: unable to load data DMA map: %d\n", sc->sc_dev.dv_xname, error); diff --git a/sys/dev/ic/uha.c b/sys/dev/ic/uha.c index 5e1067e9a28..65cfb1c923b 100644 --- a/sys/dev/ic/uha.c +++ b/sys/dev/ic/uha.c @@ -1,4 +1,4 @@ -/* $NetBSD: uha.c,v 1.24 2000/11/14 18:21:02 thorpej Exp $ */ +/* $NetBSD: uha.c,v 1.25 2001/03/07 23:07:15 thorpej Exp $ */ #undef UHADEBUG #ifdef DDB @@ -576,15 +576,15 @@ uha_scsi_cmd(xs) if (flags & SCSI_DATA_UIO) { error = bus_dmamap_load_uio(dmat, mscp->dmamap_xfer, (struct uio *)xs->data, - (flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : - BUS_DMA_WAITOK); + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } else #endif /*TFS */ { error = bus_dmamap_load(dmat, mscp->dmamap_xfer, xs->data, xs->datalen, NULL, - (flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : - BUS_DMA_WAITOK); + ((flags & XS_CTL_NOSLEEP) ? BUS_DMA_NOWAIT : + BUS_DMA_WAITOK) | BUS_DMA_STREAMING); } if (error) { diff --git a/sys/dev/pci/isp_pci.c b/sys/dev/pci/isp_pci.c index a384caa357d..517973df357 100644 --- a/sys/dev/pci/isp_pci.c +++ b/sys/dev/pci/isp_pci.c @@ -1,4 +1,4 @@ -/* $NetBSD: isp_pci.c,v 1.66 2001/02/12 23:25:20 mjacob Exp $ */ +/* $NetBSD: isp_pci.c,v 1.67 2001/03/07 23:07:16 thorpej Exp $ */ /* * This driver, which is contained in NetBSD in the files: * @@ -874,8 +874,8 @@ isp_pci_dmasetup(isp, xs, rq, iptrp, optr) } } error = bus_dmamap_load(pcs->pci_dmat, dmap, xs->data, xs->datalen, - NULL, xs->xs_control & XS_CTL_NOSLEEP ? - BUS_DMA_NOWAIT : BUS_DMA_WAITOK); + NULL, ((xs->xs_control & XS_CTL_NOSLEEP) ? + BUS_DMA_NOWAIT : BUS_DMA_WAITOK) | BUS_DMA_STREAMING); if (error) { XS_SETERR(xs, HBA_BOTCH); return (CMD_COMPLETE); diff --git a/sys/dev/pci/twe.c b/sys/dev/pci/twe.c index c3b2643dcef..85d9042f136 100644 --- a/sys/dev/pci/twe.c +++ b/sys/dev/pci/twe.c @@ -1,4 +1,4 @@ -/* $NetBSD: twe.c,v 1.12 2001/03/04 17:50:51 ad Exp $ */ +/* $NetBSD: twe.c,v 1.13 2001/03/07 23:07:17 thorpej Exp $ */ /*- * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -834,7 +834,7 @@ twe_ccb_map(struct twe_softc *sc, struct twe_ccb *ccb) * Map the data buffer into bus space and build the S/G list. */ rv = bus_dmamap_load(sc->sc_dmat, ccb->ccb_dmamap_xfer, data, - ccb->ccb_datasize, NULL, BUS_DMA_NOWAIT); + ccb->ccb_datasize, NULL, BUS_DMA_NOWAIT | BUS_DMA_STREAMING); if (rv != 0) { if (ccb->ccb_abuf != (vaddr_t)0) { s = splvm(); |
