From: Jonathan Cameron <jic23@kernel.org>
To: "Guido Günther" <agx@sigxcpu.org>
Cc: Tomas Novotny <tomas@novotny.cz>,
Hartmut Knaack <knaack.h@gmx.de>,
Lars-Peter Clausen <lars@metafoo.de>,
Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
"Angus Ainslie (Purism)" <angus@akkea.ca>,
Marco Felsch <m.felsch@pengutronix.de>,
Thomas Gleixner <tglx@linutronix.de>,
linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] iio: vncl4000: Fix early return in vcnl4200_set_power_state
Date: Sat, 8 Feb 2020 14:17:13 +0000 [thread overview]
Message-ID: <20200208141713.469fb174@archlinux> (raw)
In-Reply-To: <19efdcd597b21ece9ad0ff894b6566d2ef4e2c02.1581066317.git.agx@sigxcpu.org>
On Fri, 7 Feb 2020 10:12:09 +0100
Guido Günther <agx@sigxcpu.org> wrote:
> Don't return early unconditionally.
>
> Signed-off-by: Guido Günther <agx@sigxcpu.org>
> Reported-by: kbuild test robot <lkp@intel.com>
> Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
I've merged this down into the original patch.
Thanks,
Jonathan
>
> ---
> I've not added a 'Fixes:' line since this is not part of Linus tree yet.
> Tested proximity and ambient light on a vcnl4040 and checked the driver
> suspends/resumes correctly and puts out valid data right after resume.
>
> drivers/iio/light/vcnl4000.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/iio/light/vcnl4000.c b/drivers/iio/light/vcnl4000.c
> index 3b71c7d538af..38fcd9a26046 100644
> --- a/drivers/iio/light/vcnl4000.c
> +++ b/drivers/iio/light/vcnl4000.c
> @@ -149,7 +149,7 @@ static int vcnl4200_set_power_state(struct vcnl4000_data *data, bool on)
> if (ret < 0)
> return ret;
>
> - return i2c_smbus_write_word_data(data->client, VCNL4200_PS_CONF1, val);
> + ret = i2c_smbus_write_word_data(data->client, VCNL4200_PS_CONF1, val);
> if (ret < 0)
> return ret;
>
next prev parent reply other threads:[~2020-02-08 14:17 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-07 9:12 [PATCH] iio: vncl4000: Fix early return in vcnl4200_set_power_state Guido Günther
2020-02-07 19:45 ` Matt Ranostay
2020-02-08 14:17 ` Jonathan Cameron [this message]
2020-02-10 15:41 ` Exposing device properties for priximity sensors Guido Günther
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=20200208141713.469fb174@archlinux \
--to=jic23@kernel.org \
--cc=agx@sigxcpu.org \
--cc=angus@akkea.ca \
--cc=knaack.h@gmx.de \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=m.felsch@pengutronix.de \
--cc=pmeerw@pmeerw.net \
--cc=tglx@linutronix.de \
--cc=tomas@novotny.cz \
/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).