On Tue, 05.01.10 11:18, Colin Guthrie (gmane at colin.guthr.ie) wrote: > Hi, > > It seems that there is conflict between GDM and real user accounts which > is affecting volume saving. > > The short description of the problem is that after logout, your user's > PA remains until the exit timeout but still processes volume saves. As > you logout, GDM is spawned and restores the volume to the value it has > in it's m-d-r database, your PA notices this "change from ALSA" and > saves it thus overwriting the real volume you left it with. > > More detailed info here: > http://pulseaudio.org/ticket/572#comment:19 Ah, good catch! Thanks for figuring that one out. I was puzzled by this one. > So, what to do about this? > > I propose that while consolekit says our user is inactive we ignore any > volume changes that come in via alsa. When our user becomes active, we > restore the device volumes. > > Comments? Hmm, for that to not be racy we'd have to *synchronously* check the ckit status on every alsa mixer change. That could be very slow. OTOH, if we did it asynchronously we'd just shift around the race... Hmm, what about this: do an access() on the control device (i.e. /dev/snd/controlC0) after each volume change and ignore the volume change if the device is not accessible to us? Since the ACL change should happen synchronously before the other side gets access this should fix the issue, shouldn't it? That sounds like a workable solution do me, do you agree? Also is much easier to implement, which is nice, too... Lennart -- Lennart Poettering Red Hat, Inc. lennart [at] poettering [dot] net http://0pointer.net/lennart/ GnuPG 0x1A015CC4