[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1fc84a39-733e-5867-1f74-26a5076b18fc@broadcom.com>
Date: Tue, 9 Aug 2016 09:15:41 -0700
From: Ray Jui <ray.jui@...adcom.com>
To: Wolfram Sang <wsa-dev@...g-engineering.com>,
linux-kernel@...r.kernel.org
Cc: linux-i2c@...r.kernel.org, Jean Delvare <jdelvare@...e.com>,
Wolfram Sang <wsa@...-dreams.de>,
Ludovic Desroches <ludovic.desroches@...el.com>,
Ray Jui <rjui@...adcom.com>,
Scott Branden <sbranden@...adcom.com>,
Jon Mason <jonmason@...adcom.com>,
bcm-kernel-feedback-list@...adcom.com,
Florian Fainelli <f.fainelli@...il.com>,
Sonic Zhang <sonic.zhang@...log.com>,
Brian Norris <computersforpeace@...il.com>,
Gregory Fong <gregory.0xf0@...il.com>,
Michal Simek <michal.simek@...inx.com>,
Sören Brinkmann <soren.brinkmann@...inx.com>,
Jochen Friedrich <jochen@...am.de>,
Sekhar Nori <nsekhar@...com>,
Kevin Hilman <khilman@...nel.org>,
Guenter Roeck <linux@...ck-us.net>,
Uwe Kleine-König <kernel@...gutronix.de>,
Kukjin Kim <kgene@...nel.org>,
Krzysztof Kozlowski <k.kozlowski@...sung.com>,
Seth Heasley <seth.heasley@...el.com>,
Neil Horman <nhorman@...driver.com>,
Joachim Eastwood <manabian@...il.com>,
Carlo Caione <carlo@...one.org>,
Alessandro Rubini <rubini@...pv.it>,
Linus Walleij <linus.walleij@...aro.org>,
Peter Korsgaard <jacmet@...site.dk>,
Tony Lindgren <tony@...mide.com>,
Vladimir Zapolskiy <vz@...ia.com>,
Sylvain Lemieux <slemieux.tyco@...il.com>,
Guan Xuetao <gxt@...c.pku.edu.cn>,
Heiko Stuebner <heiko@...ech.de>,
Barry Song <baohua@...nel.org>,
Patrice Chotard <patrice.chotard@...com>,
Laxman Dewangan <ldewangan@...dia.com>,
Stephen Warren <swarren@...dotorg.org>,
Thierry Reding <thierry.reding@...il.com>,
Alexandre Courbot <gnurou@...il.com>,
Masahiro Yamada <yamada.masahiro@...ionext.com>,
Tony Prisk <linux@...sktech.co.nz>,
linux-arm-kernel@...ts.infradead.org,
adi-buildroot-devel@...ts.sourceforge.net,
linuxppc-dev@...ts.ozlabs.org, linux-samsung-soc@...r.kernel.org,
linux-amlogic@...ts.infradead.org, linux-omap@...r.kernel.org,
linux-rockchip@...ts.infradead.org, kernel@...inux.com,
linux-tegra@...r.kernel.org
Subject: Re: [PATCH] i2c: don't print error when adding adapter fails
Hi Wolfram,
On 8/9/2016 4:36 AM, Wolfram Sang wrote:
> The core will do this for us now.
>
> Signed-off-by: Wolfram Sang <wsa-dev@...g-engineering.com>
[...]
> diff --git a/drivers/i2c/busses/i2c-bcm-iproc.c b/drivers/i2c/busses/i2c-bcm-iproc.c
> index 19c843828fe2ca..8e3477f9297eda 100644
> --- a/drivers/i2c/busses/i2c-bcm-iproc.c
> +++ b/drivers/i2c/busses/i2c-bcm-iproc.c
> @@ -488,13 +488,7 @@ static int bcm_iproc_i2c_probe(struct platform_device *pdev)
> adap->dev.parent = &pdev->dev;
> adap->dev.of_node = pdev->dev.of_node;
>
> - ret = i2c_add_adapter(adap);
> - if (ret) {
> - dev_err(iproc_i2c->device, "failed to add adapter\n");
> - return ret;
> - }
> -
> - return 0;
> + return i2c_add_adapter(adap);
> }
>
> static int bcm_iproc_i2c_remove(struct platform_device *pdev)
> diff --git a/drivers/i2c/busses/i2c-bcm-kona.c b/drivers/i2c/busses/i2c-bcm-kona.c
> index ac9f47679c3a4b..a5c9098507896b 100644
> --- a/drivers/i2c/busses/i2c-bcm-kona.c
> +++ b/drivers/i2c/busses/i2c-bcm-kona.c
> @@ -858,10 +858,8 @@ static int bcm_kona_i2c_probe(struct platform_device *pdev)
> adap->dev.of_node = pdev->dev.of_node;
>
> rc = i2c_add_adapter(adap);
> - if (rc) {
> - dev_err(dev->device, "failed to add adapter\n");
> + if (rc)
> return rc;
> - }
>
> dev_info(dev->device, "device registered successfully\n");
>
For both i2c-bcm-iproc.c and i2c-bcm-kona.c:
Acked-by: Ray Jui <ray.jui@...adcom.com>
Thanks,
Ray
Powered by blists - more mailing lists