boundary, not boundry. Inspired by Tom Cosgrove.
This commit is contained in:
parent
43b448a711
commit
d88f7b1d62
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: rdreg.h,v 1.2 2003/08/07 16:30:56 agc Exp $ */
|
/* $NetBSD: rdreg.h,v 1.3 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1982, 1990, 1993
|
* Copyright (c) 1982, 1990, 1993
|
||||||
|
@ -153,8 +153,8 @@ struct rd_rscmd { /* different */
|
||||||
* Several HP drives have an odd number of 256 byte sectors per track.
|
* Several HP drives have an odd number of 256 byte sectors per track.
|
||||||
* This makes it rather difficult to break them into 512 and 1024 byte blocks.
|
* This makes it rather difficult to break them into 512 and 1024 byte blocks.
|
||||||
* So...we just do like HPUX and don't bother to respect hardware track/head
|
* So...we just do like HPUX and don't bother to respect hardware track/head
|
||||||
* boundries -- we just mold the disk so that we use the entire capacity.
|
* boundaries -- we just mold the disk so that we use the entire capacity.
|
||||||
* HPUX also sometimes doesn't abide by cylinder boundries, we attempt to
|
* HPUX also sometimes doesn't abide by cylinder boundaries, we attempt to
|
||||||
* whenever possible.
|
* whenever possible.
|
||||||
*
|
*
|
||||||
* DISK REAL (256 BPS) HPUX (1024 BPS) BSD (512 BPS)
|
* DISK REAL (256 BPS) HPUX (1024 BPS) BSD (512 BPS)
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: hd64570reg.h,v 1.8 2001/06/12 15:17:22 wiz Exp $ */
|
/* $NetBSD: hd64570reg.h,v 1.9 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1998 Vixie Enterprises
|
* Copyright (c) 1998 Vixie Enterprises
|
||||||
|
@ -607,6 +607,6 @@ struct hdlc_llc_header {
|
||||||
* DMA constraints
|
* DMA constraints
|
||||||
*/
|
*/
|
||||||
#define SCA_DMA_ALIGNMENT (64 * 1024) /* 64 KB alignment */
|
#define SCA_DMA_ALIGNMENT (64 * 1024) /* 64 KB alignment */
|
||||||
#define SCA_DMA_BOUNDRY (16 * 1024 * 1024) /* 16 MB region */
|
#define SCA_DMA_BOUNDARY (16 * 1024 * 1024) /* 16 MB region */
|
||||||
|
|
||||||
#endif /* _DEV_IC_HD64570REG_H_ */
|
#endif /* _DEV_IC_HD64570REG_H_ */
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: rrunner.c,v 1.42 2003/10/30 01:58:17 simonb Exp $ */
|
/* $NetBSD: rrunner.c,v 1.43 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
|
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
|
||||||
|
@ -42,7 +42,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/cdefs.h>
|
#include <sys/cdefs.h>
|
||||||
__KERNEL_RCSID(0, "$NetBSD: rrunner.c,v 1.42 2003/10/30 01:58:17 simonb Exp $");
|
__KERNEL_RCSID(0, "$NetBSD: rrunner.c,v 1.43 2003/11/02 10:31:06 wiz Exp $");
|
||||||
|
|
||||||
#include "opt_inet.h"
|
#include "opt_inet.h"
|
||||||
#include "opt_ns.h"
|
#include "opt_ns.h"
|
||||||
|
@ -222,7 +222,7 @@ eshconfig(sc)
|
||||||
sizeof(struct rr_event) * RR_EVENT_RING_SIZE;
|
sizeof(struct rr_event) * RR_EVENT_RING_SIZE;
|
||||||
|
|
||||||
error = bus_dmamem_alloc(sc->sc_dmat, sc->sc_dma_size,
|
error = bus_dmamem_alloc(sc->sc_dmat, sc->sc_dma_size,
|
||||||
0, RR_DMA_BOUNDRY, &sc->sc_dmaseg, 1,
|
0, RR_DMA_BOUNDARY, &sc->sc_dmaseg, 1,
|
||||||
&rseg, BUS_DMA_NOWAIT);
|
&rseg, BUS_DMA_NOWAIT);
|
||||||
if (error) {
|
if (error) {
|
||||||
aprint_error("%s: couldn't allocate space for host-side"
|
aprint_error("%s: couldn't allocate space for host-side"
|
||||||
|
@ -247,7 +247,7 @@ eshconfig(sc)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bus_dmamap_create(sc->sc_dmat, sc->sc_dma_size,
|
if (bus_dmamap_create(sc->sc_dmat, sc->sc_dma_size,
|
||||||
1, sc->sc_dma_size, RR_DMA_BOUNDRY,
|
1, sc->sc_dma_size, RR_DMA_BOUNDARY,
|
||||||
BUS_DMA_ALLOCNOW | BUS_DMA_NOWAIT,
|
BUS_DMA_ALLOCNOW | BUS_DMA_NOWAIT,
|
||||||
&sc->sc_dma)) {
|
&sc->sc_dma)) {
|
||||||
aprint_error("%s: couldn't create DMA map\n",
|
aprint_error("%s: couldn't create DMA map\n",
|
||||||
|
@ -302,7 +302,7 @@ eshconfig(sc)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (bus_dmamap_create(sc->sc_dmat, ESH_MAX_NSEGS * RR_DMA_MAX,
|
if (bus_dmamap_create(sc->sc_dmat, ESH_MAX_NSEGS * RR_DMA_MAX,
|
||||||
ESH_MAX_NSEGS, RR_DMA_MAX, RR_DMA_BOUNDRY,
|
ESH_MAX_NSEGS, RR_DMA_MAX, RR_DMA_BOUNDARY,
|
||||||
BUS_DMA_ALLOCNOW | BUS_DMA_NOWAIT,
|
BUS_DMA_ALLOCNOW | BUS_DMA_NOWAIT,
|
||||||
&sc->sc_send.ec_dma)) {
|
&sc->sc_send.ec_dma)) {
|
||||||
aprint_error("%s: failed bus_dmamap_create\n",
|
aprint_error("%s: failed bus_dmamap_create\n",
|
||||||
|
@ -316,7 +316,7 @@ eshconfig(sc)
|
||||||
|
|
||||||
for (i = 0; i < RR_MAX_SNAP_RECV_RING_SIZE; i++)
|
for (i = 0; i < RR_MAX_SNAP_RECV_RING_SIZE; i++)
|
||||||
if (bus_dmamap_create(sc->sc_dmat, RR_DMA_MAX, 1, RR_DMA_MAX,
|
if (bus_dmamap_create(sc->sc_dmat, RR_DMA_MAX, 1, RR_DMA_MAX,
|
||||||
RR_DMA_BOUNDRY,
|
RR_DMA_BOUNDARY,
|
||||||
BUS_DMA_ALLOCNOW | BUS_DMA_NOWAIT,
|
BUS_DMA_ALLOCNOW | BUS_DMA_NOWAIT,
|
||||||
&sc->sc_snap_recv.ec_dma[i])) {
|
&sc->sc_snap_recv.ec_dma[i])) {
|
||||||
aprint_error("%s: failed bus_dmamap_create\n",
|
aprint_error("%s: failed bus_dmamap_create\n",
|
||||||
|
@ -811,7 +811,7 @@ esh_fpopen(dev, oflags, devtype, p)
|
||||||
TAILQ_INIT(&recv->ec_queue);
|
TAILQ_INIT(&recv->ec_queue);
|
||||||
|
|
||||||
size = RR_FP_RECV_RING_SIZE * sizeof(struct rr_descr);
|
size = RR_FP_RECV_RING_SIZE * sizeof(struct rr_descr);
|
||||||
error = bus_dmamem_alloc(sc->sc_dmat, size, 0, RR_DMA_BOUNDRY,
|
error = bus_dmamem_alloc(sc->sc_dmat, size, 0, RR_DMA_BOUNDARY,
|
||||||
&recv->ec_dmaseg, 1,
|
&recv->ec_dmaseg, 1,
|
||||||
&rseg, BUS_DMA_WAITOK);
|
&rseg, BUS_DMA_WAITOK);
|
||||||
|
|
||||||
|
@ -836,7 +836,7 @@ esh_fpopen(dev, oflags, devtype, p)
|
||||||
goto bad_fp_dmamem_map;
|
goto bad_fp_dmamem_map;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bus_dmamap_create(sc->sc_dmat, size, 1, size, RR_DMA_BOUNDRY,
|
if (bus_dmamap_create(sc->sc_dmat, size, 1, size, RR_DMA_BOUNDARY,
|
||||||
BUS_DMA_ALLOCNOW | BUS_DMA_WAITOK,
|
BUS_DMA_ALLOCNOW | BUS_DMA_WAITOK,
|
||||||
&recv->ec_dma)) {
|
&recv->ec_dma)) {
|
||||||
printf("%s: couldn't create DMA map for FP receive ring\n",
|
printf("%s: couldn't create DMA map for FP receive ring\n",
|
||||||
|
@ -3691,7 +3691,7 @@ esh_new_dmainfo(sc)
|
||||||
assert(di != NULL);
|
assert(di != NULL);
|
||||||
|
|
||||||
if (bus_dmamap_create(sc->sc_dmat, ESH_MAX_NSEGS * RR_DMA_MAX,
|
if (bus_dmamap_create(sc->sc_dmat, ESH_MAX_NSEGS * RR_DMA_MAX,
|
||||||
ESH_MAX_NSEGS, RR_DMA_MAX, RR_DMA_BOUNDRY,
|
ESH_MAX_NSEGS, RR_DMA_MAX, RR_DMA_BOUNDARY,
|
||||||
BUS_DMA_ALLOCNOW | BUS_DMA_WAITOK,
|
BUS_DMA_ALLOCNOW | BUS_DMA_WAITOK,
|
||||||
&di->ed_dma)) {
|
&di->ed_dma)) {
|
||||||
printf("%s: failed dmainfo bus_dmamap_create\n",
|
printf("%s: failed dmainfo bus_dmamap_create\n",
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: rrunnerreg.h,v 1.3 1998/11/20 04:12:58 kml Exp $ */
|
/* $NetBSD: rrunnerreg.h,v 1.4 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
|
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
|
||||||
|
@ -521,8 +521,8 @@ struct rr_gen_info {
|
||||||
* A few constants:
|
* A few constants:
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define RR_DMA_BOUNDRY (64 * 1024) /* can't cross 64K boundries on DMA */
|
#define RR_DMA_BOUNDARY (64 * 1024) /* can't cross 64K boundaries on DMA */
|
||||||
#define RR_DMA_MAX 65535 /* maximum that can be transfered in
|
#define RR_DMA_MAX 65535 /* maximum that can be transferred in
|
||||||
one DMA operation */
|
one DMA operation */
|
||||||
#define RR_ULP_COUNT 256 /* number of possible ULPs */
|
#define RR_ULP_COUNT 256 /* number of possible ULPs */
|
||||||
#define RR_INIT_CMD 15 /* initial command index */
|
#define RR_INIT_CMD 15 /* initial command index */
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: gtsdmareg.h,v 1.1 2003/03/05 22:08:23 matt Exp $ */
|
/* $NetBSD: gtsdmareg.h,v 1.2 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2002 Allegro Networks, Inc., Wasabi Systems, Inc.
|
* Copyright (c) 2002 Allegro Networks, Inc., Wasabi Systems, Inc.
|
||||||
|
@ -90,7 +90,7 @@
|
||||||
#define SDMA_SDC_BLMR BIT(6) /* RX Big=0 Lil=1 Endian mode */
|
#define SDMA_SDC_BLMR BIT(6) /* RX Big=0 Lil=1 Endian mode */
|
||||||
#define SDMA_SDC_BLMT BIT(7) /* TX Big=0 Lil=1 Endian mode */
|
#define SDMA_SDC_BLMT BIT(7) /* TX Big=0 Lil=1 Endian mode */
|
||||||
#define SDMA_SDC_POVR BIT(8) /* PCI Override */
|
#define SDMA_SDC_POVR BIT(8) /* PCI Override */
|
||||||
#define SDMA_SDC_RIFB BIT(9) /* RX Intr on Frame boundries */
|
#define SDMA_SDC_RIFB BIT(9) /* RX Intr on Frame boundaries */
|
||||||
#define SDMA_SDC_RESa BITS(11,10)
|
#define SDMA_SDC_RESa BITS(11,10)
|
||||||
#define SDMA_SDC_BSZ_MASK BITS(13,12) /* Maximum Burst Size */
|
#define SDMA_SDC_BSZ_MASK BITS(13,12) /* Maximum Burst Size */
|
||||||
#define SDMA_SDC_BSZ_1x64 (0 << 12) /* 1 64 bit word */
|
#define SDMA_SDC_BSZ_1x64 (0 << 12) /* 1 64 bit word */
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: if_bgereg.h,v 1.13 2003/10/23 17:41:59 fvdl Exp $ */
|
/* $NetBSD: if_bgereg.h,v 1.14 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2001 Wind River Systems
|
* Copyright (c) 2001 Wind River Systems
|
||||||
* Copyright (c) 1997, 1998, 1999, 2001
|
* Copyright (c) 1997, 1998, 1999, 2001
|
||||||
|
@ -2218,7 +2218,7 @@ struct bge_ring_data {
|
||||||
/*
|
/*
|
||||||
* Number of DMA segments in a TxCB. Note that this is carefully
|
* Number of DMA segments in a TxCB. Note that this is carefully
|
||||||
* chosen to make the total struct size an even power of two. It's
|
* chosen to make the total struct size an even power of two. It's
|
||||||
* critical that no TxCB be split across a page boundry since
|
* critical that no TxCB be split across a page boundary since
|
||||||
* no attempt is made to allocate physically contiguous memory.
|
* no attempt is made to allocate physically contiguous memory.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: if_ntwoc_pci.c,v 1.12 2003/05/03 18:11:36 wiz Exp $ */
|
/* $NetBSD: if_ntwoc_pci.c,v 1.13 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1998 Vixie Enterprises
|
* Copyright (c) 1998 Vixie Enterprises
|
||||||
|
@ -37,7 +37,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/cdefs.h>
|
#include <sys/cdefs.h>
|
||||||
__KERNEL_RCSID(0, "$NetBSD: if_ntwoc_pci.c,v 1.12 2003/05/03 18:11:36 wiz Exp $");
|
__KERNEL_RCSID(0, "$NetBSD: if_ntwoc_pci.c,v 1.13 2003/11/02 10:31:06 wiz Exp $");
|
||||||
|
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
#include <sys/systm.h>
|
#include <sys/systm.h>
|
||||||
|
@ -592,7 +592,7 @@ ntwoc_pci_alloc_dma(struct sca_softc *sc)
|
||||||
if (bus_dmamem_alloc(sc->scu_dmat,
|
if (bus_dmamem_alloc(sc->scu_dmat,
|
||||||
allocsize,
|
allocsize,
|
||||||
SCA_DMA_ALIGNMENT,
|
SCA_DMA_ALIGNMENT,
|
||||||
SCA_DMA_BOUNDRY,
|
SCA_DMA_BOUNDARY,
|
||||||
&sc->scu_seg, 1, &rsegs, BUS_DMA_NOWAIT) != 0) {
|
&sc->scu_seg, 1, &rsegs, BUS_DMA_NOWAIT) != 0) {
|
||||||
printf("Could not allocate DMA memory\n");
|
printf("Could not allocate DMA memory\n");
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -607,7 +607,7 @@ ntwoc_pci_alloc_dma(struct sca_softc *sc)
|
||||||
NTWO_DPRINTF(("DMA memory mapped\n"));
|
NTWO_DPRINTF(("DMA memory mapped\n"));
|
||||||
|
|
||||||
if (bus_dmamap_create(sc->scu_dmat, allocsize, 2,
|
if (bus_dmamap_create(sc->scu_dmat, allocsize, 2,
|
||||||
allocsize, SCA_DMA_BOUNDRY,
|
allocsize, SCA_DMA_BOUNDARY,
|
||||||
BUS_DMA_NOWAIT, &sc->scu_dmam) != 0) {
|
BUS_DMA_NOWAIT, &sc->scu_dmam) != 0) {
|
||||||
printf("Could not create DMA map\n");
|
printf("Could not create DMA map\n");
|
||||||
return 1;
|
return 1;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: if_skvar.h,v 1.2 2003/10/15 02:18:52 briggs Exp $ */
|
/* $NetBSD: if_skvar.h,v 1.3 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
|
|
||||||
/*-
|
/*-
|
||||||
* Copyright (c) 2003 The NetBSD Foundation, Inc.
|
* Copyright (c) 2003 The NetBSD Foundation, Inc.
|
||||||
|
@ -106,7 +106,7 @@ struct sk_chain {
|
||||||
/*
|
/*
|
||||||
* Number of DMA segments in a TxCB. Note that this is carefully
|
* Number of DMA segments in a TxCB. Note that this is carefully
|
||||||
* chosen to make the total struct size an even power of two. It's
|
* chosen to make the total struct size an even power of two. It's
|
||||||
* critical that no TxCB be split across a page boundry since
|
* critical that no TxCB be split across a page boundary since
|
||||||
* no attempt is made to allocate physically contiguous memory.
|
* no attempt is made to allocate physically contiguous memory.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: ssvar.h,v 1.9 2002/07/22 14:59:45 hannken Exp $ */
|
/* $NetBSD: ssvar.h,v 1.10 2003/11/02 10:31:06 wiz Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1995 Kenneth Stailey. All rights reserved.
|
* Copyright (c) 1995 Kenneth Stailey. All rights reserved.
|
||||||
|
@ -70,7 +70,7 @@ struct ss_softc {
|
||||||
struct bufq_state buf_queue; /* the queue of pending IO operations */
|
struct bufq_state buf_queue; /* the queue of pending IO operations */
|
||||||
u_int quirks; /* scanner is only mildly twisted */
|
u_int quirks; /* scanner is only mildly twisted */
|
||||||
#define SS_Q_GET_BUFFER_SIZE 0x0001 /* poll for available data in ssread() */
|
#define SS_Q_GET_BUFFER_SIZE 0x0001 /* poll for available data in ssread() */
|
||||||
/* truncate to byte boundry is assumed by default unless one of these is set */
|
/* truncate to byte boundary is assumed by default unless one of these is set */
|
||||||
#define SS_Q_PAD_TO_BYTE 0x0002 /* pad monochrome data to byte boundary */
|
#define SS_Q_PAD_TO_BYTE 0x0002 /* pad monochrome data to byte boundary */
|
||||||
#define SS_Q_PAD_TO_WORD 0x0004 /* pad monochrome data to word boundary */
|
#define SS_Q_PAD_TO_WORD 0x0004 /* pad monochrome data to word boundary */
|
||||||
#define SS_Q_THRESHOLD_FOLLOWS_BRIGHTNESS 0x0008
|
#define SS_Q_THRESHOLD_FOLLOWS_BRIGHTNESS 0x0008
|
||||||
|
|
Loading…
Reference in New Issue