Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 166779
b: refs/heads/master
c: 81ac55a
h: refs/heads/master
i:
  166777: 0203d44
  166775: def2bc2
v: v3
  • Loading branch information
Troy Kisky authored and Mark Brown committed Sep 23, 2009
1 parent 95034ed commit f693b34
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 9 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: df0fd5e5e117329436fdea568455545ca18a71f0
refs/heads/master: 81ac55aa14c863821248d9e82694c79bb556694d
3 changes: 2 additions & 1 deletion trunk/sound/soc/davinci/davinci-i2s.c
Original file line number Diff line number Diff line change
Expand Up @@ -353,8 +353,9 @@ static int davinci_i2s_hw_params(struct snd_pcm_substream *substream,
struct snd_pcm_hw_params *params,
struct snd_soc_dai *dai)
{
struct davinci_pcm_dma_params *dma_params = dai->dma_data;
struct davinci_mcbsp_dev *dev = dai->private_data;
struct davinci_pcm_dma_params *dma_params =
dev->dma_params[substream->stream];
struct snd_interval *i = NULL;
int mcbsp_word_length;
unsigned int rcr, xcr, srgr;
Expand Down
12 changes: 5 additions & 7 deletions trunk/sound/soc/davinci/davinci-pcm.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,16 +126,9 @@ static void davinci_pcm_dma_irq(unsigned lch, u16 ch_status, void *data)
static int davinci_pcm_dma_request(struct snd_pcm_substream *substream)
{
struct davinci_runtime_data *prtd = substream->runtime->private_data;
struct snd_soc_pcm_runtime *rtd = substream->private_data;
struct davinci_pcm_dma_params *dma_data = rtd->dai->cpu_dai->dma_data;
struct edmacc_param p_ram;
int ret;

if (!dma_data)
return -ENODEV;

prtd->params = dma_data;

/* Request master DMA channel */
ret = edma_alloc_channel(prtd->params->channel,
davinci_pcm_dma_irq, substream,
Expand Down Expand Up @@ -244,6 +237,10 @@ static int davinci_pcm_open(struct snd_pcm_substream *substream)
struct snd_pcm_runtime *runtime = substream->runtime;
struct davinci_runtime_data *prtd;
int ret = 0;
struct snd_soc_pcm_runtime *rtd = substream->private_data;
struct davinci_pcm_dma_params *params = rtd->dai->cpu_dai->dma_data;
if (!params)
return -ENODEV;

snd_soc_set_runtime_hwparams(substream, &davinci_pcm_hardware);
/* ensure that buffer size is a multiple of period size */
Expand All @@ -257,6 +254,7 @@ static int davinci_pcm_open(struct snd_pcm_substream *substream)
return -ENOMEM;

spin_lock_init(&prtd->lock);
prtd->params = params;

runtime->private_data = prtd;

Expand Down

0 comments on commit f693b34

Please sign in to comment.