[PATCH 3/3] drm/rockchip: lvds: fix reference leak when pm_runtime_get_sync fails

2020-12-02 Thread Qinglang Miao
The PM reference count is not expected to be incremented on return in functions rk3288_lvds_poweron and px30_lvds_poweron. However, pm_runtime_get_sync will increment the PM reference count even failed. Forgetting to putting operation will result in a reference leak here. Replace it with pm_runti

[PATCH 3/3] drm/rockchip: lvds: fix reference leak when pm_runtime_get_sync fails

2020-12-01 Thread Qinglang Miao
pm_runtime_get_sync will increment pm usage counter even failed. Forgetting to putting operation will result in a reference leak here. Replace it with pm_runtime_resume_and_get to keep usage counter balanced. Fixes: cca1705c3d89 ("drm/rockchip: lvds: Add PX30 support") Reported-by: Hulk Robot Si