Re: Synaptics and keyboard losing interrupts w/ACPI ?

Dmitry Torokhov
2004-04-04T06:06:15Z

On Sunday 04 April 2004 12:54 am, Karl Hegbloom wrote:
> On Sat, 2004-04-03 at 21:29, Dmitry Torokhov wrote:
> > On Sunday 04 April 2004 12:16 am, Karl Hegbloom wrote:
> > > Is there any reason why the ACPI code cannot cache that info, rather
> > > than looking it up each time the /proc file is accessed? (which is what
> > > I think it does now... am I right?)
> >
> > It sort of does.. that's why there /proc/acpi/battery/BATX/info (slow access,
> > mostly static data) and /proc/acpi/battery/BATX/state. Now if only
> > applications weren't reading both of them all the time...
>
> But the thing is that the kernel can know when a battery gets jacked in,
> removed, or swapped for a fresh one, but a user space application
> cannot.

It can, the kernel signals when a battery is inserted or removed through
/proc/acpi/event (normally acpid listens on it). The only change that may be
needed is to allow multiple applications read /proc/acpi/event simultaneously,
right now it only allows exclusive access.

--
Dmitry