Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9b9c87cf authored by Dan Carpenter's avatar Dan Carpenter Committed by Greg Kroah-Hartman
Browse files

staging: vc04_services: Fix an error code in vchiq_probe()



We need to set "err" on this error path.

Fixes: 187ac53e ("staging: vchiq_arm: rework probe and init functions")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Acked-by: default avatarStefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent b6391ac7
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -3513,6 +3513,7 @@ static int vchiq_probe(struct platform_device *pdev)
	struct device_node *fw_node;
	const struct of_device_id *of_id;
	struct vchiq_drvdata *drvdata;
	struct device *vchiq_dev;
	int err;

	of_id = of_match_node(vchiq_of_match, pdev->dev.of_node);
@@ -3547,9 +3548,12 @@ static int vchiq_probe(struct platform_device *pdev)
		goto failed_platform_init;
	}

	if (IS_ERR(device_create(vchiq_class, &pdev->dev, vchiq_devid,
				 NULL, "vchiq")))
	vchiq_dev = device_create(vchiq_class, &pdev->dev, vchiq_devid, NULL,
				  "vchiq");
	if (IS_ERR(vchiq_dev)) {
		err = PTR_ERR(vchiq_dev);
		goto failed_device_create;
	}

	vchiq_debugfs_init();