From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Matthew Garrett <mjg59@srcf.ucam.org>
Cc: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org,
lenb@kernel.org
Subject: Re: [PATCH] acpi: Update battery information on notification 0x81
Date: Mon, 3 Jan 2011 21:56:24 +0100 [thread overview]
Message-ID: <201101032156.24402.rjw@sisk.pl> (raw)
In-Reply-To: <20110103175915.GA789@srcf.ucam.org>
On Monday, January 03, 2011, Matthew Garrett wrote:
> On Thu, Dec 23, 2010 at 11:23:42PM +0100, Rafael J. Wysocki wrote:
>
> > As I've already said on IRC, I'd simply add a new function like:
> >
> > void acpi_battery_refresh(struct acpi_battery *battery)
> > {
> > if (!battery->bat.dev)
> > return;
> > acpi_battery_get_info(battery);
> > /* The battery may have changed its reporting units */
> > sysfs_remove_battery(battery);
> > sysfs_add_battery(battery);
> > }
> >
> > and call it before acpi_battery_update()
> > (a) in acpi_battery_resume()
> > (b) in acpi_battery_notify() if event == ACPI_BATTERY_NOTIFY_INFO
> >
> > That would be more straightforward IMHO.
>
> That might be more reasonable. Want to send that, or shall I?
I can do that.
Thanks,
Rafael
prev parent reply other threads:[~2011-01-03 20:57 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-16 20:32 [PATCH] acpi: Update battery information on notification 0x81 Matthew Garrett
2010-08-31 9:06 ` Richard Hughes
2010-12-15 17:19 ` Matthew Garrett
2010-12-23 21:16 ` Matthew Garrett
2010-12-23 22:23 ` Rafael J. Wysocki
2011-01-03 17:59 ` Matthew Garrett
2011-01-03 20:56 ` Rafael J. Wysocki [this message]
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=201101032156.24402.rjw@sisk.pl \
--to=rjw@sisk.pl \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mjg59@srcf.ucam.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.