From: Tomi Valkeinen <tomi.valkeinen@ti.com>
To: linux-fbdev@vger.kernel.org
Subject: Re: [PATCH -next] video: ARM CLCD: fix return value check in versatile_clcd_init_panel()
Date: Tue, 30 Aug 2016 08:37:43 +0000 [thread overview]
Message-ID: <f8e2377e-f078-3c9a-29fb-b5b45cf8f415@ti.com> (raw)
In-Reply-To: <1471051586-26189-1-git-send-email-weiyj.lk@gmail.com>
[-- Attachment #1.1: Type: text/plain, Size: 1127 bytes --]
On 13/08/16 04:26, Wei Yongjun wrote:
> In case of error, the function syscon_node_to_regmap() returns ERR_PTR()
> and never returns NULL. The NULL test in the return value check should
> be replaced with IS_ERR().
>
> Fixes: 25348160e9a4 ("video: ARM CLCD: add special panel hook for Versatiles")
> Signed-off-by: Wei Yongjun <weiyj.lk@gmail.com>
> ---
> drivers/video/fbdev/amba-clcd-versatile.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/video/fbdev/amba-clcd-versatile.c b/drivers/video/fbdev/amba-clcd-versatile.c
> index 9a90817..56161f9 100644
> --- a/drivers/video/fbdev/amba-clcd-versatile.c
> +++ b/drivers/video/fbdev/amba-clcd-versatile.c
> @@ -528,9 +528,9 @@ int versatile_clcd_init_panel(struct clcd_fb *fb,
> versatile_clcd_type = (enum versatile_clcd)clcd_id->data;
>
> map = syscon_node_to_regmap(np);
> - if (!map) {
> + if (IS_ERR(map)) {
> dev_err(dev, "no Versatile syscon regmap\n");
> - return -ENODEV;
> + return PTR_ERR(map);
> }
>
> switch (versatile_clcd_type) {
>
Thanks, queued for v4.9.
Tomi
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
prev parent reply other threads:[~2016-08-30 8:37 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-13 1:26 [PATCH -next] video: ARM CLCD: fix return value check in versatile_clcd_init_panel() Wei Yongjun
2016-08-19 9:07 ` Linus Walleij
2016-08-30 8:37 ` Tomi Valkeinen [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=f8e2377e-f078-3c9a-29fb-b5b45cf8f415@ti.com \
--to=tomi.valkeinen@ti.com \
--cc=linux-fbdev@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).