From: Anton Vorontsov <avorontsov@ru.mvista.com>
To: "Mahalingam, Nithish" <nithish.mahalingam@intel.com>
Cc: "dwmw2@infradead.org" <dwmw2@infradead.org>,
"cbou@mail.ru" <cbou@mail.ru>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [RFC] [PATCH] Adding Intel Moorestown PMIC Battery Driver
Date: Fri, 15 Jan 2010 16:12:29 +0300 [thread overview]
Message-ID: <20100115131229.GA30213@oksana.dev.rtsoft.ru> (raw)
In-Reply-To: <175E0F9A9EFCEA46A65F5552BB0572980445DB31FB@bgsmsx502.gar.corp.intel.com>
On Fri, Jan 15, 2010 at 05:31:55PM +0530, Mahalingam, Nithish wrote:
[...]
> >> + unsigned int batt_charge_now; /* in mAS */
> >> + unsigned int batt_prev_charge_full; /* in mAS */
> >> + unsigned int batt_charge_rate; /* in units per second */
> >
> > Per include/linux/power_supply.h and
> > Documentation/power/power_supply_class.txt
> >
> > * All voltages, currents, charges, energies, time and temperatures in uV,
> > * uA, uAh, uWh, seconds and tenths of degree Celsius unless otherwise
> > * stated. It's driver's job to convert its raw values to units in which
> > * this class operates.
>
> I just now checked the hardware spec and it is indeed mAh. I will correct
> the comment appropriately.
Note, if the hardware reports the values in mAh (milli), the driver
still have to convert them to uAh (micro) before reporting the values
to userspace.
[...]
> > I think you can use threaded irq for this.
> >
> > See documentation for request_threaded_irq() in kernel/irq/manage.c.
> > And as an example of usage see drivers/mfd/wm8350-irq.c.
>
> Haa that is useful information... completely missed to read about this
> feature.
No wonder, it's just a new feature, not many know about it. ;-)
Once again, thanks for the driver!
--
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2
next prev parent reply other threads:[~2010-01-15 13:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <175E0F9A9EFCEA46A65F5552BB0572980445D2BE30@bgsmsx502.gar.corp.intel.com>
2010-01-11 21:32 ` Anton Vorontsov
2010-01-12 17:23 ` Mahalingam, Nithish
2010-01-15 12:01 ` Mahalingam, Nithish
2010-01-15 13:12 ` Anton Vorontsov [this message]
2010-01-15 13:19 ` Mahalingam, Nithish
2010-02-13 14:35 ` Mahalingam, Nithish
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=20100115131229.GA30213@oksana.dev.rtsoft.ru \
--to=avorontsov@ru.mvista.com \
--cc=cbou@mail.ru \
--cc=dwmw2@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nithish.mahalingam@intel.com \
/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
Powered by JetHome