All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lennart Poettering <mznyfn@0pointer.de>
To: alsa-devel@alsa-project.org
Subject: Re: Device creation order
Date: Fri, 3 Apr 2009 13:56:47 +0200	[thread overview]
Message-ID: <20090403115647.GD15646@tango.0pointer.de> (raw)
In-Reply-To: <49D5BCF6.1020407@ladisch.de>

On Fri, 03.04.09 09:38, Clemens Ladisch (clemens@ladisch.de) wrote:

> > - dynamic device creation at runtime - for example we have an
> >    experimental HDA driver configuration code which might change
> >    the arrangement of PCM devices on request from the user space
> > 
> > I would suggest to wait awhile with some small timeout (0.5 sec?) for all 
> > devices to get the usual static arrangement working and handle extra
> > dynamic cases, too.
> 
> The current implementation of the ALSA framework guarantees that the
> control device file is that latest one to be created for all the devices
> created at initialization.  Any devices created later depend on some
> userspace action, so a small timeout won't help in this case.
> 
> In other words:
> 1) When the control device file has been created, all other devices
>    (that are created during sound card initialization) are
>    available.

OK. Very good. I'll then change PA to rely on this behaviour and hope
that this is considered part of the ALSA userspace API and is not
changed in the future...

> 2) When some device file for a specific sound card is created after the
>    card's control device, the sound card configuration has changed.

I'll ignore this for now since Jaroslav mentioned drivers doing this
are still experimental. But eventually we'd need to know some kind of
'end notification' for this as well: i..e if the reconfiguration
causes multiple device nodes to disappear/appear we also need to know
when they are all complete. A possible simple fix would be to issue an
udev 'change' event on the control device after the reconfiguration
finished.

Lennart

-- 
Lennart Poettering                        Red Hat, Inc.
lennart [at] poettering [dot] net         ICQ# 11060553
http://0pointer.net/lennart/           GnuPG 0x1A015CC4

  parent reply	other threads:[~2009-04-03 11:56 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-03  1:54 Device creation order Lennart Poettering
2009-04-03  7:12 ` Jaroslav Kysela
2009-04-03  7:20   ` Daniel Mack
2009-04-03  7:31     ` Jaroslav Kysela
2009-04-03  7:40       ` Daniel Mack
2009-04-03 10:34       ` Colin Guthrie
2009-04-03 11:51       ` Lennart Poettering
2009-04-03 11:43     ` Lennart Poettering
2009-04-03  7:38   ` Clemens Ladisch
2009-04-03  7:50     ` Jaroslav Kysela
2009-04-03 11:58       ` Lennart Poettering
2009-04-03 11:56     ` Lennart Poettering [this message]
2009-04-05 13:16       ` Wu Fengguang
2009-04-05 14:40         ` Lennart Poettering
2009-04-05 20:29           ` Mark Brown
2009-04-03 11:42   ` Lennart Poettering

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=20090403115647.GD15646@tango.0pointer.de \
    --to=mznyfn@0pointer.de \
    --cc=alsa-devel@alsa-project.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 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.