disp: msm: sde: ensure input handler unregistration in command mode

Input handler is only registered in command mode, so add this change
to ensure that the input handler will be only unregistered in command
mode.

Change-Id: I15f652439339eee45b0ed3c011aa2922151f68ba
Signed-off-by: Lei Chen <chenlei@codeaurora.org>
This commit is contained in:
Lei Chen 2019-09-10 14:58:57 +08:00
commit e50cce2dfe

View file

@ -3336,7 +3336,8 @@ static void sde_encoder_virt_disable(struct drm_encoder *drm_enc)
/* wait for idle */
sde_encoder_wait_for_event(drm_enc, MSM_ENC_TX_COMPLETE);
if (sde_enc->input_handler)
if (sde_enc->input_handler &&
sde_encoder_check_curr_mode(drm_enc, MSM_DISPLAY_CMD_MODE))
input_unregister_handler(sde_enc->input_handler);
/*