[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANAwSgRtZoAmMO-WtRBX4W4pTkmzJKH1zc=6-99Py-d_4cOR0w@mail.gmail.com>
Date: Wed, 22 Sep 2021 00:51:32 +0530
From: Anand Moon <linux.amoon@...il.com>
To: Martin Blumenstingl <martin.blumenstingl@...glemail.com>
Cc: linux-arm-kernel <linux-arm-kernel@...ts.infradead.org>,
linux-amlogic@...ts.infradead.org,
Linux Kernel <linux-kernel@...r.kernel.org>,
Liam Girdwood <lgirdwood@...il.com>,
Mark Brown <broonie@...nel.org>,
Jon Hunter <jonathanh@...dia.com>
Subject: Re: [PATCHv2] regulator: pwm-regulator: Make use of the helper
function dev_err_probe()
Hi Martin,
On Tue, 21 Sept 2021 at 11:04, Martin Blumenstingl
<martin.blumenstingl@...glemail.com> wrote:
>
> Hi Anand,
>
> On Mon, Sep 20, 2021 at 10:38 PM Anand Moon <linux.amoon@...il.com> wrote:
> >
> > devm_pwm_get() can return -EPROBE_DEFER if the pwm regulator is not
> > ready yet. Use dev_err_probe() for pwm regulator resources
> > to indicate the deferral reason when waiting for the
> > resource to come up.
> >
> > Fixes: 0cd71b9a43ad ("regulator: pwm: Don't warn on probe deferral")
> Personally I consider this as an improvement (having the deferral
> reason show up in debugfs), not a bugfix.
> Because of that I would drop the Fixes tag.
> Let's wait on other people's opinions though.
>
Ok will drop this in the next version.
> [...]
> > - dev_err(&pdev->dev, "Failed to get PWM: %d\n", ret);
> > - return ret;
> > + return dev_err_probe(&pdev->dev, PTR_ERR(drvdata->pwm),
> > + "Failed to register regulator %s\n",
> The message here should still be similar to the original one since the
> actual problem is that we could not get a reference to the PWM
> controller. At this point we are not trying to register the
> pwm-regulator yet.
>
Yep, Typo I mixed up the logs completely.
it should be "Failed to get PWM, deferring probe"
Thanks
-Anand
>
> Best regards,
> Martin
Powered by blists - more mailing lists