diff options
Diffstat (limited to 'arch/arm/include/asm/mach/dma.h')
-rw-r--r-- | arch/arm/include/asm/mach/dma.h | 35 |
1 files changed, 16 insertions, 19 deletions
diff --git a/arch/arm/include/asm/mach/dma.h b/arch/arm/include/asm/mach/dma.h index fc7278ea7146..9e614a18e680 100644 --- a/arch/arm/include/asm/mach/dma.h +++ b/arch/arm/include/asm/mach/dma.h | |||
@@ -15,13 +15,13 @@ struct dma_struct; | |||
15 | typedef struct dma_struct dma_t; | 15 | typedef struct dma_struct dma_t; |
16 | 16 | ||
17 | struct dma_ops { | 17 | struct dma_ops { |
18 | int (*request)(dmach_t, dma_t *); /* optional */ | 18 | int (*request)(unsigned int, dma_t *); /* optional */ |
19 | void (*free)(dmach_t, dma_t *); /* optional */ | 19 | void (*free)(unsigned int, dma_t *); /* optional */ |
20 | void (*enable)(dmach_t, dma_t *); /* mandatory */ | 20 | void (*enable)(unsigned int, dma_t *); /* mandatory */ |
21 | void (*disable)(dmach_t, dma_t *); /* mandatory */ | 21 | void (*disable)(unsigned int, dma_t *); /* mandatory */ |
22 | int (*residue)(dmach_t, dma_t *); /* optional */ | 22 | int (*residue)(unsigned int, dma_t *); /* optional */ |
23 | int (*setspeed)(dmach_t, dma_t *, int); /* optional */ | 23 | int (*setspeed)(unsigned int, dma_t *, int); /* optional */ |
24 | char *type; | 24 | const char *type; |
25 | }; | 25 | }; |
26 | 26 | ||
27 | struct dma_struct { | 27 | struct dma_struct { |
@@ -34,24 +34,21 @@ struct dma_struct { | |||
34 | unsigned int active:1; /* Transfer active */ | 34 | unsigned int active:1; /* Transfer active */ |
35 | unsigned int invalid:1; /* Address/Count changed */ | 35 | unsigned int invalid:1; /* Address/Count changed */ |
36 | 36 | ||
37 | dmamode_t dma_mode; /* DMA mode */ | 37 | unsigned int dma_mode; /* DMA mode */ |
38 | int speed; /* DMA speed */ | 38 | int speed; /* DMA speed */ |
39 | 39 | ||
40 | unsigned int lock; /* Device is allocated */ | 40 | unsigned int lock; /* Device is allocated */ |
41 | const char *device_id; /* Device name */ | 41 | const char *device_id; /* Device name */ |
42 | 42 | ||
43 | unsigned int dma_base; /* Controller base address */ | 43 | const struct dma_ops *d_ops; |
44 | int dma_irq; /* Controller IRQ */ | ||
45 | struct scatterlist cur_sg; /* Current controller buffer */ | ||
46 | unsigned int state; | ||
47 | |||
48 | struct dma_ops *d_ops; | ||
49 | }; | 44 | }; |
50 | 45 | ||
51 | /* Prototype: void arch_dma_init(dma) | 46 | /* |
52 | * Purpose : Initialise architecture specific DMA | 47 | * isa_dma_add - add an ISA-style DMA channel |
53 | * Params : dma - pointer to array of DMA structures | ||
54 | */ | 48 | */ |
55 | extern void arch_dma_init(dma_t *dma); | 49 | extern int isa_dma_add(unsigned int, dma_t *dma); |
56 | 50 | ||
57 | extern void isa_init_dma(dma_t *dma); | 51 | /* |
52 | * Add the ISA DMA controller. Always takes channels 0-7. | ||
53 | */ | ||
54 | extern void isa_init_dma(void); | ||