cpufreq: mediatek: add missing platform_driver_unregister() on error in mtk_cpufreq_d...
authorQinglang Miao <miaoqinglang@huawei.com>
Sat, 31 Oct 2020 01:18:54 +0000 (09:18 +0800)
committerViresh Kumar <viresh.kumar@linaro.org>
Mon, 7 Dec 2020 07:32:37 +0000 (13:02 +0530)
commit2f05c19d9ef4f5a42634f83bdb0db596ffc0dd30
tree5887c0972b3e72805d0883ee8f69235ccaf0fae8
parent68b9cd7270f0191bd51b635f8f4778951ee3811a
cpufreq: mediatek: add missing platform_driver_unregister() on error in mtk_cpufreq_driver_init

Add the missing platform_driver_unregister() before return from
mtk_cpufreq_driver_init in the error handling case when failed
to register mtk-cpufreq platform device

Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
drivers/cpufreq/mediatek-cpufreq.c