On Wed, 2009-04-29 at 11:47 +0530, Azam Ansari wrote: > Hi Steve, > > After looking into the PINMUX I found that the pinmux setting is being > done when I call > > board_setup_psc(DAVINCI_GPSC_ARMDOMAIN, DAVINCI_LPSC_McBSP0, 1); > > This does the PINMUX settings for McBSP0. > > I found two patchs on the mailing list for McBSP0 setup... > tx_swap.patch > rx_swap.patch > http://www.mail-archive.com/davinci-linux-open-source@linux.davincidsp.com/msg10133.html > > > I tried applying the patches but the patches are not getting applied. > So I manually checked the patch and added it. > > After that I get following error for audio recording "frame sync not > detected". It seems that the frames are not getting detected. > > Also I found ASP1 uses CLKS pin for clock. So I changed it to use CLKR > pin for ASP0 by setting SCLKME bit in PCR. I found few code in mcbsp.c > and davinci-audio-dma-intf.c file that is only for ASP1 and not for > ASP0. So I modified it too but still recording is not working. > Example: > OLD: > if (!cpu_is_davinci_dm355()) > davinci_set_dma_dest_params(mcbsp[id].dma_tx_lch, > (unsigned long) (DAVINCI_MCBSP_BASE + 4), 0, > 0); > else > davinci_set_dma_dest_params(mcbsp[id].dma_tx_lch, > (unsigned long) (DAVINCI_MCBSP1_BASE + 4), 0, > 0); > > NEW: > if (cpu_is_davinci_dm355()) > davinci_set_dma_dest_params(mcbsp[id].dma_tx_lch, > (unsigned long) (DAVINCI_MCBSP_BASE + 4), 0, > 0); > else > davinci_set_dma_dest_params(mcbsp[id].dma_tx_lch, > (unsigned long) (DAVINCI_MCBSP1_BASE + 4), 0, > 0); > > Please help... >
Were you getting frame sync before the change? If you were, the pinmux is probably setting up correctly. I did a quick look through the code, and I noticed in function audio_aic33_init in sound/oss/dm644x/davinci-audio-aic33.c contains ... if (cpu_is_davinci_dm355()) { input_stream.dma_dev = DM355_DMA_MCBSP1_RX; output_stream.dma_dev = DM355_DMA_MCBSP1_TX; ... May want to try if (cpu_is_davinci_dm355()) { input_stream.dma_dev = DM355_DMA_MCBSP0_RX; output_stream.dma_dev = DM355_DMA_MCBSP0_TX; Also, file arch/arm/mach-davinci/mcbsp.c function davinci_mcbsp_recv_buffer may want to try replacing if (!cpu_is_davinci_dm355()) davinci_set_dma_src_params(mcbsp[id].dma_rx_lch, (unsigned long) DAVINCI_MCBSP_BASE, 0, 0); else davinci_set_dma_src_params(mcbsp[id].dma_rx_lch, (unsigned long) DAVINCI_MCBSP1_BASE, 0, 0); with just davinci_set_dma_src_params(mcbsp[id].dma_rx_lch, (unsigned long) DAVINCI_MCBSP_BASE, 0, 0); Regards, Steve _______________________________________________ Davinci-linux-open-source mailing list Davinci-linux-open-source@linux.davincidsp.com http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source