From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Bjorn Andersson <bjorn.andersson@linaro.org>,
Andy Gross <agross@kernel.org>,
linux-arm-msm@vger.kernel.org,
Linus Walleij <linus.walleij@linaro.org>,
linux-gpio@vger.kernel.org
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Subject: [PATCH v1 2/2] pinctrl: qdf2xxx: Switch to use device_property_count_uXX()
Date: Tue, 23 Jul 2019 22:27:38 +0300 [thread overview]
Message-ID: <20190723192738.68486-2-andriy.shevchenko@linux.intel.com> (raw)
In-Reply-To: <20190723192738.68486-1-andriy.shevchenko@linux.intel.com>
Use use device_property_count_uXX() directly, that makes code neater.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/pinctrl/qcom/pinctrl-qdf2xxx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pinctrl/qcom/pinctrl-qdf2xxx.c b/drivers/pinctrl/qcom/pinctrl-qdf2xxx.c
index 5da5dd51542c..43bd15f16377 100644
--- a/drivers/pinctrl/qcom/pinctrl-qdf2xxx.c
+++ b/drivers/pinctrl/qcom/pinctrl-qdf2xxx.c
@@ -52,7 +52,7 @@ static int qdf2xxx_pinctrl_probe(struct platform_device *pdev)
}
/* The number of GPIOs in the approved list */
- ret = device_property_read_u8_array(&pdev->dev, "gpios", NULL, 0);
+ ret = device_property_count_u8(&pdev->dev, "gpios");
if (ret < 0) {
dev_err(&pdev->dev, "missing 'gpios' property\n");
return ret;
--
2.20.1
next prev parent reply other threads:[~2019-07-23 19:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-23 19:27 [PATCH v1 1/2] pinctrl: msm: Switch to use device_property_count_uXX() Andy Shevchenko
2019-07-23 19:27 ` Andy Shevchenko [this message]
2019-08-05 10:02 ` [PATCH v1 2/2] pinctrl: qdf2xxx: " Linus Walleij
2019-08-05 10:24 ` Andy Shevchenko
2019-08-05 10:01 ` [PATCH v1 1/2] pinctrl: msm: " Linus Walleij
2019-08-05 10:24 ` Andy Shevchenko
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=20190723192738.68486-2-andriy.shevchenko@linux.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=agross@kernel.org \
--cc=bjorn.andersson@linaro.org \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-gpio@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;
as well as URLs for NNTP newsgroup(s).