Commit 5d2883d5 authored by Fabio Estevam's avatar Fabio Estevam Committed by Stefan Agner

drm/fsl-dcu: remove unneeded 'ret' assignment

When devm_kzalloc() fails there is no need to assign an error code
to the 'ret' variable as it will not be used after jumping to the
'err_node_put' label, so just remove the assignment.
Signed-off-by: default avatarFabio Estevam <fabio.estevam@nxp.com>
Reviewed-by: default avatarGabriel Krisman Bertazi <krisman@collabora.co.uk>
Signed-off-by: default avatarStefan Agner <stefan@agner.ch>
parent 4eaa39c6
......@@ -72,10 +72,8 @@ struct fsl_tcon *fsl_tcon_init(struct device *dev)
return NULL;
tcon = devm_kzalloc(dev, sizeof(*tcon), GFP_KERNEL);
if (!tcon) {
ret = -ENOMEM;
if (!tcon)
goto err_node_put;
}
ret = fsl_tcon_init_regmap(dev, tcon, np);
if (ret) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment