]>
Commit | Line | Data |
---|---|---|
3d588f83 AS |
1 | /* |
2 | * Driver for the Synopsys DesignWare DMA Controller | |
3 | * | |
4 | * Copyright (C) 2007 Atmel Corporation | |
5 | * Copyright (C) 2010-2011 ST Microelectronics | |
6 | * | |
7 | * This program is free software; you can redistribute it and/or modify | |
8 | * it under the terms of the GNU General Public License version 2 as | |
9 | * published by the Free Software Foundation. | |
10 | */ | |
11 | #ifndef _DMA_DW_H | |
12 | #define _DMA_DW_H | |
13 | ||
14 | #include <linux/dmaengine.h> | |
15 | ||
16 | /* DMA API extensions */ | |
17 | struct dw_desc; | |
18 | ||
19 | struct dw_cyclic_desc { | |
20 | struct dw_desc **desc; | |
21 | unsigned long periods; | |
22 | void (*period_callback)(void *param); | |
23 | void *period_callback_param; | |
24 | }; | |
25 | ||
26 | struct dw_cyclic_desc *dw_dma_cyclic_prep(struct dma_chan *chan, | |
27 | dma_addr_t buf_addr, size_t buf_len, size_t period_len, | |
28 | enum dma_transfer_direction direction); | |
29 | void dw_dma_cyclic_free(struct dma_chan *chan); | |
30 | int dw_dma_cyclic_start(struct dma_chan *chan); | |
31 | void dw_dma_cyclic_stop(struct dma_chan *chan); | |
32 | ||
33 | dma_addr_t dw_dma_get_src_addr(struct dma_chan *chan); | |
34 | ||
35 | dma_addr_t dw_dma_get_dst_addr(struct dma_chan *chan); | |
36 | ||
37 | #endif /* _DMA_DW_H */ |