From: Sachin Kamat <sachin.kamat@linaro.org>
To: linux-kernel@vger.kernel.org
Cc: broonie@kernel.org, lgirdwood@gmail.com, sachin.kamat@linaro.org,
Laxman Dewangan <ldewangan@nvidia.com>
Subject: [PATCH 2/2] regulator: palmas: Fix incorrect condition
Date: Wed, 8 May 2013 16:09:06 +0530 [thread overview]
Message-ID: <1368009546-20770-2-git-send-email-sachin.kamat@linaro.org> (raw)
In-Reply-To: <1368009546-20770-1-git-send-email-sachin.kamat@linaro.org>
Since 'id' cannot take two values at the same time, the condition
should probably be an OR (||) instead of AND (&&).
Introduced by commit 28d1e8cd67 ("regulator: palma: add ramp delay
support through regulator constraints").
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Laxman Dewangan <ldewangan@nvidia.com>
---
Compile tested against for-next branch of regulator tree.
---
drivers/regulator/palmas-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/palmas-regulator.c b/drivers/regulator/palmas-regulator.c
index 92ceed0..ced7416 100644
--- a/drivers/regulator/palmas-regulator.c
+++ b/drivers/regulator/palmas-regulator.c
@@ -840,7 +840,7 @@ static int palmas_regulators_probe(struct platform_device *pdev)
break;
}
- if ((id == PALMAS_REG_SMPS6) && (id == PALMAS_REG_SMPS8))
+ if ((id == PALMAS_REG_SMPS6) || (id == PALMAS_REG_SMPS8))
ramp_delay_support = true;
if (ramp_delay_support) {
--
1.7.9.5
next prev parent reply other threads:[~2013-05-08 10:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-08 10:39 [PATCH 1/2] regulator: isl6271a: Use NULL instead of 0 Sachin Kamat
2013-05-08 10:39 ` Sachin Kamat [this message]
2013-05-10 11:11 ` [PATCH 2/2] regulator: palmas: Fix incorrect condition Mark Brown
2013-05-08 12:41 ` [PATCH 1/2] regulator: isl6271a: Use NULL instead of 0 Mark Brown
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=1368009546-20770-2-git-send-email-sachin.kamat@linaro.org \
--to=sachin.kamat@linaro.org \
--cc=broonie@kernel.org \
--cc=ldewangan@nvidia.com \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
/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
all inboxes | Powered by JetHome®