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.

DM644x Linux PCM driver fails intermittently when interrupted

Using the Linux 2.6.18 kernel from the latest DVSDK (V2.00) for the DM644x it is easy to show there is a problem with the audio sub-system.  To demonstrate this problem you need to have two scripts running at the same time.

The first script continuously runs the ALSA application speaker-test

while [ 1 ] ; do speaker-test ; done

The second script interrupts speaker-test every 1/4 second

while [ 1 ] ; do killall speaker-test ; usleep 250000 ; done

This test will fail after no more than 3 minutes.  We found the follow change to davinci_pcm_trigger() allows the test to run reliably.  Clearly this is not the right fix.

Index: linux-2.6.18/sound/soc/davinci/davinci-pcm.c
===================================================================
--- linux-2.6.18.orig/sound/soc/davinci/davinci-pcm.c    2011-01-06 07:43:06.204436738 -0600
+++ linux-2.6.18/sound/soc/davinci/davinci-pcm.c    2011-01-06 07:44:43.244439037 -0600
@@ -14,6 +14,7 @@
 #include <linux/platform_device.h>
 #include <linux/slab.h>
 #include <linux/dma-mapping.h>
+#include <linux/delay.h>
 
 #include <sound/driver.h>
 #include <sound/core.h>
@@ -174,7 +175,9 @@
     case SNDRV_PCM_TRIGGER_START:
     case SNDRV_PCM_TRIGGER_RESUME:
     case SNDRV_PCM_TRIGGER_PAUSE_RELEASE:
+        mdelay(100);
         davinci_start_dma(prtd->master_lch);
+        mdelay(100);
         break;
     case SNDRV_PCM_TRIGGER_STOP:
     case SNDRV_PCM_TRIGGER_SUSPEND:

Can someone please reproduce the error and post the correct fix to this problem, along with an explanation if the code change isn't obvious.

Thanks,

Todd

  • The issue you are seeing is on MontaVista-based kernel; MontaVista normally provides bug fixes via their MVZone site which requires a yearly license subscription.  I would contact them to see if they have a bug fix for this.

    Optionally, TI is actively fixing bugs in the GIT-tree community kernel (from which MV and others can pull in to create commercial distributions they support for a fee) and we have verified the bug is not present.  The following wiki shows you step-by-step process of using the free community kernel with DM6446 DVSDK. 

    http://processors.wiki.ti.com/index.php/Using_the_community_kernel_on_DM6446_with_the_DVSDK

     

  • hi juan , we are new to wifi side .so,we need help from you.our custom board with DM6443 .has we are working on DM6446 EVM board as REFERENCE . and the wifi module is jorjin WG7310E04 . AT FIRST step i want to test the sd slot with the wifi module is communication taking place or not. can you please give me some documents related to where to start and How to start working with the above wifi module. please tell you suggestion regarding this . thanks and regards , Y.V.RAMAKRISHNA