diff options
author | Rabin Vincent <rabin.vincent@stericsson.com> | 2011-01-25 11:18:27 +0100 |
---|---|---|
committer | Linus WALLEIJ <linus.walleij@stericsson.com> | 2011-10-22 18:45:40 +0200 |
commit | c8a2f2af35d890a7da7544bfb185e8b539d2856e (patch) | |
tree | 0183a2916fb3c26973888b907529befe87d77257 /drivers/dma | |
parent | 0e2c146dba1e60cb31aa5524e24d7acf2a30bd8f (diff) |
dma40: pass the info pointer all the way to reduce argument count
ST-Ericsson ID: 362972
ST-Ericsson FOSS-OUT ID: NA
ST-Ericsson Linux next: NA
Change-Id: I3279e5a337ca319ec9a8f21eef8dfbfec6e8182f
Acked-by: Per Forlin <per.forlin@stericsson.com>
Acked-by: Jonas Aaberg <jonas.aberg@stericsson.com>
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
Signed-off-by: Linus Walleij <linus.walleij@stericsson.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/34884
Tested-by: Narayanan GOPALAKRISHNAN <narayanan.gopalakrishnan@stericsson.com>
Diffstat (limited to 'drivers/dma')
-rw-r--r-- | drivers/dma/ste_dma40.c | 10 | ||||
-rw-r--r-- | drivers/dma/ste_dma40_ll.c | 18 | ||||
-rw-r--r-- | drivers/dma/ste_dma40_ll.h | 10 |
3 files changed, 17 insertions, 21 deletions
diff --git a/drivers/dma/ste_dma40.c b/drivers/dma/ste_dma40.c index 35693c8ba13..8c7cfea7c01 100644 --- a/drivers/dma/ste_dma40.c +++ b/drivers/dma/ste_dma40.c @@ -2016,19 +2016,17 @@ d40_prep_sg_phy(struct d40_chan *chan, struct d40_desc *desc, desc->lli_phy.src, virt_to_phys(desc->lli_phy.src), chan->src_def_cfg, - src_info->data_width, - src_info->psize, desc->cyclic, - desc->txd.flags & DMA_PREP_INTERRUPT); + desc->txd.flags & DMA_PREP_INTERRUPT, + src_info); ret = d40_phy_sg_to_lli(sg_dst, sg_len, dst_dev_addr, desc->lli_phy.dst, virt_to_phys(desc->lli_phy.dst), chan->dst_def_cfg, - dst_info->data_width, - dst_info->psize, desc->cyclic, - desc->txd.flags & DMA_PREP_INTERRUPT); + desc->txd.flags & DMA_PREP_INTERRUPT, + dst_info); dma_sync_single_for_device(chan->base->dev, desc->lli_pool.dma_addr, desc->lli_pool.size, DMA_TO_DEVICE); diff --git a/drivers/dma/ste_dma40_ll.c b/drivers/dma/ste_dma40_ll.c index f6c988a0c3f..9a7bd60f3b1 100644 --- a/drivers/dma/ste_dma40_ll.c +++ b/drivers/dma/ste_dma40_ll.c @@ -133,13 +133,14 @@ void d40_phy_cfg(struct stedma40_chan_cfg *cfg, int d40_phy_fill_lli(struct d40_phy_lli *lli, dma_addr_t data, u32 data_size, - int psize, dma_addr_t next_lli, u32 reg_cfg, bool term_int, - u32 data_width, - bool is_device) + bool is_device, + struct stedma40_half_channel_info *info) { + unsigned int data_width = info->data_width; + int psize = info->psize; int num_elems; if (psize == STEDMA40_PSIZE_PHY_1) @@ -201,10 +202,9 @@ int d40_phy_sg_to_lli(struct scatterlist *sg, struct d40_phy_lli *lli, dma_addr_t lli_phys, u32 reg_cfg, - u32 data_width, - int psize, bool cyclic, - bool cyclic_int) + bool cyclic_int, + struct stedma40_half_channel_info *info) { int total_size = 0; int i; @@ -236,12 +236,12 @@ int d40_phy_sg_to_lli(struct scatterlist *sg, err = d40_phy_fill_lli(&lli[i], dst, sg_dma_len(current_sg), - psize, next_lli_phys, reg_cfg, interrupt, - data_width, - target == dst); + target == dst, + info); + if (err) goto err; } diff --git a/drivers/dma/ste_dma40_ll.h b/drivers/dma/ste_dma40_ll.h index 09ced0d1a66..36a7773d845 100644 --- a/drivers/dma/ste_dma40_ll.h +++ b/drivers/dma/ste_dma40_ll.h @@ -323,20 +323,18 @@ int d40_phy_sg_to_lli(struct scatterlist *sg, struct d40_phy_lli *lli, dma_addr_t lli_phys, u32 reg_cfg, - u32 data_width, - int psize, bool cyclic, - bool cyclic_int); + bool cyclic_int, + struct stedma40_half_channel_info *info); int d40_phy_fill_lli(struct d40_phy_lli *lli, dma_addr_t data, u32 data_size, - int psize, dma_addr_t next_lli, u32 reg_cfg, bool term_int, - u32 data_width, - bool is_device); + bool is_device, + struct stedma40_half_channel_info *info); /* Logical channels */ |