From: David Cohen <david.a.cohen@linux.intel.com>
To: linus.walleij@linaro.org, gnurou@gmail.com
Cc: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
"xinhui.pan" <xinhuiX.pan@intel.com>, "bo.he" <bo.he@intel.com>,
David Cohen <david.a.cohen@linux.intel.com>,
Felibe Balbi <balbi@ti.com>
Subject: [PATCH v2] gpio-intel-mid: fix the incorrect return of idle callback
Date: Fri, 31 Jan 2014 13:08:01 -0800 [thread overview]
Message-ID: <1391202481-19533-1-git-send-email-david.a.cohen@linux.intel.com> (raw)
In-Reply-To: <20140131205007.GB26770@psi-dev26.jf.intel.com>
From: "xinhui.pan" <xinhuiX.pan@intel.com>
intel_gpio_runtime_idle should return correct error code if it do fail.
make it more correct even though -EBUSY is the most possible return value.
Signed-off-by: bo.he <bo.he@intel.com>
Signed-off-by: xinhui.pan <xinhuiX.pan@intel.com>
Signed-off-by: David Cohen <david.a.cohen@linux.intel.com>
Cc: Felibe Balbi <balbi@ti.com>
---
drivers/gpio/gpio-intel-mid.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpio/gpio-intel-mid.c b/drivers/gpio/gpio-intel-mid.c
index 41218e93b9fe..55688d0548e9 100644
--- a/drivers/gpio/gpio-intel-mid.c
+++ b/drivers/gpio/gpio-intel-mid.c
@@ -369,8 +369,8 @@ static const struct irq_domain_ops intel_gpio_irq_ops = {
static int intel_gpio_runtime_idle(struct device *dev)
{
- pm_schedule_suspend(dev, 500);
- return -EBUSY;
+ int err = pm_schedule_suspend(dev, 500);
+ return err ?: -EBUSY;
}
static const struct dev_pm_ops intel_gpio_pm_ops = {
--
1.8.4.2
next prev parent reply other threads:[~2014-01-31 21:02 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-30 12:15 [PATCH] gpio-intel-mid: fix the incorrect return of idle callback xinhui.pan
2014-01-31 20:50 ` David Cohen
2014-01-31 21:08 ` David Cohen [this message]
2014-01-31 21:26 ` [PATCH v2] " Felipe Balbi
2014-02-05 9:37 ` Linus Walleij
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=1391202481-19533-1-git-send-email-david.a.cohen@linux.intel.com \
--to=david.a.cohen@linux.intel.com \
--cc=balbi@ti.com \
--cc=bo.he@intel.com \
--cc=gnurou@gmail.com \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=xinhuiX.pan@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).