Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 37413
b: refs/heads/master
c: e738e35
h: refs/heads/master
i:
  37411: 0be48cf
v: v3
  • Loading branch information
Ricardo Cerqueira authored and Mauro Carvalho Chehab committed Sep 26, 2006
1 parent 2109d7e commit 84a5662
Show file tree
Hide file tree
Showing 3 changed files with 11 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: 4e318bef68e819f001a3c8af65401891893d3d54
refs/heads/master: e738e35d1e9ae15b597c713e0b74e9a535020c0d
10 changes: 10 additions & 0 deletions trunk/drivers/media/video/cx88/cx88-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -792,6 +792,11 @@ int cx88_start_audio_dma(struct cx88_core *core)
{
/* constant 128 made buzz in analog Nicam-stereo for bigger fifo_size */
int bpl = cx88_sram_channels[SRAM_CH25].fifo_size/4;

/* If downstream RISC is enabled, bail out; ALSA is managing DMA */
if (cx_read(MO_AUD_DMACNTRL) & 0x10)
return 0;

/* setup fifo + format */
cx88_sram_channel_setup(core, &cx88_sram_channels[SRAM_CH25], bpl, 0);
cx88_sram_channel_setup(core, &cx88_sram_channels[SRAM_CH26], bpl, 0);
Expand All @@ -801,11 +806,16 @@ int cx88_start_audio_dma(struct cx88_core *core)

/* start dma */
cx_write(MO_AUD_DMACNTRL, 0x0003); /* Up and Down fifo enable */

return 0;
}

int cx88_stop_audio_dma(struct cx88_core *core)
{
/* If downstream RISC is enabled, bail out; ALSA is managing DMA */
if (cx_read(MO_AUD_DMACNTRL) & 0x10)
return 0;

/* stop dma */
cx_write(MO_AUD_DMACNTRL, 0x0000);

Expand Down
4 changes: 0 additions & 4 deletions trunk/drivers/media/video/cx88/cx88-tvaudio.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,14 +137,10 @@ static void set_audio_finish(struct cx88_core *core, u32 ctl)
{
u32 volume;

#ifndef CONFIG_VIDEO_CX88_ALSA
/* restart dma; This avoids buzz in NICAM and is good in others */
cx88_stop_audio_dma(core);
#endif
cx_write(AUD_RATE_THRES_DMD, 0x000000C0);
#ifndef CONFIG_VIDEO_CX88_ALSA
cx88_start_audio_dma(core);
#endif

if (cx88_boards[core->board].blackbird) {
/* sets sound input from external adc */
Expand Down

0 comments on commit 84a5662

Please sign in to comment.