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

Commit fc5a13d6 authored by Deepak Katragadda's avatar Deepak Katragadda
Browse files

msm: pil: Unregister modem notifer on failure to create kobj



Correct functionality to unregister the modem notifier if creating
a kobject for the audio voice service fails.

Change-Id: I51ddd33bcc6b69172cc006e599ab7182d39e4dbd
Signed-off-by: default avatarDeepak Katragadda <dkatraga@codeaurora.org>
parent 61a09d4a
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -479,7 +479,7 @@ static int pil_lpass_driver_probe(struct platform_device *pdev)
	if (!lpass_status) {
		pr_err("%s: kobject create failed\n", __func__);
		ret = -ENOMEM;
		goto err_notif_modem;
		goto err_create_kobj;
	}

	ret = sysfs_create_group(lpass_status, &attr_group);
@@ -492,6 +492,8 @@ static int pil_lpass_driver_probe(struct platform_device *pdev)
	return 0;
err_kobj:
	kobject_put(lpass_status);
err_create_kobj:
	subsys_notif_unregister_notifier(drv->modem_notif_hdle, &mnb);
err_notif_modem:
	subsys_notif_unregister_notifier(drv->wcnss_notif_hdle, &wnb);
err_notif_wcnss: