Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1581463

Re: [PATCH 10/14] phy: meson8b-usb2: simplify optional reset handling

From Philipp Zabel <p.zabel@pengutronix.de>
Newsgroups linux.kernel
Subject Re: [PATCH 10/14] phy: meson8b-usb2: simplify optional reset handling
Date 2017-02-15 18:00 +0100
Message-ID <tbb5V-2sv-39@gated-at.bofh.it> (permalink)
References <t5iD7-3th-9@gated-at.bofh.it> <t5iWw-3Pv-71@gated-at.bofh.it> <taURr-8p5-1@gated-at.bofh.it> <tbaWe-2oT-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Jerome,

On Wed, 2017-02-15 at 17:43 +0100, Jerome Brunet wrote:
[...]
> > > @@ -241,7 +239,7 @@ static int phy_meson8b_usb2_probe(struct
> > > platform_device *pdev)
> > >                 return PTR_ERR(priv->clk_usb);
> > > 
> > >         priv->reset = devm_reset_control_get_optional_shared(&pdev-
> > > >dev, NULL);
> > > -       if (PTR_ERR(priv->reset) == -EPROBE_DEFER)
> > > +       if (PTR_ERR(priv->reset))
> 
> This is wrong and will always exit on error. It should be "IS_ERR".
> Clearly the bug was there before your patch, but since you are changing
> the faulty line, would you mind using IS_ERR instead ?
> 
> With this changed:
> Tested-by: Jerome Brunet <jbrunet@baylibre.com>

Thanks for catching this, I should have changed this to IS_ERR when
removing the error value comparison.

regards
Philipp

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: [PATCH 10/14] phy: meson8b-usb2: simplify optional reset handling Martin Blumenstingl <martin.blumenstingl@googlemail.com> - 2017-02-15 00:40 +0100
  Re: [PATCH 10/14] phy: meson8b-usb2: simplify optional reset  handling Jerome Brunet <jbrunet@baylibre.com> - 2017-02-15 17:50 +0100
    Re: [PATCH 10/14] phy: meson8b-usb2: simplify optional reset  handling Philipp Zabel <p.zabel@pengutronix.de> - 2017-02-15 18:00 +0100

csiph-web