public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Karl Hegbloom <hegbloom-tbDHPZwbsQQ@public.gmane.org>
To: acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: Synaptics and keyboard losing interrupts w/ACPI ?
Date: Sat, 03 Apr 2004 21:54:39 -0800	[thread overview]
Message-ID: <1081058079.2239.15.camel@localhost.localdomain> (raw)
In-Reply-To: <200404040029.12359.dtor_core-yWtbtysYrB+LZ21kGMrzwg@public.gmane.org>

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.  If the application caches that information, there needs to be a
way for the kernel to notify it of a battery change.  But if the kernel
caches it, reading the battery information only when a new battery is
inserted, then returning that cached information on read of the "info"
file, the application need not concern itself with such things, and the
read can happen quickly.  Obviously the state information must be
updated each time it is requested.

-- 
If you feel like the machines are conspiring against you,
then it's time to perspire against the machines.




-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click

  parent reply	other threads:[~2004-04-04  5:54 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-04-04  2:09 Synaptics and keyboard losing interrupts w/ACPI ? Karl Hegbloom
     [not found] ` <1081044549.2179.281.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
2004-04-04  2:45   ` Randy.Dunlap
     [not found]     ` <20040403184520.196ff775.rddunlap-3NddpPZAyC0@public.gmane.org>
2004-04-04  3:19       ` Karl Hegbloom
     [not found]         ` <1081048768.2179.293.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
2004-04-04  3:49           ` Karl Hegbloom
     [not found]             ` <1081050591.2239.1.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
2004-04-04  4:36               ` Dmitry Torokhov
     [not found]                 ` <200404032336.39468.dtor_core-yWtbtysYrB+LZ21kGMrzwg@public.gmane.org>
2004-04-04  5:16                   ` Karl Hegbloom
     [not found]                     ` <1081055767.2239.7.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
2004-04-04  5:29                       ` Dmitry Torokhov
     [not found]                         ` <200404040029.12359.dtor_core-yWtbtysYrB+LZ21kGMrzwg@public.gmane.org>
2004-04-04  5:54                           ` Karl Hegbloom [this message]
     [not found]                             ` <1081058079.2239.15.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
2004-04-04  6:06                               ` Dmitry Torokhov
     [not found]                                 ` <200404040106.15621.dtor_core-yWtbtysYrB+LZ21kGMrzwg@public.gmane.org>
2004-04-05  2:40                                   ` Stefan Seyfried
     [not found]                                     ` <20040405024043.GC5509-l0tNAEGuAhhzZ8+rp42Dbp9+tswZ0GTaehPwdyo5hKaELgA04lAiVw@public.gmane.org>
2004-04-05  3:43                                       ` Karl Hegbloom

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=1081058079.2239.15.camel@localhost.localdomain \
    --to=hegbloom-tbdhpzwbsqq@public.gmane.org \
    --cc=acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox