[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1374178035-19943-3-git-send-email-davidb@codeaurora.org>
Date: Thu, 18 Jul 2013 13:07:14 -0700
From: David Brown <davidb@...eaurora.org>
To: Grant Likely <grant.likely@...aro.org>,
Linus Walleij <linus.walleij@...aro.org>
Cc: Rohit Vaswani <rvaswani@...eaurora.org>,
linux-kernel@...r.kernel.org, linux-arm-msm@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, linux-gpio@...r.kernel.org,
"Bird, Tim" <Tim.Bird@...ymobile.com>,
David Brown <davidb@...eaurora.org>
Subject: [PATCH 2/3] drivers: gpio: msm: Fix the error condition for reading ngpio
From: Rohit Vaswani <rvaswani@...eaurora.org>
of_property_read_u32 return 0 on success. The check was using a ! to
return error. Fix the if condition.
Signed-off-by: Rohit Vaswani <rvaswani@...eaurora.org>
Acked-by: Linus Walleij <linus.walleij@...aro.org>
Reviewed-by: Pankaj Jangra <jangra.pankaj9@...il.com>
Cc: "Bird, Tim" <Tim.Bird@...ymobile.com>
Signed-off-by: David Brown <davidb@...eaurora.org>
---
drivers/gpio/gpio-msm-v2.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpio/gpio-msm-v2.c b/drivers/gpio/gpio-msm-v2.c
index f4491a4..c2fa770 100644
--- a/drivers/gpio/gpio-msm-v2.c
+++ b/drivers/gpio/gpio-msm-v2.c
@@ -378,7 +378,7 @@ static int msm_gpio_probe(struct platform_device *pdev)
int ret, ngpio;
struct resource *res;
- if (!of_property_read_u32(pdev->dev.of_node, "ngpio", &ngpio)) {
+ if (of_property_read_u32(pdev->dev.of_node, "ngpio", &ngpio)) {
dev_err(&pdev->dev, "%s: ngpio property missing\n", __func__);
return -EINVAL;
}
--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
hosted by The Linux Foundation
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists