[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAD=FV=UWn8a9C3j0Ky9JWqo_2AvOE=ORVP94zHftGQLsxFdXyw@mail.gmail.com>
Date: Fri, 19 Aug 2022 16:03:24 -0700
From: Doug Anderson <dianders@...omium.org>
To: Mark Brown <broonie@...nel.org>
Cc: Andrew Halaney <ahalaney@...hat.com>,
Liam Girdwood <lgirdwood@...il.com>,
LKML <linux-kernel@...r.kernel.org>, bmasney@...hat.com
Subject: Re: [PATCH] regulator: core: Clean up on enable failure
Hi,
On Fri, Aug 19, 2022 at 3:48 PM Mark Brown <broonie@...nel.org> wrote:
>
> On Fri, Aug 19, 2022 at 02:43:36PM -0500, Andrew Halaney wrote:
>
> > - if (regulator->uA_load && regulator->enable_count == 1)
> > - return drms_uA_update(rdev);
> > + if (regulator->uA_load && regulator->enable_count == 1) {
> > + ret = drms_uA_update(rdev);
>
> I am vaugely surprised and a bit concerned that drms_uA_update() can
> fail...
In his original email Andrew implied that his system was misconfigured
when he was seeing this error. I presume this isn't common which is
why nobody had noticed this before now, but given that the function
drms_uA_update() does return an error code it seems like we should
handle it properly in the caller.
-Doug
Powered by blists - more mailing lists