Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* ice1712, snd_pcm_mmap_readi(), POLLERR in poll_revents
@ 2003-05-16 14:03 Peter Vollmer
  2003-05-16 15:04 ` Takashi Iwai
  0 siblings, 1 reply; 3+ messages in thread
From: Peter Vollmer @ 2003-05-16 14:03 UTC (permalink / raw)
  To: alsa-devel

Hi all,

I am still trying to get the ice1712-based soundcard to work on an embedded 
platform, using alsa driver/lib 0.9.3
While capturing works for hw:0,0 (multitrack mode) using snd_pcm_readi(), I 
get an -EIO when capturing with snd_pcm_mmap_readi(), immediatly after the 
buffer is filled up with 4 periods.
I tracked the problem down to the snd_read_areas() function, where 
snd_pcm_wait(pcm,-1) returns -EIO (detection of POLLERR in revents), 
waiting for the soundcard to become ready.

Do you have any idea where to start debugging in the driver from this point ?

Thanks for your help,

Peter



-------------------------------------------------------
Enterprise Linux Forum Conference & Expo, June 4-6, 2003, Santa Clara
The only event dedicated to issues related to Linux enterprise solutions
www.enterpriselinuxforum.com

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

* Re: ice1712, snd_pcm_mmap_readi(), POLLERR in poll_revents
  2003-05-16 14:03 ice1712, snd_pcm_mmap_readi(), POLLERR in poll_revents Peter Vollmer
@ 2003-05-16 15:04 ` Takashi Iwai
  2003-05-16 15:52   ` Peter Vollmer
  0 siblings, 1 reply; 3+ messages in thread
From: Takashi Iwai @ 2003-05-16 15:04 UTC (permalink / raw)
  To: Peter Vollmer; +Cc: alsa-devel

At Fri, 16 May 2003 16:03:48 +0200,
Peter Vollmer wrote:
> 
> Hi all,
> 
> I am still trying to get the ice1712-based soundcard to work on an embedded 
> platform, using alsa driver/lib 0.9.3
> While capturing works for hw:0,0 (multitrack mode) using snd_pcm_readi(), I 
> get an -EIO when capturing with snd_pcm_mmap_readi(), immediatly after the 
> buffer is filled up with 4 periods.
> I tracked the problem down to the snd_read_areas() function, where 
> snd_pcm_wait(pcm,-1) returns -EIO (detection of POLLERR in revents), 
> waiting for the soundcard to become ready.

at first you should check in which state the pcm stream is when poll()
returns the error.  alsa-lib code checks the normal errors (XRUN and
SUSPENDED) but the other status are handled as it is.


ciao,

Takashi


-------------------------------------------------------
Enterprise Linux Forum Conference & Expo, June 4-6, 2003, Santa Clara
The only event dedicated to issues related to Linux enterprise solutions
www.enterpriselinuxforum.com

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

* Re: ice1712, snd_pcm_mmap_readi(), POLLERR in poll_revents
  2003-05-16 15:04 ` Takashi Iwai
@ 2003-05-16 15:52   ` Peter Vollmer
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Vollmer @ 2003-05-16 15:52 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel

At 17:04 16.5.2003 +0200, Takashi Iwai wrote:
>At Fri, 16 May 2003 16:03:48 +0200,
>Peter Vollmer wrote:
> >
> > Hi all,
> >
> > I am still trying to get the ice1712-based soundcard to work on an 
> embedded
> > platform, using alsa driver/lib 0.9.3
> > While capturing works for hw:0,0 (multitrack mode) using 
> snd_pcm_readi(), I
> > get an -EIO when capturing with snd_pcm_mmap_readi(), immediatly after the
> > buffer is filled up with 4 periods.
> > I tracked the problem down to the snd_read_areas() function, where
> > snd_pcm_wait(pcm,-1) returns -EIO (detection of POLLERR in revents),
> > waiting for the soundcard to become ready.
>
>at first you should check in which state the pcm stream is when poll()
>returns the error.  alsa-lib code checks the normal errors (XRUN and
>SUSPENDED) but the other status are handled as it is.

I checked this in the driver. Somehow the stream returned to OPEN state.
In snd_pcm_capture_poll() the default case is applied. But the driver
seems not to cause this, I checked all occurences of SNDRV_PCM_STATE_OPEN
(in snd_pcm_open_substream(), snd_pcm_hw_params() and snd_pcm_hw_free().
If the state is only set  using the enums SNDDRV_PCM_STATE_... , I guess I
have a problem somewhere else.

Peter



-------------------------------------------------------
Enterprise Linux Forum Conference & Expo, June 4-6, 2003, Santa Clara
The only event dedicated to issues related to Linux enterprise solutions
www.enterpriselinuxforum.com

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

end of thread, other threads:[~2003-05-16 15:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-05-16 14:03 ice1712, snd_pcm_mmap_readi(), POLLERR in poll_revents Peter Vollmer
2003-05-16 15:04 ` Takashi Iwai
2003-05-16 15:52   ` Peter Vollmer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox