opp: Fix error check in dev_pm_opp_attach_genpd()
stable inclusion from stable-v5.10.137 commit e2a4e46f52584e43cd0d9866752b51f588cc1173 category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I60PLB Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=e2a4e46f52584e43cd0d9866752b51f588cc1173 -------------------------------- [ Upstream commit 4ea9496c ] dev_pm_domain_attach_by_name() may return NULL in some cases, so IS_ERR() doesn't meet the requirements. Thus fix it. Fixes: 6319aee1 ("opp: Attach genpds to devices from within OPP core") Signed-off-by:Tang Bin <tangbin@cmss.chinamobile.com> [ Viresh: Replace ENODATA with ENODEV ] Signed-off-by:
Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by:
Sasha Levin <sashal@kernel.org> Signed-off-by:
Zheng Zengkai <zhengzengkai@huawei.com> Reviewed-by:
Wei Li <liwei391@huawei.com>
Loading
Please sign in to comment