linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jean Delvare <khali@linux-fr.org>
To: Lars-Peter Clausen <lars@metafoo.de>
Cc: Wolfram Sang <wsa@the-dreams.de>, Ben Dooks <ben-linux@fluff.org>,
	linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org,
	Guan Xuetao <gxt@mprc.pku.edu.cn>,
	Mauro Carvalho Chehab <mchehab@redhat.com>,
	Ben Hutchings <bhutchings@solarflare.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Alan Cox <alan@linux.intel.com>,
	Nicolas Ferre <nicolas.ferre@atmel.com>,
	Aaro Koskinen <aaro.koskinen@iki.fi>,
	Shawn Guo <shawn.guo@linaro.org>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Lars Poeschel <poeschel@lemonage.de>
Subject: Re: [PATCH 3/6] i2c: Ignore return value of i2c_del_adapter()
Date: Sun, 31 Mar 2013 10:25:47 +0200	[thread overview]
Message-ID: <20130331102547.4d5d2e4c@endymion.delvare> (raw)
In-Reply-To: <1362853009-20789-4-git-send-email-lars@metafoo.de>

On Sat,  9 Mar 2013 19:16:46 +0100, Lars-Peter Clausen wrote:
> i2c_del_adapter() always returns 0. So all checks testing whether it will be
> non zero will always evaluate to false and the conditional code is dead code.
> This patch updates all callers of i2c_del_mux_adapter() to ignore the return
> value and assume that it will always succeed (which it will). In a subsequent
> patch the return type of i2c_del_adapter() will be made void.
> 
> Cc: Jean Delvare <khali@linux-fr.org>
> Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
> Cc: Mauro Carvalho Chehab <mchehab@redhat.com>
> Cc: Ben Hutchings <bhutchings@solarflare.com>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: Alan Cox <alan@linux.intel.com>
> Cc: Nicolas Ferre <nicolas.ferre@atmel.com>
> Cc: Aaro Koskinen <aaro.koskinen@iki.fi>
> Cc: Marek Vasut <marex@denx.de> (commit_signer:11/20=55%)
> Cc: Shawn Guo <shawn.guo@linaro.org>
> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
> Cc: Lars Poeschel <poeschel@lemonage.de>
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> ---
>  drivers/gpu/drm/gma500/oaktrail_hdmi_i2c.c   |  3 +--
>  drivers/i2c/busses/i2c-amd756-s4882.c        |  6 +-----
>  drivers/i2c/busses/i2c-at91.c                |  5 ++---
>  drivers/i2c/busses/i2c-cbus-gpio.c           |  4 +++-
>  drivers/i2c/busses/i2c-intel-mid.c           |  3 +--
>  drivers/i2c/busses/i2c-mv64xxx.c             |  5 ++---
>  drivers/i2c/busses/i2c-mxs.c                 |  5 +----
>  drivers/i2c/busses/i2c-nforce2-s4985.c       |  6 +-----
>  drivers/i2c/busses/i2c-powermac.c            | 10 ++--------
>  drivers/i2c/busses/i2c-puv3.c                | 10 ++--------
>  drivers/i2c/busses/i2c-viperboard.c          |  5 ++---
>  drivers/i2c/i2c-mux.c                        |  5 +----
>  drivers/media/pci/bt8xx/bttv-input.c         |  6 +++---
>  drivers/media/pci/mantis/mantis_i2c.c        |  4 +++-
>  drivers/net/ethernet/sfc/falcon.c            |  6 ++----
>  drivers/staging/media/go7007/go7007-driver.c |  7 ++-----
>  16 files changed, 29 insertions(+), 61 deletions(-)
> (...)

For i2c-amd756-s4882, i2c-nforce2-s4985 and i2c-mux:

Reviewed-by: Jean Delvare <khali@linux-fr.org>

-- 
Jean Delvare

  reply	other threads:[~2013-03-31  8:25 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-09 18:16 [PATCH 0/6] Make return type of i2c_del_adapter() (and i2c_del_mux_adapter()) void Lars-Peter Clausen
2013-03-09 18:16 ` [PATCH 1/6] i2c: Remove detach_adapter Lars-Peter Clausen
     [not found]   ` <1362853009-20789-2-git-send-email-lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-30 14:52     ` Jean Delvare
2013-03-09 18:16 ` [PATCH 2/6] i2c: i2c_del_adapter: Don't treat removing a non-registered adapter as error Lars-Peter Clausen
     [not found]   ` <1362853009-20789-3-git-send-email-lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-30 18:17     ` Jean Delvare
2013-03-09 18:16 ` [PATCH 3/6] i2c: Ignore return value of i2c_del_adapter() Lars-Peter Clausen
2013-03-31  8:25   ` Jean Delvare [this message]
     [not found]   ` <1362853009-20789-4-git-send-email-lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-11 17:52     ` Ben Hutchings
2013-03-30  6:34     ` Wolfram Sang
2013-03-30  7:55     ` Jean Delvare
     [not found]       ` <20130330085539.442321fa-R0o5gVi9kd7kN2dkZ6Wm7A@public.gmane.org>
2013-03-30  8:11         ` Lars-Peter Clausen
     [not found]           ` <51569E4A.2080006-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-30  8:43             ` Jean Delvare
2013-03-31 13:12     ` Shawn Guo
2013-03-09 18:16 ` [PATCH 4/6] i2c: Make return type of i2c_del_adapter() void Lars-Peter Clausen
     [not found]   ` <1362853009-20789-5-git-send-email-lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-31  9:04     ` Jean Delvare
2013-03-09 18:16 ` [PATCH 5/6] i2c: Ignore the return value of i2c_del_mux_adapter() Lars-Peter Clausen
     [not found]   ` <1362853009-20789-6-git-send-email-lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-13  6:05     ` [5/6] " Guenter Roeck
2013-03-31  9:23     ` [PATCH 5/6] " Jean Delvare
2013-03-09 18:16 ` [PATCH 6/6] i2c: Make the return type of i2c_del_mux_adapter() void Lars-Peter Clausen
     [not found]   ` <1362853009-20789-7-git-send-email-lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-31  9:24     ` Jean Delvare
2013-03-30  6:33 ` [PATCH 0/6] Make return type of i2c_del_adapter() (and i2c_del_mux_adapter()) void Wolfram Sang
     [not found] ` <1362853009-20789-1-git-send-email-lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-30 20:13   ` Jean Delvare
2013-03-30 20:43     ` Lars-Peter Clausen
     [not found]       ` <51574E71.7010403-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2013-03-31  7:56         ` Jean Delvare
2013-03-31 11:30   ` Jean Delvare
2013-04-02  5:09   ` Wolfram Sang

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=20130331102547.4d5d2e4c@endymion.delvare \
    --to=khali@linux-fr.org \
    --cc=aaro.koskinen@iki.fi \
    --cc=alan@linux.intel.com \
    --cc=ben-linux@fluff.org \
    --cc=benh@kernel.crashing.org \
    --cc=bhutchings@solarflare.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=gxt@mprc.pku.edu.cn \
    --cc=lars@metafoo.de \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mchehab@redhat.com \
    --cc=nicolas.ferre@atmel.com \
    --cc=poeschel@lemonage.de \
    --cc=shawn.guo@linaro.org \
    --cc=wsa@the-dreams.de \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).