From: Philipp Zabel <p.zabel@pengutronix.de>
To: Alban Bedel <albeu@free.fr>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] reset: Fix of_reset_control_get() for consistent return values
Date: Wed, 02 Sep 2015 17:09:52 +0200 [thread overview]
Message-ID: <1441206592.3279.45.camel@pengutronix.de> (raw)
In-Reply-To: <1441121311-31628-1-git-send-email-albeu@free.fr>
Hi Alban,
Am Dienstag, den 01.09.2015, 17:28 +0200 schrieb Alban Bedel:
> When of_reset_control_get() is called without connection ID it returns
> -ENOENT when the 'resets' property doesn't exists or is an empty entry.
> However when a connection ID is given it returns -EINVAL when the 'resets'
> property doesn't exists or the requested name can't be found. This is
> because the error code returned by of_property_match_string() is just
> passed down as an index to of_parse_phandle_with_args(), which then
> returns -EINVAL.
Is that true? As far as I can see, since commit bd69f73f2c81
("of: Create function for counting number of phandles in a property")
it returns the (positive) number of entries if index is negative and the
'resets' property exists and parses correctly (before it would return
-ENOENT). If there are parsing errors, it can also return -EINVAL.
regards
Philipp
next prev parent reply other threads:[~2015-09-02 15:09 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-01 15:28 [PATCH] reset: Fix of_reset_control_get() for consistent return values Alban Bedel
2015-09-02 15:09 ` Philipp Zabel [this message]
2015-09-02 16:35 ` Alban
2015-09-03 9:49 ` Philipp Zabel
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=1441206592.3279.45.camel@pengutronix.de \
--to=p.zabel@pengutronix.de \
--cc=albeu@free.fr \
--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