Lines Matching refs:dma
28 void __init init_one_dvma(struct sbus_dma *dma, int num_dma) in init_one_dvma() argument
32 dma->next = 0; in init_one_dvma()
33 dma->running = 0; /* No transfers going on as of yet */ in init_one_dvma()
34 dma->allocated = 0; /* No one has allocated us yet */ in init_one_dvma()
35 switch(sbus_readl(dma->regs + DMA_CSR)&DMA_DEVICE_ID) { in init_one_dvma()
37 dma->revision = dvmarev0; in init_one_dvma()
41 dma->revision = dvmaesc1; in init_one_dvma()
45 dma->revision = dvmarev1; in init_one_dvma()
49 dma->revision = dvmarev2; in init_one_dvma()
53 dma->revision = dvmahme; in init_one_dvma()
57 dma->revision = dvmarevplus; in init_one_dvma()
62 sbus_readl(dma->regs + DMA_CSR) & DMA_DEVICE_ID); in init_one_dvma()
63 dma->allocated = 1; in init_one_dvma()
68 dump_dma_regs(dma->regs); in init_one_dvma()
76 struct sbus_dma *dma; in dvma_init() local
92 dma = kmalloc(sizeof(struct sbus_dma), GFP_ATOMIC); in dvma_init()
94 dma->sdev = this_dev; in dvma_init()
101 dchain->next = dma; in dvma_init()
104 dma_chain = dma; in dvma_init()
107 dma->regs = sbus_ioremap(&dma->sdev->resource[0], 0, in dvma_init()
108 dma->sdev->resource[0].end - dma->sdev->resource[0].start + 1, in dvma_init()
111 dma->node = dma->sdev->prom_node; in dvma_init()
113 init_one_dvma(dma, num_dma++); in dvma_init()
123 struct sbus_dma *dma; in sun4_dvma_init() local
128 dma = kmalloc(sizeof(struct sbus_dma), GFP_ATOMIC); in sun4_dvma_init()
131 dma->sdev = NULL; in sun4_dvma_init()
134 dma_chain = dma; in sun4_dvma_init()
138 dma->regs = sbus_ioremap(&r, 0, PAGE_SIZE, "dma"); in sun4_dvma_init()
141 dma->node = 0x0; in sun4_dvma_init()
143 init_one_dvma(dma, 0); in sun4_dvma_init()