All of lore.kernel.org
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzk@kernel.org>
To: Jonathan Cameron <jic23@kernel.org>
Cc: Lars-Peter Clausen <lars@metafoo.de>,
	Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
	Peter Rosin <peda@axentia.se>,
	Michael Hennerich <Michael.Hennerich@analog.com>,
	Marek Vasut <marek.vasut@gmail.com>,
	Tomasz Duszynski <tomasz.duszynski@octakon.com>,
	linux-iio@vger.kernel.org,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	linux-arm-kernel@lists.infradead.org,
	"linux-samsung-soc@vger.kernel.org" 
	<linux-samsung-soc@vger.kernel.org>,
	linux-amlogic@lists.infradead.org,
	linux-stm32@st-md-mailman.stormreply.com,
	Andy Shevchenko <andy.shevchenko@gmail.com>
Subject: Re: [PATCH v3 08/18] iio: adc: stm32: Simplify with dev_err_probe()
Date: Wed, 9 Sep 2020 21:57:41 +0200	[thread overview]
Message-ID: <CAJKOXPeo8SXWaRmiFG6z+t9jcnaSMRpvRPm2X22Rf6rtEeKVew@mail.gmail.com> (raw)
In-Reply-To: <20200909193600.41970d8c@archlinux>

On Wed, 9 Sep 2020 at 20:36, Jonathan Cameron <jic23@kernel.org> wrote:
>
> On Sat, 29 Aug 2020 08:47:16 +0200
> Krzysztof Kozlowski <krzk@kernel.org> wrote:
>
> > Common pattern of handling deferred probe can be simplified with
> > dev_err_probe().  Less code and also it prints the error value.
> >
> > Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> > Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
> >
> I don't have the thread to hand, but this tripped a warning next
> and the patch was dropped as a result. See below.

Thanks for letting me know. If you mean the warning caused by:
https://lore.kernel.org/lkml/20200909073716.GA560912@kroah.com/
then the driver-core patch was dropped, not the iio one:
https://lore.kernel.org/linux-next/20200909074130.GB561485@kroah.com/T/#t

So we are good here :)

Best regards,
Krzysztof

> Jonathan
> > ---
> >
> > Changes since v2:
> > 1. Wrap dev_err_probe() lines at 80 character
> >
> > Changes since v1:
> > 1. Convert to devm_clk_get_optional
> > 2. Update also stm32-dfsdm-core and stm32-dac-core.
> > 3. Wrap around 100 characters (accepted by checkpatch).
> > ---
> >  drivers/iio/adc/stm32-adc-core.c   | 75 ++++++++++--------------------
> >  drivers/iio/adc/stm32-adc.c        | 10 ++--
> >  drivers/iio/adc/stm32-dfsdm-adc.c  | 10 ++--
> >  drivers/iio/adc/stm32-dfsdm-core.c |  9 ++--
> >  drivers/iio/dac/stm32-dac-core.c   |  5 +-
> >  5 files changed, 35 insertions(+), 74 deletions(-)
> >
> > diff --git a/drivers/iio/adc/stm32-adc-core.c b/drivers/iio/adc/stm32-adc-core.c
> > index 0e2068ec068b..3f27b4817a42 100644
> > --- a/drivers/iio/adc/stm32-adc-core.c
> > +++ b/drivers/iio/adc/stm32-adc-core.c
> > @@ -582,11 +582,9 @@ static int stm32_adc_core_switches_probe(struct device *dev,
> >       priv->syscfg = syscon_regmap_lookup_by_phandle(np, "st,syscfg");
> >       if (IS_ERR(priv->syscfg)) {
> >               ret = PTR_ERR(priv->syscfg);
> > -             if (ret != -ENODEV) {
> > -                     if (ret != -EPROBE_DEFER)
> > -                             dev_err(dev, "Can't probe syscfg: %d\n", ret);
> > -                     return ret;
> > -             }
> > +             if (ret != -ENODEV)
> > +                     return dev_err_probe(dev, ret, "Can't probe syscfg\n");
> > +
> >               priv->syscfg = NULL;
> >       }
> >
> > @@ -596,12 +594,9 @@ static int stm32_adc_core_switches_probe(struct device *dev,
> >               priv->booster = devm_regulator_get_optional(dev, "booster");
> >               if (IS_ERR(priv->booster)) {
> >                       ret = PTR_ERR(priv->booster);
> > -                     if (ret != -ENODEV) {
> > -                             if (ret != -EPROBE_DEFER)
> > -                                     dev_err(dev, "can't get booster %d\n",
> > -                                             ret);
> > -                             return ret;
> > -                     }
> > +                     if (ret != -ENODEV)
> > +                             dev_err_probe(dev, ret, "can't get booster\n");
>
> This tripped a warning and got the patch dropped because we no longer
> return on error.

WARNING: multiple messages have this Message-ID (diff)
From: Krzysztof Kozlowski <krzk@kernel.org>
To: Jonathan Cameron <jic23@kernel.org>
Cc: Lars-Peter Clausen <lars@metafoo.de>,
	Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
	Michael Hennerich <Michael.Hennerich@analog.com>,
	linux-iio@vger.kernel.org,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	linux-stm32@st-md-mailman.stormreply.com,
	Marek Vasut <marek.vasut@gmail.com>,
	Andy Shevchenko <andy.shevchenko@gmail.com>,
	"linux-samsung-soc@vger.kernel.org"
	<linux-samsung-soc@vger.kernel.org>,
	Tomasz Duszynski <tomasz.duszynski@octakon.com>,
	linux-amlogic@lists.infradead.org, Peter Rosin <peda@axentia.se>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v3 08/18] iio: adc: stm32: Simplify with dev_err_probe()
Date: Wed, 9 Sep 2020 21:57:41 +0200	[thread overview]
Message-ID: <CAJKOXPeo8SXWaRmiFG6z+t9jcnaSMRpvRPm2X22Rf6rtEeKVew@mail.gmail.com> (raw)
In-Reply-To: <20200909193600.41970d8c@archlinux>

On Wed, 9 Sep 2020 at 20:36, Jonathan Cameron <jic23@kernel.org> wrote:
>
> On Sat, 29 Aug 2020 08:47:16 +0200
> Krzysztof Kozlowski <krzk@kernel.org> wrote:
>
> > Common pattern of handling deferred probe can be simplified with
> > dev_err_probe().  Less code and also it prints the error value.
> >
> > Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> > Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
> >
> I don't have the thread to hand, but this tripped a warning next
> and the patch was dropped as a result. See below.

Thanks for letting me know. If you mean the warning caused by:
https://lore.kernel.org/lkml/20200909073716.GA560912@kroah.com/
then the driver-core patch was dropped, not the iio one:
https://lore.kernel.org/linux-next/20200909074130.GB561485@kroah.com/T/#t

So we are good here :)

Best regards,
Krzysztof

> Jonathan
> > ---
> >
> > Changes since v2:
> > 1. Wrap dev_err_probe() lines at 80 character
> >
> > Changes since v1:
> > 1. Convert to devm_clk_get_optional
> > 2. Update also stm32-dfsdm-core and stm32-dac-core.
> > 3. Wrap around 100 characters (accepted by checkpatch).
> > ---
> >  drivers/iio/adc/stm32-adc-core.c   | 75 ++++++++++--------------------
> >  drivers/iio/adc/stm32-adc.c        | 10 ++--
> >  drivers/iio/adc/stm32-dfsdm-adc.c  | 10 ++--
> >  drivers/iio/adc/stm32-dfsdm-core.c |  9 ++--
> >  drivers/iio/dac/stm32-dac-core.c   |  5 +-
> >  5 files changed, 35 insertions(+), 74 deletions(-)
> >
> > diff --git a/drivers/iio/adc/stm32-adc-core.c b/drivers/iio/adc/stm32-adc-core.c
> > index 0e2068ec068b..3f27b4817a42 100644
> > --- a/drivers/iio/adc/stm32-adc-core.c
> > +++ b/drivers/iio/adc/stm32-adc-core.c
> > @@ -582,11 +582,9 @@ static int stm32_adc_core_switches_probe(struct device *dev,
> >       priv->syscfg = syscon_regmap_lookup_by_phandle(np, "st,syscfg");
> >       if (IS_ERR(priv->syscfg)) {
> >               ret = PTR_ERR(priv->syscfg);
> > -             if (ret != -ENODEV) {
> > -                     if (ret != -EPROBE_DEFER)
> > -                             dev_err(dev, "Can't probe syscfg: %d\n", ret);
> > -                     return ret;
> > -             }
> > +             if (ret != -ENODEV)
> > +                     return dev_err_probe(dev, ret, "Can't probe syscfg\n");
> > +
> >               priv->syscfg = NULL;
> >       }
> >
> > @@ -596,12 +594,9 @@ static int stm32_adc_core_switches_probe(struct device *dev,
> >               priv->booster = devm_regulator_get_optional(dev, "booster");
> >               if (IS_ERR(priv->booster)) {
> >                       ret = PTR_ERR(priv->booster);
> > -                     if (ret != -ENODEV) {
> > -                             if (ret != -EPROBE_DEFER)
> > -                                     dev_err(dev, "can't get booster %d\n",
> > -                                             ret);
> > -                             return ret;
> > -                     }
> > +                     if (ret != -ENODEV)
> > +                             dev_err_probe(dev, ret, "can't get booster\n");
>
> This tripped a warning and got the patch dropped because we no longer
> return on error.

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

WARNING: multiple messages have this Message-ID (diff)
From: Krzysztof Kozlowski <krzk@kernel.org>
To: Jonathan Cameron <jic23@kernel.org>
Cc: Lars-Peter Clausen <lars@metafoo.de>,
	Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
	Michael Hennerich <Michael.Hennerich@analog.com>,
	linux-iio@vger.kernel.org,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	linux-stm32@st-md-mailman.stormreply.com,
	Marek Vasut <marek.vasut@gmail.com>,
	Andy Shevchenko <andy.shevchenko@gmail.com>,
	"linux-samsung-soc@vger.kernel.org"
	<linux-samsung-soc@vger.kernel.org>,
	Tomasz Duszynski <tomasz.duszynski@octakon.com>,
	linux-amlogic@lists.infradead.org, Peter Rosin <peda@axentia.se>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v3 08/18] iio: adc: stm32: Simplify with dev_err_probe()
Date: Wed, 9 Sep 2020 21:57:41 +0200	[thread overview]
Message-ID: <CAJKOXPeo8SXWaRmiFG6z+t9jcnaSMRpvRPm2X22Rf6rtEeKVew@mail.gmail.com> (raw)
In-Reply-To: <20200909193600.41970d8c@archlinux>

On Wed, 9 Sep 2020 at 20:36, Jonathan Cameron <jic23@kernel.org> wrote:
>
> On Sat, 29 Aug 2020 08:47:16 +0200
> Krzysztof Kozlowski <krzk@kernel.org> wrote:
>
> > Common pattern of handling deferred probe can be simplified with
> > dev_err_probe().  Less code and also it prints the error value.
> >
> > Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> > Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
> >
> I don't have the thread to hand, but this tripped a warning next
> and the patch was dropped as a result. See below.

Thanks for letting me know. If you mean the warning caused by:
https://lore.kernel.org/lkml/20200909073716.GA560912@kroah.com/
then the driver-core patch was dropped, not the iio one:
https://lore.kernel.org/linux-next/20200909074130.GB561485@kroah.com/T/#t

So we are good here :)

Best regards,
Krzysztof

> Jonathan
> > ---
> >
> > Changes since v2:
> > 1. Wrap dev_err_probe() lines at 80 character
> >
> > Changes since v1:
> > 1. Convert to devm_clk_get_optional
> > 2. Update also stm32-dfsdm-core and stm32-dac-core.
> > 3. Wrap around 100 characters (accepted by checkpatch).
> > ---
> >  drivers/iio/adc/stm32-adc-core.c   | 75 ++++++++++--------------------
> >  drivers/iio/adc/stm32-adc.c        | 10 ++--
> >  drivers/iio/adc/stm32-dfsdm-adc.c  | 10 ++--
> >  drivers/iio/adc/stm32-dfsdm-core.c |  9 ++--
> >  drivers/iio/dac/stm32-dac-core.c   |  5 +-
> >  5 files changed, 35 insertions(+), 74 deletions(-)
> >
> > diff --git a/drivers/iio/adc/stm32-adc-core.c b/drivers/iio/adc/stm32-adc-core.c
> > index 0e2068ec068b..3f27b4817a42 100644
> > --- a/drivers/iio/adc/stm32-adc-core.c
> > +++ b/drivers/iio/adc/stm32-adc-core.c
> > @@ -582,11 +582,9 @@ static int stm32_adc_core_switches_probe(struct device *dev,
> >       priv->syscfg = syscon_regmap_lookup_by_phandle(np, "st,syscfg");
> >       if (IS_ERR(priv->syscfg)) {
> >               ret = PTR_ERR(priv->syscfg);
> > -             if (ret != -ENODEV) {
> > -                     if (ret != -EPROBE_DEFER)
> > -                             dev_err(dev, "Can't probe syscfg: %d\n", ret);
> > -                     return ret;
> > -             }
> > +             if (ret != -ENODEV)
> > +                     return dev_err_probe(dev, ret, "Can't probe syscfg\n");
> > +
> >               priv->syscfg = NULL;
> >       }
> >
> > @@ -596,12 +594,9 @@ static int stm32_adc_core_switches_probe(struct device *dev,
> >               priv->booster = devm_regulator_get_optional(dev, "booster");
> >               if (IS_ERR(priv->booster)) {
> >                       ret = PTR_ERR(priv->booster);
> > -                     if (ret != -ENODEV) {
> > -                             if (ret != -EPROBE_DEFER)
> > -                                     dev_err(dev, "can't get booster %d\n",
> > -                                             ret);
> > -                             return ret;
> > -                     }
> > +                     if (ret != -ENODEV)
> > +                             dev_err_probe(dev, ret, "can't get booster\n");
>
> This tripped a warning and got the patch dropped because we no longer
> return on error.

_______________________________________________
linux-amlogic mailing list
linux-amlogic@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-amlogic

  reply	other threads:[~2020-09-09 19:57 UTC|newest]

Thread overview: 93+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-29  6:47 [PATCH v3 01/18] iio: accel: bma180: Simplify with dev_err_probe() Krzysztof Kozlowski
2020-08-29  6:47 ` Krzysztof Kozlowski
2020-08-29  6:47 ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 02/18] iio: accel: mma8452: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 03/18] iio: adc: envelope-detector: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29 21:28   ` Peter Rosin
2020-08-29 21:28     ` Peter Rosin
2020-08-29 21:28     ` Peter Rosin
2020-08-29  6:47 ` [PATCH v3 04/18] iio: adc: exynos_adc: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 05/18] iio: adc: ltc2497: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 06/18] iio: adc: meson_saradc: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29 14:48   ` Martin Blumenstingl
2020-08-29 14:48     ` Martin Blumenstingl
2020-08-29 14:48     ` Martin Blumenstingl
2020-08-29  6:47 ` [PATCH v3 07/18] iio: adc: rcar-gyroadc: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 08/18] iio: adc: stm32: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-09-09 18:36   ` Jonathan Cameron
2020-09-09 18:36     ` Jonathan Cameron
2020-09-09 18:36     ` Jonathan Cameron
2020-09-09 19:57     ` Krzysztof Kozlowski [this message]
2020-09-09 19:57       ` Krzysztof Kozlowski
2020-09-09 19:57       ` Krzysztof Kozlowski
2020-09-09 21:25       ` Peter Rosin
2020-09-09 21:25         ` Peter Rosin
2020-09-09 21:25         ` Peter Rosin
     [not found]         ` <CAHp75Vc4-zkkWtOz8w7pA0Vu1yMAVodhPSLQ1NJH4K+j9XD52g@mail.gmail.com>
2020-09-10  6:58           ` Krzysztof Kozlowski
2020-09-10  6:58             ` Krzysztof Kozlowski
2020-09-10  6:58             ` Krzysztof Kozlowski
2020-09-10  8:12             ` Jonathan Cameron
2020-09-10  8:12               ` Jonathan Cameron
2020-09-10  8:12               ` Jonathan Cameron
2020-09-10  8:36               ` Krzysztof Kozlowski
2020-09-10  8:36                 ` Krzysztof Kozlowski
2020-09-10  8:36                 ` Krzysztof Kozlowski
2020-09-10 11:23             ` Andy Shevchenko
2020-09-10 11:23               ` Andy Shevchenko
2020-09-10 11:23               ` Andy Shevchenko
2020-08-29  6:47 ` [PATCH v3 09/18] iio: afe: iio-rescale: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29 21:28   ` Peter Rosin
2020-08-29 21:28     ` Peter Rosin
2020-08-29 21:28     ` Peter Rosin
2020-08-29  6:47 ` [PATCH v3 10/18] iio: amplifiers: hmc425a: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 11/18] iio: chemical: scd30: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 12/18] iio: dac: dpot-dac: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29 21:29   ` Peter Rosin
2020-08-29 21:29     ` Peter Rosin
2020-08-29 21:29     ` Peter Rosin
2020-08-29  6:47 ` [PATCH v3 13/18] iio: imu: inv_mpu6050: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 14/18] iio: light: isl29018: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 15/18] iio: light: tsl2772: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 16/18] iio: magnetometer: ak8974: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 17/18] iio: magnetometer: mag3110: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47 ` [PATCH v3 18/18] iio: multiplexer: iio-mux: " Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29  6:47   ` Krzysztof Kozlowski
2020-08-29 21:30   ` Peter Rosin
2020-08-29 21:30     ` Peter Rosin
2020-08-29 21:30     ` Peter Rosin
2020-08-29 14:34 ` [PATCH v3 01/18] iio: accel: bma180: " Jonathan Cameron
2020-08-29 14:34   ` Jonathan Cameron
2020-08-29 14:34   ` Jonathan Cameron

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAJKOXPeo8SXWaRmiFG6z+t9jcnaSMRpvRPm2X22Rf6rtEeKVew@mail.gmail.com \
    --to=krzk@kernel.org \
    --cc=Michael.Hennerich@analog.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=jic23@kernel.org \
    --cc=lars@metafoo.de \
    --cc=linux-amlogic@lists.infradead.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=linux-stm32@st-md-mailman.stormreply.com \
    --cc=marek.vasut@gmail.com \
    --cc=peda@axentia.se \
    --cc=pmeerw@pmeerw.net \
    --cc=tomasz.duszynski@octakon.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.