All of lore.kernel.org
 help / color / mirror / Atom feed
* Error enabling dmix with ALSA
       [not found] <3a2444df0908150606p7a1cb237qad6d31dedae3ec4a@mail.gmail.com>
@ 2009-08-16 10:19 ` ruchi sirauthiya
  2009-08-19 12:16   ` Takashi Iwai
  0 siblings, 1 reply; 5+ messages in thread
From: ruchi sirauthiya @ 2009-08-16 10:19 UTC (permalink / raw)
  To: alsa-devel

Hi,

I am trying to enable a software mixer (using ALSA and dmix) on an OMAP3
based embedded target board using the twl4030 codec.

When I try to play audio using the command,

# aplay -D playback rec.wav

I am getting the following error:

ALSA lib pcm_direct.c:1098:(snd_pcm_direct_initialize_poll_fd) unable to
open timer 'hw:CLASS=3,SCLASS=0,CARD=0,DEV=0,SUBDEV=0'
ALSA lib pcm_dmix.c:943:(snd_pcm_dmix_open) unable to initialize poll_fd
aplay: main:546: audio open error: No such file or directory

The contents of my /etc/asound.conf is given below.

pcm.playback {
   type dmix
   ipc_key 2048
   ipc_key_add_uid true
   ipc_gid 1
   slave {
      rate 44100
      pcm hw:0
   }
}

I have tested it on two kernel versions, 2.6.22 and 2.6.29, but it fails on
both.
Playback and recording works fine if -D option is not provided.

I also tried configuring ALSA (dmix) with a different configuration file
which is given in the following link:
http://amarok.kde.org/wiki/Setting_up_Dmix_for_ALSA

# aplay -D plug:ossmix /mnt/Audio1_1.wav
ALSA lib pcm_direct.c:1098:(snd_pcm_direct_initialize_poll_fd) unable to
open timer 'hw:CLASS=3,SCLASS=0,CARD=0,DEV=0,SUBDEV=0'
ALSA lib pcm_dmix.c:943:(snd_pcm_dmix_open) unable to initialize poll_fd
aplay: main:546: audio open error: No such file or directory

But as you can see the same error turns up again.

The topic discussed in the following link (a similar issue) suggests that it
is unable to open a second timer.
http://osdir.com/ml/linux.distributions.crux.general/2005-11/msg00134.html

What could be the cause of this error?

Is the above error related to my ALSA configuration (for dmix) or is it
related to the sound hardware (or driver)?
Do I need to patch the kernel or ALSA for using dmix?

Please help me resolve this issue. Let me know if any more setup info is
required.

Thanks and Regards,

Ruchi Sirauthiya.



Some information I obtained from the proc filesystem is given below for your
reference.

-----------------------
For Linux kernel 2.6.29
-----------------------

[root@OMAP3 tests]# cat /proc/asound/version
Advanced Linux Sound Architecture Driver Version 1.0.19


[root@OMAP3 tests]# cat /proc/asound/cards
 0 [omap3evm       ]: twl4030 - omap3evm
                      omap3evm (twl4030)

[root@OMAP3 tests]# omap-dss: Could not find exact pixel clock. Requested
25188 kHz, got 25187 kHz

[root@OMAP3 tests]# cat /proc/asound/devices
  2:        : timer
  3: [ 0- 0]: digital audio playback
  4: [ 0- 0]: digital audio capture
  5: [ 0]   : control

[root@OMAP3 tests]# cat /proc/asound/timers
G0: system timer : 7812.500us (10000000 ticks)
P0-0-0: PCM playback 0-0-0 : SLAVE
P0-0-1: PCM capture 0-0-1 : SLAVE

[root@OMAP3 tests]# cat /proc/asound/pcm
00-00: TWL4030 twl4030-0 :  : playback 1 : capture 1

[root@OMAP3 tests]# cat /proc/asound/devices
  2:        : timer
   3: [ 0- 0]: digital audio playback
  4: [ 0- 0]: digital audio capture
  5: [ 0]   : control

[root@OMAP3 tests]# cat /proc/asound/pcm
00-00: TWL4030 twl4030-0 :  : playback 1 : capture 1

[root@OMAP3 tests]# cat /proc/asound/oss/devices
  3: [0- 0]: digital audio
  4: [0- 0]: digital audio

[root@OMAP3 tests]# cat /proc/asound/oss/sndstat
Sound Driver:3.8.1a-980706 (ALSA v1.0.19 emulation code)
Kernel: Linux OMAP3 2.6.29-rc3-omap1 #1 Fri Jul 24 14:45:37 IST 2009 armv7l
Config options: 0
Installed drivers:
Type 10: ALSA emulation

Card config:
omap3evm (twl4030)

Audio devices:
0:  (DUPLEX)

Synth devices: NOT ENABLED IN CONFIG

Midi devices: NOT ENABLED IN CONFIG

Timers:
31: system timer

Mixers: NOT ENABLED IN CONFIG

[root@OMAP3 tests]# aplay -D playback /mnt/Audio1_1.wav
ALSA lib pcm_direct.c:1098:(snd_pcm_direct_initialize_poll_fd) unable to
open timer 'hw:CLASS=3,SCLASS=0,CARD=0,DEV=0,SUBDEV=0'
ALSA lib pcm_dmix.c:943:(snd_pcm_dmix_open) unable to initialize poll_fd
aplay: main:546: audio open error: No such file or directory


-----------------------
For Linux kernel 2.6.22
-----------------------

[root@OMAP3 tests]# cat /proc/asound/devices
  2:        : timer
  3: [ 0- 0]: digital audio playback
  4: [ 0- 0]: digital audio capture
  5: [ 0]   : control

[root@OMAP3 tests]# cat /proc/asound/pcm
00-00: OMAP PCM : omap alsa pcm : playback 1 : capture 1

[root@OMAP3 tests]# cat /proc/asound/timers
G0: system timer : 7812.500us (10000000 ticks)
P0-0-0: PCM playback 0-0-0 : SLAVE
P0-0-1: PCM capture 0-0-1 : SLAVE

[root@OMAP3 tests]# cat /proc/asound/
/proc/asound/TWL4030/  /proc/asound/devices   /proc/asound/timers
/proc/asound/card0/    /proc/asound/hwdep     /proc/asound/version
/proc/asound/cards     /proc/asound/pcm

[root@OMAP3 tests]# cat /proc/asound/cards
 0 [TWL4030        ]: OMAP_ALSA - TWL4030
                      TWL4030

/proc/asound/oss was not found in the proc file system when booted with
kernel 2.6.22.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Error enabling dmix with ALSA
  2009-08-16 10:19 ` Error enabling dmix with ALSA ruchi sirauthiya
@ 2009-08-19 12:16   ` Takashi Iwai
  2009-08-20  7:32     ` ruchi sirauthiya
  0 siblings, 1 reply; 5+ messages in thread
From: Takashi Iwai @ 2009-08-19 12:16 UTC (permalink / raw)
  To: ruchi sirauthiya; +Cc: alsa-devel

At Sun, 16 Aug 2009 15:49:11 +0530,
ruchi sirauthiya wrote:
> 
> Hi,
> 
> I am trying to enable a software mixer (using ALSA and dmix) on an OMAP3
> based embedded target board using the twl4030 codec.
> 
> When I try to play audio using the command,
> 
> # aplay -D playback rec.wav
> 
> I am getting the following error:
> 
> ALSA lib pcm_direct.c:1098:(snd_pcm_direct_initialize_poll_fd) unable to
> open timer 'hw:CLASS=3,SCLASS=0,CARD=0,DEV=0,SUBDEV=0'

Do you have /dev/snd/timer device?


Takashi

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Error enabling dmix with ALSA
  2009-08-19 12:16   ` Takashi Iwai
@ 2009-08-20  7:32     ` ruchi sirauthiya
  2009-08-20  8:36       ` Takashi Iwai
  0 siblings, 1 reply; 5+ messages in thread
From: ruchi sirauthiya @ 2009-08-20  7:32 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel

Hi,
No, I do not have /dev/snd/timer device entry.

A small correction... I am using TPS65950 codec and not TWL4030.

Ruchi Sirauthiya


On Wed, Aug 19, 2009 at 5:46 PM, Takashi Iwai <tiwai@suse.de> wrote:

> At Sun, 16 Aug 2009 15:49:11 +0530,
> ruchi sirauthiya wrote:
> >
> > Hi,
> >
> > I am trying to enable a software mixer (using ALSA and dmix) on an OMAP3
> > based embedded target board using the twl4030 codec.
> >
> > When I try to play audio using the command,
> >
> > # aplay -D playback rec.wav
> >
> > I am getting the following error:
> >
> > ALSA lib pcm_direct.c:1098:(snd_pcm_direct_initialize_poll_fd) unable to
> > open timer 'hw:CLASS=3,SCLASS=0,CARD=0,DEV=0,SUBDEV=0'
>
> Do you have /dev/snd/timer device?
>
>
> Takashi
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Error enabling dmix with ALSA
  2009-08-20  7:32     ` ruchi sirauthiya
@ 2009-08-20  8:36       ` Takashi Iwai
  2009-08-30 12:13         ` ruchi sirauthiya
  0 siblings, 1 reply; 5+ messages in thread
From: Takashi Iwai @ 2009-08-20  8:36 UTC (permalink / raw)
  To: ruchi sirauthiya; +Cc: alsa-devel

At Thu, 20 Aug 2009 13:02:20 +0530,
ruchi sirauthiya wrote:
> 
> Hi,
> No, I do not have /dev/snd/timer device entry.

That's the reason.  dmix uses the ALSA timer device to sync the
position.


Takashi

> 
> A small correction... I am using TPS65950 codec and not TWL4030.
> 
> Ruchi Sirauthiya
> 
> 
> On Wed, Aug 19, 2009 at 5:46 PM, Takashi Iwai <tiwai@suse.de> wrote:
> 
> > At Sun, 16 Aug 2009 15:49:11 +0530,
> > ruchi sirauthiya wrote:
> > >
> > > Hi,
> > >
> > > I am trying to enable a software mixer (using ALSA and dmix) on an OMAP3
> > > based embedded target board using the twl4030 codec.
> > >
> > > When I try to play audio using the command,
> > >
> > > # aplay -D playback rec.wav
> > >
> > > I am getting the following error:
> > >
> > > ALSA lib pcm_direct.c:1098:(snd_pcm_direct_initialize_poll_fd) unable to
> > > open timer 'hw:CLASS=3,SCLASS=0,CARD=0,DEV=0,SUBDEV=0'
> >
> > Do you have /dev/snd/timer device?
> >
> >
> > Takashi
> >
> [2  <text/html; ISO-8859-1 (quoted-printable)>]
> 

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Error enabling dmix with ALSA
  2009-08-20  8:36       ` Takashi Iwai
@ 2009-08-30 12:13         ` ruchi sirauthiya
  0 siblings, 0 replies; 5+ messages in thread
From: ruchi sirauthiya @ 2009-08-30 12:13 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel

Hi,

> That's the reason.  dmix uses the ALSA timer device to sync the

position.


> Takashi


Thanks a lot, I moved /dev/timer to /dev/snd/timer and aplay (and dmix
plugin) worked!

Ruchi

On Thu, Aug 20, 2009 at 2:06 PM, Takashi Iwai <tiwai@suse.de> wrote:

> At Thu, 20 Aug 2009 13:02:20 +0530,
> ruchi sirauthiya wrote:
> >
> > Hi,
> > No, I do not have /dev/snd/timer device entry.
>
> That's the reason.  dmix uses the ALSA timer device to sync the
> position.
>
>
> Takashi
>
> >
> > A small correction... I am using TPS65950 codec and not TWL4030.
> >
> > Ruchi Sirauthiya
> >
> >
> > On Wed, Aug 19, 2009 at 5:46 PM, Takashi Iwai <tiwai@suse.de> wrote:
> >
> > > At Sun, 16 Aug 2009 15:49:11 +0530,
> > > ruchi sirauthiya wrote:
> > > >
> > > > Hi,
> > > >
> > > > I am trying to enable a software mixer (using ALSA and dmix) on an
> OMAP3
> > > > based embedded target board using the twl4030 codec.
> > > >
> > > > When I try to play audio using the command,
> > > >
> > > > # aplay -D playback rec.wav
> > > >
> > > > I am getting the following error:
> > > >
> > > > ALSA lib pcm_direct.c:1098:(snd_pcm_direct_initialize_poll_fd) unable
> to
> > > > open timer 'hw:CLASS=3,SCLASS=0,CARD=0,DEV=0,SUBDEV=0'
> > >
> > > Do you have /dev/snd/timer device?
> > >
> > >
> > > Takashi
> > >
> > [2  <text/html; ISO-8859-1 (quoted-printable)>]
> >
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-08-30 12:13 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <3a2444df0908150606p7a1cb237qad6d31dedae3ec4a@mail.gmail.com>
2009-08-16 10:19 ` Error enabling dmix with ALSA ruchi sirauthiya
2009-08-19 12:16   ` Takashi Iwai
2009-08-20  7:32     ` ruchi sirauthiya
2009-08-20  8:36       ` Takashi Iwai
2009-08-30 12:13         ` ruchi sirauthiya

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.