[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 9 Sep 2020 09:02:44 +0200
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: Krzysztof Kozlowski <krzk@...nel.org>
Cc: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Andrzej Hajda <a.hajda@...sung.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Joe Perches <joe@...ches.com>,
"Rafael J . Wysocki" <rafael@...nel.org>,
Stephen Rothwell <sfr@...b.auug.org.au>
Subject: Re: [PATCH v1] driver core: Annotate dev_err_probe() with
__must_check
On Wed, Sep 09, 2020 at 08:29:25AM +0200, Krzysztof Kozlowski wrote:
> On Wed, 26 Aug 2020 at 18:18, Joe Perches <joe@...ches.com> wrote:
> >
> > On Wed, 2020-08-26 at 18:55 +0300, Andy Shevchenko wrote:
> > > On Wed, Aug 26, 2020 at 08:44:30AM -0700, Joe Perches wrote:
> > > > On Wed, 2020-08-26 at 13:44 +0300, Andy Shevchenko wrote:
> > >
> > > ...
> > >
> > > > > -int dev_err_probe(const struct device *dev, int err, const char *fmt, ...);
> > > > > +int __must_check dev_err_probe(const struct device *dev, int err, const char *fmt, ...);
>
> +Cc Stephen and Greg,
>
> Hi Andy,
>
> Did this patch ended up in next somehow? I am surprised because now I
> got warnings for perfectly fine code:
> https://lore.kernel.org/linux-next/20200909155654.76fe3bd6@canb.auug.org.au/T/#u
>
> This creates simply false warnings instead of hints for "optimization".
Yes, it got merged into m y driver core tree.
I'll fix up the tty build warning, should be easy enough, the patch is
below.
thanks,
greg k-h
------------------
diff --git a/drivers/tty/serial/8250/8250_bcm2835aux.c b/drivers/tty/serial/8250/8250_bcm2835aux.c
index fd95860cd661..cd1880715bad 100644
--- a/drivers/tty/serial/8250/8250_bcm2835aux.c
+++ b/drivers/tty/serial/8250/8250_bcm2835aux.c
@@ -151,7 +151,7 @@ static int bcm2835aux_serial_probe(struct platform_device *pdev)
/* register the port */
ret = serial8250_register_8250_port(&up);
if (ret < 0) {
- dev_err_probe(&pdev->dev, ret, "unable to register 8250 port\n");
+ ret = dev_err_probe(&pdev->dev, ret, "unable to register 8250 port\n");
goto dis_clk;
}
data->line = ret;
Powered by blists - more mailing lists