* [PATCH -next] drm/logicvc: Fix error return code in logicvc_layer_init()
@ 2022-06-23 14:05 Yang Yingliang
2022-06-24 14:47 ` Paul Kocialkowski
0 siblings, 1 reply; 2+ messages in thread
From: Yang Yingliang @ 2022-06-23 14:05 UTC (permalink / raw)
To: linux-kernel, dri-devel; +Cc: paul.kocialkowski, airlied, daniel, mripard
Fix error return code when logicvc_layer_formats_lookup() fails.
Fixes: efeeaefe9be5 ("drm: Add support for the LogiCVC display controller")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
drivers/gpu/drm/logicvc/logicvc_layer.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/logicvc/logicvc_layer.c b/drivers/gpu/drm/logicvc/logicvc_layer.c
index fbebe966f93a..54b5931d879f 100644
--- a/drivers/gpu/drm/logicvc/logicvc_layer.c
+++ b/drivers/gpu/drm/logicvc/logicvc_layer.c
@@ -489,6 +489,7 @@ static int logicvc_layer_init(struct logicvc_drm *logicvc,
formats = logicvc_layer_formats_lookup(layer);
if (!formats) {
+ ret = -EINVAL;
drm_err(drm_dev, "Failed to lookup formats for layer #%d\n",
index);
goto error;
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH -next] drm/logicvc: Fix error return code in logicvc_layer_init()
2022-06-23 14:05 [PATCH -next] drm/logicvc: Fix error return code in logicvc_layer_init() Yang Yingliang
@ 2022-06-24 14:47 ` Paul Kocialkowski
0 siblings, 0 replies; 2+ messages in thread
From: Paul Kocialkowski @ 2022-06-24 14:47 UTC (permalink / raw)
To: Yang Yingliang; +Cc: linux-kernel, dri-devel, airlied, daniel, mripard
[-- Attachment #1: Type: text/plain, Size: 1169 bytes --]
Hi Yang,
On Thu 23 Jun 22, 22:05, Yang Yingliang wrote:
> Fix error return code when logicvc_layer_formats_lookup() fails.
>
> Fixes: efeeaefe9be5 ("drm: Add support for the LogiCVC display controller")
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Good catch! Yet Dan submitted a similar fix earlier, which is already
on its way to the tree.
Thanks!
Paul
> ---
> drivers/gpu/drm/logicvc/logicvc_layer.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/gpu/drm/logicvc/logicvc_layer.c b/drivers/gpu/drm/logicvc/logicvc_layer.c
> index fbebe966f93a..54b5931d879f 100644
> --- a/drivers/gpu/drm/logicvc/logicvc_layer.c
> +++ b/drivers/gpu/drm/logicvc/logicvc_layer.c
> @@ -489,6 +489,7 @@ static int logicvc_layer_init(struct logicvc_drm *logicvc,
>
> formats = logicvc_layer_formats_lookup(layer);
> if (!formats) {
> + ret = -EINVAL;
> drm_err(drm_dev, "Failed to lookup formats for layer #%d\n",
> index);
> goto error;
> --
> 2.25.1
>
--
Paul Kocialkowski, Bootlin
Embedded Linux and kernel engineering
https://bootlin.com
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-06-24 14:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-23 14:05 [PATCH -next] drm/logicvc: Fix error return code in logicvc_layer_init() Yang Yingliang
2022-06-24 14:47 ` Paul Kocialkowski
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).