This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DM6446 ASOC: Problem in register read write



Hi,

I am writing simple driver for McASP module on DM6446 EVM board with ASOC architecture and using 3.14.0 main line version of Linux kernel.

As I found that in mainline version, support is broken, I added device tree support to load EVM and CODEC part of driver. I am using driver files from sound/soc/davinci as it is,

     sound/soc/davinci/davinci-evm.c

     sound/soc/davinci/davinci-pcm.c

I am writing minimal DAI driver for ASP. After loading ASP driver, in probe function I am getting proper reset values of register SRGR = 0x20000001

Then I enabled entry and exit function in driver and played audio file with aplay utility to debug the driver. But I am finding the content of SRGR=0 in driver's function pointers. Then I wrote a value of 0x20000001 to SRGR and read it back, but the value read is showing 0.

Following are the call sequences of functions and value of SRGR in each of functions,

   probe - SRGR=0x20000001

   set_fmt - SRGR=0x20000001

(Following functions are after issuing command for aplay)

   startup - SRGR=0x00

   set_sysclk-  SRGR=0x00

   hw_params - SRGR=0x00

  Before issuing aplay command, I validated whether ASP register's is actually owned by driver written by me by         issuing cat  command on /proc/iomem file.

  What can be possible scenarios in which register mapping can go wrong? or there are any debugging methods?