1 /* $Id$ 2 * 3 * This file is subject to the terms and conditions of the GNU General Public 4 * License. See the file "COPYING" in the main directory of this archive 5 * for more details. 6 * 7 * Copyright (C) 1992-1997,2000-2003 Silicon Graphics, Inc. All rights reserved. 8 */ 9 #ifndef _ASM_IA64_SN_DMAMAP_H 10 #define _ASM_IA64_SN_DMAMAP_H 11 12 #include <asm/sn/types.h> 13 14 #ifdef __cplusplus 15 extern "C" { 16 #endif 17 18 /* 19 * Definitions for allocating, freeing, and using DMA maps 20 */ 21 22 /* 23 * DMA map types 24 */ 25 #define DMA_SCSI 0 26 #define DMA_A24VME 1 /* Challenge/Onyx only */ 27 #define DMA_A32VME 2 /* Challenge/Onyx only */ 28 #define DMA_A64VME 3 /* SN0/Racer */ 29 30 #define DMA_EISA 4 31 32 #define DMA_PCI32 5 /* SN0/Racer */ 33 #define DMA_PCI64 6 /* SN0/Racer */ 34 35 /* 36 * DMA map structure as returned by dma_mapalloc() 37 */ 38 typedef struct dmamap { 39 int dma_type; /* Map type (see above) */ 40 int dma_adap; /* I/O adapter */ 41 int dma_index; /* Beginning map register to use */ 42 int dma_size; /* Number of map registers to use */ 43 paddr_t dma_addr; /* Corresponding bus addr for A24/A32 */ 44 unsigned long dma_virtaddr; /* Beginning virtual address that is mapped */ 45 } dmamap_t; 46 47 #ifdef __cplusplus 48 } 49 #endif 50 51 /* standard flags values for pio_map routines, 52 * including {xtalk,pciio}_dmamap calls. 53 * NOTE: try to keep these in step with PIOMAP flags. 54 */ 55 #define DMAMAP_FIXED 0x1 56 #define DMAMAP_NOSLEEP 0x2 57 #define DMAMAP_INPLACE 0x4 58 59 #define DMAMAP_FLAGS 0x7 60 61 #endif /* _ASM_IA64_SN_DMAMAP_H */ 62