[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1585562347-30214-1-git-send-email-dingxiang@cmss.chinamobile.com>
Date: Mon, 30 Mar 2020 17:59:07 +0800
From: Ding Xiang <dingxiang@...s.chinamobile.com>
To: oleksandr_andrushchenko@...m.com, airlied@...ux.ie, daniel@...ll.ch
Cc: dri-devel@...ts.freedesktop.org, xen-devel@...ts.xenproject.org,
linux-kernel@...r.kernel.org
Subject: [PATCH] drm/xen: fix passing zero to 'PTR_ERR' warning
Fix a static code checker warning:
drivers/gpu/drm/xen/xen_drm_front.c:404 xen_drm_drv_dumb_create()
warn: passing zero to 'PTR_ERR'
Signed-off-by: Ding Xiang <dingxiang@...s.chinamobile.com>
---
drivers/gpu/drm/xen/xen_drm_front.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/xen/xen_drm_front.c b/drivers/gpu/drm/xen/xen_drm_front.c
index 4be49c1..3741420 100644
--- a/drivers/gpu/drm/xen/xen_drm_front.c
+++ b/drivers/gpu/drm/xen/xen_drm_front.c
@@ -401,7 +401,7 @@ static int xen_drm_drv_dumb_create(struct drm_file *filp,
obj = xen_drm_front_gem_create(dev, args->size);
if (IS_ERR_OR_NULL(obj)) {
- ret = PTR_ERR(obj);
+ ret = PTR_ERR_OR_ZERO(obj);
goto fail;
}
--
1.9.1
Powered by blists - more mailing lists