All of lore.kernel.org
 help / color / mirror / Atom feed
From: Clemens Ladisch <clemens@ladisch.de>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: alsa-devel@alsa-project.org,
	David Henningsson <david.henningsson@canonical.com>,
	zonque@gmail.com
Subject: Re: USB Audio initialization race
Date: Fri, 13 Sep 2013 22:55:43 +0200	[thread overview]
Message-ID: <52337BCF.8040602@ladisch.de> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1309131636250.1542-100000@iolanthe.rowland.org>

Alan Stern wrote:
>> 1) The first interface is probed, which might contain the mixer controls
>> 2) snd_card_register is called, which sends a signal to userspace
>> 3) PulseAudio probes the device and notices that it has no PCMs, so it
>> ignores the device
>> 4) The second interface is probed, which adds the PCMs
>> 5) snd_card_register is again called, which is a no-op since the card
>> already exist
>> 6) User is unhappy because his plugged in sound card did not show up in
>> PulseAudio.
>>
>> So, assuming all this is right, it seems like we need some type of
>> callback from the usb driver when all the interfaces for the sound card
>> has been probed, so we can call snd_card_register at that point instead.
>> Thoughts?
>
> The driver probably doesn't know when all the interfaces have been
> probed.  Maybe it would be better to send a signal to userspace each
> time snd_card_register is called, even if nothing is done.

New devices will result in a signal because they result in new device
nodes.

> Alternatively, when the first interface is probed, the driver could
> claim all the other interfaces belonging to the same association.

The driver already does this.


Regards,
Clemens

      parent reply	other threads:[~2013-09-13 20:56 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-13 19:56 USB Audio initialization race David Henningsson
2013-09-13 20:39 ` Alan Stern
2013-09-13 20:53   ` David Henningsson
2013-09-13 21:06     ` Alan Stern
2013-09-13 23:47       ` David Henningsson
2013-09-14 13:44         ` Alan Stern
2013-09-14 19:33           ` Clemens Ladisch
2013-09-15  1:35             ` Alan Stern
2013-09-15  8:49               ` Clemens Ladisch
2013-09-16 22:21                 ` David Henningsson
2013-09-13 20:55   ` Clemens Ladisch [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=52337BCF.8040602@ladisch.de \
    --to=clemens@ladisch.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=david.henningsson@canonical.com \
    --cc=stern@rowland.harvard.edu \
    --cc=zonque@gmail.com \
    /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 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.