From: Lee Jones <lee.jones@linaro.org>
To: Philipp Zabel <p.zabel@pengutronix.de>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mfd: syscon: return ENOTSUPP instead of ENOSYS when disabled
Date: Thu, 11 Feb 2016 17:11:22 +0000 [thread overview]
Message-ID: <20160211171122.GI20693@x1> (raw)
In-Reply-To: <1454056939-16860-1-git-send-email-p.zabel@pengutronix.de>
On Fri, 29 Jan 2016, Philipp Zabel wrote:
> When CONFIG_MFD_SYSCON is disabled, have the function stubs return
> ENOTSUPP to indicate the syscon functionality is not available.
> There are currently no callers that depend on the ENOSYS return value.
>
> This patchfixes a checkpatch warning:
> WARNING: ENOSYS means 'invalid syscall nr' and nothing else
>
> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
> ---
> include/linux/mfd/syscon.h | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
Applied, thanks.
> diff --git a/include/linux/mfd/syscon.h b/include/linux/mfd/syscon.h
> index 75e543b..1088149 100644
> --- a/include/linux/mfd/syscon.h
> +++ b/include/linux/mfd/syscon.h
> @@ -29,24 +29,24 @@ extern struct regmap *syscon_regmap_lookup_by_phandle(
> #else
> static inline struct regmap *syscon_node_to_regmap(struct device_node *np)
> {
> - return ERR_PTR(-ENOSYS);
> + return ERR_PTR(-ENOTSUPP);
> }
>
> static inline struct regmap *syscon_regmap_lookup_by_compatible(const char *s)
> {
> - return ERR_PTR(-ENOSYS);
> + return ERR_PTR(-ENOTSUPP);
> }
>
> static inline struct regmap *syscon_regmap_lookup_by_pdevname(const char *s)
> {
> - return ERR_PTR(-ENOSYS);
> + return ERR_PTR(-ENOTSUPP);
> }
>
> static inline struct regmap *syscon_regmap_lookup_by_phandle(
> struct device_node *np,
> const char *property)
> {
> - return ERR_PTR(-ENOSYS);
> + return ERR_PTR(-ENOTSUPP);
> }
> #endif
>
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
prev parent reply other threads:[~2016-02-11 17:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-29 8:42 [PATCH] mfd: syscon: return ENOTSUPP instead of ENOSYS when disabled Philipp Zabel
2016-02-11 17:11 ` Lee Jones [this message]
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=20160211171122.GI20693@x1 \
--to=lee.jones@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=p.zabel@pengutronix.de \
/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