Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 316666
b: refs/heads/master
c: 341f4dc
h: refs/heads/master
v: v3
  • Loading branch information
Guennadi Liakhovetski authored and Vinod Koul committed Jul 20, 2012
1 parent 307b5a7 commit e23ee56
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7fd63ccdad72335fd820b0ce5cb8edb6ca6419ce
refs/heads/master: 341f4dc5dcecbf60f038055db177845b9af480ed
8 changes: 4 additions & 4 deletions trunk/drivers/dma/sh/shdma.c
Original file line number Diff line number Diff line change
Expand Up @@ -304,18 +304,18 @@ static void sh_dmae_setup_xfer(struct shdma_chan *schan,
}

static const struct sh_dmae_slave_config *dmae_find_slave(
struct sh_dmae_chan *sh_chan, struct sh_dmae_slave *slave)
struct sh_dmae_chan *sh_chan, unsigned int slave_id)
{
struct sh_dmae_device *shdev = to_sh_dev(sh_chan);
struct sh_dmae_pdata *pdata = shdev->pdata;
const struct sh_dmae_slave_config *cfg;
int i;

if (slave->shdma_slave.slave_id >= SH_DMA_SLAVE_NUMBER)
if (slave_id >= SH_DMA_SLAVE_NUMBER)
return NULL;

for (i = 0, cfg = pdata->slave; i < pdata->slave_num; i++, cfg++)
if (cfg->slave_id == slave->shdma_slave.slave_id)
if (cfg->slave_id == slave_id)
return cfg;

return NULL;
Expand All @@ -328,7 +328,7 @@ static int sh_dmae_set_slave(struct shdma_chan *schan,
shdma_chan);
struct sh_dmae_slave *slave = container_of(sslave, struct sh_dmae_slave,
shdma_slave);
const struct sh_dmae_slave_config *cfg = dmae_find_slave(sh_chan, slave);
const struct sh_dmae_slave_config *cfg = dmae_find_slave(sh_chan, sslave->slave_id);
if (!cfg)
return -ENODEV;

Expand Down

0 comments on commit e23ee56

Please sign in to comment.