From: Jonathan Cameron <jic23@kernel.org>
To: Irina Tirdea <irina.tirdea@intel.com>, linux-iio@vger.kernel.org
Cc: Peter Meerwald <pmeerw@pmeerw.net>,
Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>,
Daniel Baluta <daniel.baluta@intel.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/4] iio: accel: kxcjk-1013: always power on device in resume
Date: Sat, 06 Dec 2014 11:15:44 +0000 [thread overview]
Message-ID: <5482E560.2090707@kernel.org> (raw)
In-Reply-To: <1417817890-10252-2-git-send-email-irina.tirdea@intel.com>
On 05/12/14 22:18, Irina Tirdea wrote:
> When the system resumes, it will first call system resume and
> then runtime suspend (if CONFIG_RUNTIME_PM is enabled).
> There is no need to conditionally power on the device in
> system resume, so always power it on and leave runtime
> suspend to power it off if needed.
>
> Suggested-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
> Signed-off-by: Irina Tirdea <irina.tirdea@intel.com>
> Reviewed-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Applied to the togreg branch of iio.git
Thanks,
> ---
> drivers/iio/accel/kxcjk-1013.c | 5 +----
> 1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/drivers/iio/accel/kxcjk-1013.c b/drivers/iio/accel/kxcjk-1013.c
> index 1720e9a..aed3777 100644
> --- a/drivers/iio/accel/kxcjk-1013.c
> +++ b/drivers/iio/accel/kxcjk-1013.c
> @@ -1354,10 +1354,7 @@ static int kxcjk1013_resume(struct device *dev)
> int ret = 0;
>
> mutex_lock(&data->mutex);
> - /* Check, if the suspend occured while active */
> - if (data->dready_trigger_on || data->motion_trigger_on ||
> - data->ev_enable_state)
> - ret = kxcjk1013_set_mode(data, OPERATION);
> + ret = kxcjk1013_set_mode(data, OPERATION);
> mutex_unlock(&data->mutex);
>
> return ret;
>
next prev parent reply other threads:[~2014-12-06 11:15 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-05 22:18 [PATCH 0/4] PM fixes for kxcjk-1013 Irina Tirdea
2014-12-05 22:18 ` [PATCH 1/4] iio: accel: kxcjk-1013: always power on device in resume Irina Tirdea
2014-12-06 11:15 ` Jonathan Cameron [this message]
2014-12-05 22:18 ` [PATCH 2/4] iio: accel: kxcjk-1013: only set power state if CONFIG_PM is defined Irina Tirdea
2014-12-06 11:16 ` Jonathan Cameron
2014-12-05 22:18 ` [PATCH 3/4] iio: accel: kxcjk-1013: error handling when set mode fails Irina Tirdea
2014-12-06 11:11 ` Jonathan Cameron
2014-12-05 22:18 ` [PATCH 4/4] iio: accel: kxcjk-1013: power off device if probe fails Irina Tirdea
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=5482E560.2090707@kernel.org \
--to=jic23@kernel.org \
--cc=daniel.baluta@intel.com \
--cc=irina.tirdea@intel.com \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pmeerw@pmeerw.net \
--cc=srinivas.pandruvada@linux.intel.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 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).