mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-10 22:40:54 -04:00
disp: msm: dp: avoid use of mst_lock in hpd callbacks
DP MST driver registers bridge callback functions with the DRM framework. mst_lock is used for synchronization of the mst bridge functions. These functions call into dp_display where a session lock is obtained for the display. HPD callbacks, on the other hand, are first handled by dp_display. During these callbacks, dp_display takes a session lock first before calling into DP MST driver layer. Currently, the DP MST layer waits on mst_lock which can result in a deadlock. This change removes the usage of mst_lock inside hpd callback functions and just uses the session lock for synchronization. Change-Id: I7ec338004eef43ac0f1e1f092463e9915cd60684 Signed-off-by: Rajkumar Subbiah <rsubbia@codeaurora.org>
This commit is contained in:
parent
c7464588de
commit
b240ae79e4
1 changed files with 2 additions and 8 deletions
|
|
@ -2163,11 +2163,8 @@ static int dp_mst_display_set_mgr_state(void *dp_display, bool state,
|
|||
* on hpd_low, set_mgr_state is called after hotplug event is sent and
|
||||
* the session_state was already updated prior to that.
|
||||
*/
|
||||
if (state) {
|
||||
mutex_lock(&mst->mst_lock);
|
||||
if (state)
|
||||
mst->mst_session_state = state;
|
||||
mutex_unlock(&mst->mst_lock);
|
||||
}
|
||||
|
||||
if (info && !info->mst_protocol) {
|
||||
if (state) {
|
||||
|
|
@ -2201,11 +2198,8 @@ static void dp_mst_display_hpd(void *dp_display, bool hpd_status)
|
|||
* session state should be unset here for the connection status to be
|
||||
* updated accordingly.
|
||||
*/
|
||||
if (!hpd_status) {
|
||||
mutex_lock(&mst->mst_lock);
|
||||
if (!hpd_status)
|
||||
mst->mst_session_state = hpd_status;
|
||||
mutex_unlock(&mst->mst_lock);
|
||||
}
|
||||
|
||||
dp_mst_hpd_event_notify(mst, hpd_status);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue