Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 120316
b: refs/heads/master
c: 9cd28ab
h: refs/heads/master
v: v3
  • Loading branch information
Alexander Beregalov authored and Mark Brown committed Dec 14, 2008
1 parent 4ed825a commit 240adf6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 13 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: 49d92c7d5bbd158734bc34ed578a68b214a48583
refs/heads/master: 9cd28ab0051cc5232e3dffea6b318233445a3d5f
18 changes: 6 additions & 12 deletions trunk/sound/soc/davinci/davinci-pcm.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
#include <linux/platform_device.h>
#include <linux/slab.h>
#include <linux/dma-mapping.h>
#include <linux/kernel.h>

#include <sound/core.h>
#include <sound/pcm.h>
Expand All @@ -24,13 +25,6 @@

#include "davinci-pcm.h"

#define DAVINCI_PCM_DEBUG 0
#if DAVINCI_PCM_DEBUG
#define DPRINTK(x...) printk(KERN_DEBUG x)
#else
#define DPRINTK(x...)
#endif

static struct snd_pcm_hardware davinci_pcm_hardware = {
.info = (SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_BLOCK_TRANSFER |
SNDRV_PCM_INFO_MMAP | SNDRV_PCM_INFO_MMAP_VALID |
Expand Down Expand Up @@ -78,8 +72,8 @@ static void davinci_pcm_enqueue_dma(struct snd_pcm_substream *substream)
dma_offset = prtd->period * period_size;
dma_pos = runtime->dma_addr + dma_offset;

DPRINTK("audio_set_dma_params_play channel = %d dma_ptr = %x "
"period_size=%x\n", lch, dma_pos, period_size);
pr_debug("davinci_pcm: audio_set_dma_params_play channel = %d "
"dma_ptr = %x period_size=%x\n", lch, dma_pos, period_size);

data_type = prtd->params->data_type;
count = period_size / data_type;
Expand Down Expand Up @@ -112,7 +106,7 @@ static void davinci_pcm_dma_irq(int lch, u16 ch_status, void *data)
struct snd_pcm_substream *substream = data;
struct davinci_runtime_data *prtd = substream->runtime->private_data;

DPRINTK("lch=%d, status=0x%x\n", lch, ch_status);
pr_debug("davinci_pcm: lch=%d, status=0x%x\n", lch, ch_status);

if (unlikely(ch_status != DMA_COMPLETE))
return;
Expand Down Expand Up @@ -316,8 +310,8 @@ static int davinci_pcm_preallocate_dma_buffer(struct snd_pcm *pcm, int stream)
buf->area = dma_alloc_writecombine(pcm->card->dev, size,
&buf->addr, GFP_KERNEL);

DPRINTK("preallocate_dma_buffer: area=%p, addr=%p, size=%d\n",
(void *) buf->area, (void *) buf->addr, size);
pr_debug("davinci_pcm: preallocate_dma_buffer: area=%p, addr=%p, "
"size=%d\n", (void *) buf->area, (void *) buf->addr, size);

if (!buf->area)
return -ENOMEM;
Expand Down

0 comments on commit 240adf6

Please sign in to comment.