Fix unreachable code when using pass_pmqos_exit() by returning the
error code if failed. Before this patch, the usage code of
pass_pmqos_exit() is not able to receive the any error code.
Change-Id: I4034bcc7e6ef57e5d284d919acd4e469634c637b
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
int pass_pmqos_exit(struct pass_resource *res)
{
+ if (!res)
+ return -EINVAL;
+
/* Un-register DEVICE_NOTIFIER_PMQOS */
unregister_notifier(DEVICE_NOTIFIER_PMQOS, pmqos_notifier_cb, res);