Bug#347680: Xorg breaks acpid

Alan Hourihane alanh at fairlite.demon.co.uk
Tue Jan 24 11:41:18 PST 2006


On Tue, 2006-01-24 at 20:23 +0100, Lex Spoon wrote:
> "Mattia Dongili" <malattia at linux.it> wrote:
> 
> 
> > That patch was born to fix a different bug[1][2] showing when acpid closes
> > the socket making X eat all the cpu.
> > I submitted 2 patches of which the currently applied one simply retries
> > the same initialization path (try the socket, open /proc/acpi/event if the
> > former fails).
> > 
> > [1]: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=345537
> > [2]: https://bugs.freedesktop.org/show_bug.cgi?id=5140
> 
> Nice idea, but blocking acpid seems pretty bad.  IMHO, it's actually
> worse than the X server eating CPU or the X server losing ACPI events. 
> In the latter cases, I can restart X and things will go back to normal. 
> In the former case, that alone does not work.  So, in the super-short
> term, how about we go back to the patchless state?
> 
> As a real fix, how about having the X server retry connecting to acpid's
> socket every once in a while?  How hard would that be to implement?  It
> could try once per minute if it has never succeeded at opening the
> socket, and once per 5 seconds if it has ever succeeded.  

The Xserver connects to the acpid (or directly) to get events such as
video hotkeying. If the user hits the hotkey and nothing happens to the
display - then they're gonna blame X for not responding to that request.
If anything X would probably need to check fairly frequently in it's
block handler and definately not wait 5 seconds or a minute as that's
far too long.

> Finally, to reiterate from my first email, it seems incorrect for X to
> *ever* try for /proc/acpi/event on a typical Linux distribution.  Am I
> mistaken?  Does anyone actually want to hook ACPI events but not use
> acpid?  If this is truly as rare as it strikes me, then the standard
> Linux compile of X should not even try for /proc/acpi/event at all.

Possibly, it's an easy enough fix to remove the code. So if there's
consensus then it should be removed.

Alan.




More information about the xorg mailing list