venus: pm_helpers: Fix error check in vcodec_domains_get()
authorTang Bin <tangbin@cmss.chinamobile.com>
Tue, 13 Sep 2022 06:37:00 +0000 (14:37 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 31 Dec 2022 12:14:07 +0000 (13:14 +0100)
commit094f56192c568db17f4094021ed67e288a64d281
treefd8fd40e50e91a66fb8ec3d03837ac895c7fbead
parent3c793a9ad9d390504e4ec23467e4c40c5e65d38a
venus: pm_helpers: Fix error check in vcodec_domains_get()

[ Upstream commit 0f6e8d8c94a82e85e1b9b62a7671990740dc6f70 ]

In the function vcodec_domains_get(), dev_pm_domain_attach_by_name()
may return NULL in some cases, so IS_ERR() doesn't meet the
requirements. Thus fix it.

Fixes: 7482a983dea3 ("media: venus: redesign clocks and pm domains control")
Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/media/platform/qcom/venus/pm_helpers.c