From: Pavel Machek <pavel@ucw.cz>
To: kernel list <linux-kernel@vger.kernel.org>,
baolin.wang@linaro.org, linus.walleij@linaro.org,
sebastian.reichel@collabora.com
Cc: sre@kernel.org
Subject: Re: 5.0-rc1 Open circuit voltage tables -- 3afb50d7125bc
Date: Mon, 11 Mar 2019 11:23:25 +0100 [thread overview]
Message-ID: <20190311102325.GB14118@amd> (raw)
In-Reply-To: <20190107190555.GA18865@amd>
[-- Attachment #1: Type: text/plain, Size: 870 bytes --]
On Mon 2019-01-07 20:05:55, Pavel Machek wrote:
> Hi!
>
> Can we do something with that code?
>
> First -- tables should not be necceessary. Formula for li-ion open
> circuit voltage is well-known, and does not really depend on the
> device -- only on the chemistry of battery.
>
> state of charge = f( voltage, current, internal resistance )
>
> (And yes, internal resistance depends on temperature and health of the
> battery).
>
> Second, even if we need tables, why is it doing multiple allocations?
>
> info->ocv_temp[index] = -EINVAL;
>
> That's just wrong. Ocv_temp is temperature in celsius. Temperatures go
> below zero.
Ping? That code is just bad. Does someone care?
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]
next prev parent reply other threads:[~2019-03-11 10:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-07 19:05 5.0-rc1 Open circuit voltage tables -- 3afb50d7125bc Pavel Machek
2019-03-11 10:23 ` Pavel Machek [this message]
2019-03-11 11:11 ` Baolin Wang
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=20190311102325.GB14118@amd \
--to=pavel@ucw.cz \
--cc=baolin.wang@linaro.org \
--cc=linus.walleij@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sebastian.reichel@collabora.com \
--cc=sre@kernel.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.