public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
From: Matti Vaittinen <mazziesaccount@gmail.com>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: Sebastian Reichel <sre@kernel.org>,
	Linux PM list <linux-pm@vger.kernel.org>
Subject: Re: [PATCH v2] power: supply_core: Pass pointer to battery info
Date: Tue, 14 Dec 2021 08:44:11 +0200	[thread overview]
Message-ID: <04df0bff-87b0-d39a-4f5c-bbeb7f3e0cd1@gmail.com> (raw)
In-Reply-To: <d4478fbf-1ec8-5659-c77d-f412c351e497@gmail.com>

Hi deee Ho peeps,

On 12/13/21 11:23, Matti Vaittinen wrote:
> On 12/10/21 07:57, Matti Vaittinen wrote:
>> On Thu, Dec 9, 2021 at 2:46 AM Linus Walleij 
>> <linus.walleij@linaro.org> wrote:
> 
>>> Also I would love if you could test v2 on hardware!

... snip ...

> spare board left - and I do noeed it for bunch of tasks - so I am afraid 
> I can't re-try testing untill I have ordered and received few 
> replacement boards...

It seems I like to live on the edge. I nevertheless connected my spare 
BBB board to the BD99954 and got it working. (I noticed I had two loose 
wires touching each others during my previous trial. It resulted 
shorting +5V from beagle to GND - which was not a good idea).

It appears the patch worked as expected - but it also appears the 
BD99954 driver does not handle missing info too well... I typoed the 
trickle-charger current property in DT - and as a result the driver 
decided -EINVAL to be valid value (just too large) and set the largest 
current BD99954 supports for trickle-charging... I think this same 
problem is there for all the -EINVAL values. If I am not mistaken this 
is somewhat nasty as it means that if some information is missing the 
driver will change (potentially pre-configured) values to something 
which may fry things...

Linus, want to fix this while at it - or do you prefer me to patch the 
BD99954 with some sanity checks? I think it'd be nice to get the fixes 
in stable so it might be best to add the sanity checks before changing 
the battery-info allocation - that might be nicer for the stable folks. 
(I guess you have plenty of other things to code + some IRL tasks as 
well ...;] So, I can patch this but it means there is likely to be some 
conflicts with your series. Hence I thought I'll ask if you wish to add 
checks for uninitialized battery-info values)

Best Regards
	--Matti Vaittinen

  reply	other threads:[~2021-12-14  6:44 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-06  0:06 [PATCH v2] power: supply_core: Pass pointer to battery info Linus Walleij
2021-12-08  6:46 ` Matti Vaittinen
2021-12-09  0:46   ` Linus Walleij
2021-12-10  5:57     ` Matti Vaittinen
2021-12-13  9:23       ` Matti Vaittinen
2021-12-13  9:23       ` Matti Vaittinen
2021-12-14  6:44         ` Matti Vaittinen [this message]
2021-12-14  6:53           ` Vaittinen, Matti
2021-12-14  7:49             ` Vaittinen, Matti

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=04df0bff-87b0-d39a-4f5c-bbeb7f3e0cd1@gmail.com \
    --to=mazziesaccount@gmail.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-pm@vger.kernel.org \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox