]> git.baikalelectronics.ru Git - kernel.git/commit
drm/msm: Re-order uninit function to work during probe defer
authorSean Paul <seanpaul@chromium.org>
Fri, 24 May 2019 20:29:13 +0000 (16:29 -0400)
committerSean Paul <seanpaul@chromium.org>
Thu, 20 Jun 2019 21:00:50 +0000 (17:00 -0400)
commit6f7989b53ad2d67e71e053213c54c92841bb8217
treea80727101b6b242a079362ea3132e4d4737906b9
parent11479af648f97602d3135f46e0965dcbea4324df
drm/msm: Re-order uninit function to work during probe defer

If bind fails, we can call msm_drm_uninit before kms elements have been
created. In this case, drm_atomic_helper_shutdown will fail since there
are no drm objects. Only call drm unregistration and shutdown if drm is
registered.

Also while we're in here move the workqueue destruction to below
component_unbind since components could be actively using the wq during
uninit or in their unbind routine.

Reviewed-by: Rob Clark <robdclark@chromium.org>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20190524202919.179289-1-sean@poorly.run
drivers/gpu/drm/msm/msm_drv.c