[PATCH 1/3] watchdog: imxwd: Add error messages for some failure points in .probe()
Uwe Kleine-König
u.kleine-koenig at pengutronix.de
Wed Jun 29 01:54:52 PDT 2022
On Mon, Jun 27, 2022 at 12:51:45PM +0200, Ahmad Fatoum wrote:
> Hello Uwe,
>
> On 27.06.22 12:33, Uwe Kleine-König wrote:
> > Signed-off-by: Uwe Kleine-König <u.kleine-koenig at pengutronix.de>
> > ---
> > drivers/watchdog/imxwd.c | 14 ++++++++++----
> > 1 file changed, 10 insertions(+), 4 deletions(-)
> >
> > diff --git a/drivers/watchdog/imxwd.c b/drivers/watchdog/imxwd.c
> > index 31ea388c2cf2..3e596b55f8f7 100644
> > --- a/drivers/watchdog/imxwd.c
> > +++ b/drivers/watchdog/imxwd.c
> > @@ -245,12 +245,16 @@ static int imx_wd_probe(struct device_d *dev)
> > }
> >
> > clk = clk_get(dev, NULL);
> > - if (IS_ERR(clk))
> > + if (IS_ERR(clk)) {
> > + dev_err(dev, "Failed to get clk: %d\n", PTR_ERR(clk));
>
> Can you use dev_err_probe instead? Same for the messages below.
Yeah, will send a patch in a separate thread.
@sha: git b4 -P 2- b204e43f-3a98-b666-8a78-3281f5221f17 at pengutronix.de # :-)
Best regards
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/barebox/attachments/20220629/52db5232/attachment.sig>
More information about the barebox
mailing list