diff options
author | Yang Yingliang <yangyingliang@huawei.com> | 2022-06-14 14:21:12 +0300 |
---|---|---|
committer | Paul Kocialkowski <paul.kocialkowski@bootlin.com> | 2022-06-24 18:23:38 +0300 |
commit | e9fcc60ddd29994a8b2a276ee9b454d7cd449194 (patch) | |
tree | 643b00f5b64ea28afeb6bfab77835dd942001624 /drivers/gpu/drm/logicvc | |
parent | d3a453416270f5c7f1bf409597d702a2230e5a6c (diff) | |
download | linux-e9fcc60ddd29994a8b2a276ee9b454d7cd449194.tar.xz |
drm/logicvc: add missing of_node_put() in logicvc_layers_init()
The of_node_put() need be called in error path in logicvc_layers_init().
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>
Signed-off-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220614112112.1537319-1-yangyingliang@huawei.com
Diffstat (limited to 'drivers/gpu/drm/logicvc')
-rw-r--r-- | drivers/gpu/drm/logicvc/logicvc_layer.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/logicvc/logicvc_layer.c b/drivers/gpu/drm/logicvc/logicvc_layer.c index 31c5c42f0ac6..441e3cfce4cf 100644 --- a/drivers/gpu/drm/logicvc/logicvc_layer.c +++ b/drivers/gpu/drm/logicvc/logicvc_layer.c @@ -613,8 +613,10 @@ int logicvc_layers_init(struct logicvc_drm *logicvc) } ret = logicvc_layer_init(logicvc, layer_node, index); - if (ret) + if (ret) { + of_node_put(layers_node); goto error; + } } of_node_put(layers_node); |