On Fri, Apr 03, 2009 at 09:31:40AM +0200, Jaroslav Kysela wrote:
Unfortunately, driver may use more complex scenarios like:
- some hardware requires additional firmware - in this case devices might be created, but they are not useable until firmware is loaded
- 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.
Wouldn't the real fix be to make sure that the event from hal/udev happens after all the initialization has finished, i.e. the device got its firmware, all connected layers finished their work etc? Before all that, the audio device is not really available, right?
But even with this extension, the user space should handle dynamic device reconfiguration (my second example case). The question is, if it makes sense to handle group of devices per card basis or just take single devices and dynamically handle device changes.
That's another issue IMO, which needs different attention. Signaling audio devices being added (via udev) before it's actually usable is rather a bug than a missing extension, wouldn't you say?
Daniel