Hi Yang, Thank you for the patch. On Thu, Sep 15, 2022 at 11:03:14PM +0800, Yang Yingliang wrote: > In the probe path, dev_err() can be replace with dev_err_probe() > which will check if error code is -EPROBE_DEFER. > > Signed-off-by: Yang Yingliang <yangyingliang@xxxxxxxxxx> > --- > drivers/media/i2c/imx274.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/drivers/media/i2c/imx274.c b/drivers/media/i2c/imx274.c > index a00761b1e18c..0df515ab2cbf 100644 > --- a/drivers/media/i2c/imx274.c > +++ b/drivers/media/i2c/imx274.c > @@ -2060,9 +2060,8 @@ static int imx274_probe(struct i2c_client *client) > imx274->reset_gpio = devm_gpiod_get_optional(dev, "reset", > GPIOD_OUT_HIGH); > if (IS_ERR(imx274->reset_gpio)) { > - if (PTR_ERR(imx274->reset_gpio) != -EPROBE_DEFER) > - dev_err(dev, "Reset GPIO not setup in DT"); > - ret = PTR_ERR(imx274->reset_gpio); > + ret = dev_err_probe(dev, PTR_ERR(imx274->reset_gpio), > + "Reset GPIO not setup in DT"); While at it, could you add the missing \n at the end of the message ? With this fixed, Reviewed-by: Laurent Pinchart <laurent.pinchart@xxxxxxxxxxxxxxxx> > goto err_me; > } > -- Regards, Laurent Pinchart