Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add functions to dma.c to set address and length for src and dest.

  • Loading branch information...
commit 64a32dca71201e0ef54429f94b712de5453ce0b3 1 parent de8560a
Philip Balister authored
Showing with 20 additions and 0 deletions.
  1. +16 −0 arch/arm/plat-omap/dma.c
  2. +4 −0 arch/arm/plat-omap/include/plat/dma.h
View
16 arch/arm/plat-omap/dma.c
@@ -471,6 +471,14 @@ void omap_set_dma_src_burst_mode(int lch, enum omap_dma_burst_mode burst_mode)
}
EXPORT_SYMBOL(omap_set_dma_src_burst_mode);
+void omap_set_dma_src_addr_size(int lch, unsigned int addr, int elem_count)
+{
+
+ p->dma_write(addr, CSSA, lch);
+ p->dma_write(elem_count, CEN, lch);
+}
+EXPORT_SYMBOL(omap_set_dma_src_addr_size);
+
/* Note that dest_port is only for OMAP1 */
void omap_set_dma_dest_params(int lch, int dest_port, int dest_amode,
unsigned long dest_start,
@@ -561,6 +569,14 @@ void omap_set_dma_dest_burst_mode(int lch, enum omap_dma_burst_mode burst_mode)
}
EXPORT_SYMBOL(omap_set_dma_dest_burst_mode);
+void omap_set_dma_dest_addr_size(int lch, unsigned int addr, int elem_count)
+{
+
+ p->dma_write(addr, CDSA, lch);
+ p->dma_write(elem_count, CEN, lch);
+}
+EXPORT_SYMBOL(omap_set_dma_dest_addr_size);
+
static inline void omap_enable_channel_irq(int lch)
{
u32 status;
View
4 arch/arm/plat-omap/include/plat/dma.h
@@ -462,6 +462,8 @@ extern void omap_set_dma_src_index(int lch, int eidx, int fidx);
extern void omap_set_dma_src_data_pack(int lch, int enable);
extern void omap_set_dma_src_burst_mode(int lch,
enum omap_dma_burst_mode burst_mode);
+extern void omap_set_dma_src_addr_size(int lch, unsigned int addr,
+ int elem_count);
extern void omap_set_dma_dest_params(int lch, int dest_port, int dest_amode,
unsigned long dest_start,
@@ -470,6 +472,8 @@ extern void omap_set_dma_dest_index(int lch, int eidx, int fidx);
extern void omap_set_dma_dest_data_pack(int lch, int enable);
extern void omap_set_dma_dest_burst_mode(int lch,
enum omap_dma_burst_mode burst_mode);
+extern void omap_set_dma_dest_addr_size(int lch, unsigned int addr,
+ int elem_count);
extern void omap_set_dma_params(int lch,
struct omap_dma_channel_params *params);
Please sign in to comment.
Something went wrong with that request. Please try again.