lkml.org 
[lkml]   [1999]   [Sep]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: apm patch for kernel 2.2.12 (compute battery time left when bios didn't)
    On Mon, Sep 27, 1999 at 05:30:51PM +0200, Pavel Machek wrote:
    > Hi!
    >
    > > at the end of this mail is a small patch to compute the time left of the
    > > battery when the the bios don't do it, but report % of the battery.
    > > (it look at the speed at wich the % of the battery reduce).
    > > the time is computed in minutes.
    >
    > I believe this is wrong. apmd should do this work (and it _does_ do
    > this work).

    yes in did (i didn't know it :-( )

    > It does not belong to kernel.

    but with my patch with any bios which give the % of the battery
    the kernel will give the time left of the battery (from the bios or
    estimated by the kernel) when you ask it.

    this will make the output of /proc/apm more uniform and consistant, because
    i dont think that it should be the application which read /proc/apm
    which should do special things for broken bios. (i am using wmapm
    which read /proc/apm and dont report the time left).

    The size of the code to do the estimation is very small (10 lines of
    code and 2 static int to store some data).

    but if it really is a problem to allawais insert this code in the
    kernel source, i could add an option in the configuration entry of
    the apm.

    Franck

    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.rutgers.edu
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:54    [W:7.553 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site