From: Takashi Iwai <tiwai@suse.de>
To: Jiri Slaby <jirislaby@gmail.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
Eric Paris <eparis@redhat.com>, Pekka Enberg <penberg@kernel.org>,
Thomas Meyer <thomas@m3y3r.de>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: 2.6.36: Sound stop working
Date: Thu, 12 Aug 2010 23:45:33 +0200 [thread overview]
Message-ID: <s5h4oeztshu.wl%tiwai@suse.de> (raw)
In-Reply-To: <4C64669B.1020605@gmail.com>
At Thu, 12 Aug 2010 23:24:43 +0200,
Jiri Slaby wrote:
>
> On 08/12/2010 11:18 PM, Linus Torvalds wrote:
> > On Thu, Aug 12, 2010 at 2:01 PM, Jiri Slaby <jirislaby@gmail.com> wrote:
> >> Probably I got into this problem yesterday. Found out that PA fails to
> >> open /dev/snd/pcmC0D0p _second_ time. It opens it, then closes, then
> >> opens it again and gets EBUSY. aplay is OK.
>
> Perfectly reproducible in qemu-kvm with ac97 soundhw, i.e. intel8x0
> driver. Just in case you want to debug that easily.
And the below is a minimal test case to simulate the situation
PulseAudio does.
Takashi
===
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <sys/inotify.h>
#include <unistd.h>
int main()
{
int fd;
inotify_add_watch(inotify_init(), "/dev/snd", IN_CLOSE_WRITE);
fd = open("/dev/snd/pcmC0D0p", O_RDWR | O_NONBLOCK);
if (fd < 0)
perror("open1");
else
close(fd);
fd = open("/dev/snd/pcmC0D0p", O_RDWR | O_NONBLOCK);
if (fd < 0)
perror("open2");
else
close(fd);
return 0;
}
prev parent reply other threads:[~2010-08-12 21:45 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-12 20:00 Thomas Meyer
2010-08-12 20:10 ` Pekka Enberg
2010-08-12 20:20 ` Linus Torvalds
2010-08-12 21:01 ` Linus Torvalds
2010-08-12 20:26 ` Takashi Iwai
2010-08-12 21:01 ` Jiri Slaby
2010-08-12 21:14 ` Maxim Levitsky
2010-08-12 21:17 ` Takashi Iwai
2010-08-12 21:41 ` Linus Torvalds
2010-08-12 21:50 ` Linus Torvalds
2010-08-12 21:52 ` Al Viro
2010-08-12 22:19 ` Linus Torvalds
2010-08-13 1:53 ` Eric Paris
2010-08-13 7:50 ` Jiri Slaby
2010-08-12 22:07 ` Takashi Iwai
2010-08-12 21:18 ` Linus Torvalds
2010-08-12 21:24 ` Jiri Slaby
2010-08-12 21:45 ` Takashi Iwai [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=s5h4oeztshu.wl%tiwai@suse.de \
--to=tiwai@suse.de \
--cc=eparis@redhat.com \
--cc=jirislaby@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=penberg@kernel.org \
--cc=thomas@m3y3r.de \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®