From: Tony Lindgren <tony@atomide.com>
To: Duan Jiong <duanj.fnst@cn.fujitsu.com>
Cc: khilman@deeprootsystems.com, linux@arm.linux.org.uk,
linux-omap@vger.kernel.org
Subject: Re: [PATCH] ARM: OMAP2+: gpmc: fix: replace PTR_RET with PTR_ERR_OR_ZERO
Date: Fri, 18 Apr 2014 15:49:19 -0700 [thread overview]
Message-ID: <20140418224919.GO21823@atomide.com> (raw)
In-Reply-To: <1397210608-28318-1-git-send-email-duanj.fnst@cn.fujitsu.com>
* Duan Jiong <duanj.fnst@cn.fujitsu.com> [140411 03:10]:
> PTR_RET is deprecated. Do not recommend its usage anymore.
> Use PTR_ERR_OR_ZERO instead.
>
> Signed-off-by: Duan Jiong <duanj.fnst@cn.fujitsu.com>
> ---
> arch/arm/mach-omap2/gpmc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arm/mach-omap2/gpmc.c b/arch/arm/mach-omap2/gpmc.c
> index ab43755..6a11bda 100644
> --- a/arch/arm/mach-omap2/gpmc.c
> +++ b/arch/arm/mach-omap2/gpmc.c
> @@ -1772,7 +1772,7 @@ static int __init omap_gpmc_init(void)
> pdev = omap_device_build(DEVICE_NAME, -1, oh, NULL, 0);
> WARN(IS_ERR(pdev), "could not build omap_device for %s\n", oh_name);
>
> - return PTR_RET(pdev);
> + return PTR_ERR_OR_ZERO(pdev);
> }
> omap_postcore_initcall(omap_gpmc_init);
OK looks like we have #define PTR_RET(p) PTR_ERR_OR_ZERO(p).
But what about the others? How about a single patch to deal
with them all?
$ git grep PTR_RET arch/arm/*omap*
arch/arm/mach-omap2/devices.c: return PTR_RET(pdev);
arch/arm/mach-omap2/devices.c: return PTR_RET(pdev);
arch/arm/mach-omap2/fb.c: return PTR_RET(pdev);
arch/arm/mach-omap2/pmu.c: return PTR_RET(omap_pmu_dev);
Regards,
Tony
prev parent reply other threads:[~2014-04-18 22:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-11 10:03 [PATCH] ARM: OMAP2+: gpmc: fix: replace PTR_RET with PTR_ERR_OR_ZERO Duan Jiong
2014-04-18 22:49 ` Tony Lindgren [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=20140418224919.GO21823@atomide.com \
--to=tony@atomide.com \
--cc=duanj.fnst@cn.fujitsu.com \
--cc=khilman@deeprootsystems.com \
--cc=linux-omap@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
/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).