disp: msm: sde: remove HARD_RESET recovery event on frame-timeouts only

On frame timeouts, the driver should only be responsible for
reporting the error event to user space clients. Handling of
the error events should be left to the user space clients.

This change removes explicit mechanism in SDE driver to track
error events for a pre-defined threshold levels and RESET hints
sent to the user space on handling those error events during
frame timeouts.

Change-Id: I7bdf2495fae6430384b4031a7edf043b6efe88c5
Signed-off-by: Jeykumar Sankaran <jsanka@codeaurora.org>
Esse commit está contido em:
Jeykumar Sankaran
2020-10-12 23:16:01 -07:00
commit de Veera Sundaram Sankaran
commit 46e0ac3354
2 arquivos alterados com 7 adições e 21 exclusões

Ver arquivo

@@ -26,9 +26,6 @@
#define to_sde_encoder_phys_vid(x) \
container_of(x, struct sde_encoder_phys_vid, base)
/* maximum number of consecutive kickoff errors */
#define KICKOFF_MAX_ERRORS 2
/* Poll time to do recovery during active region */
#define POLL_TIME_USEC_FOR_LN_CNT 500
#define MAX_POLL_CNT 10
@@ -931,7 +928,6 @@ static int sde_encoder_phys_vid_prepare_for_kickoff(
struct sde_hw_ctl *ctl;
bool recovery_events;
struct drm_connector *conn;
int event;
int rc;
if (!phys_enc || !params || !phys_enc->hw_ctl) {
@@ -973,15 +969,11 @@ static int sde_encoder_phys_vid_prepare_for_kickoff(
* if the recovery event is registered by user, don't panic
* trigger panic on first timeout if no listener registered
*/
if (recovery_events) {
event = vid_enc->error_count > KICKOFF_MAX_ERRORS ?
SDE_RECOVERY_HARD_RESET : SDE_RECOVERY_CAPTURE;
sde_connector_event_notify(conn,
DRM_EVENT_SDE_HW_RECOVERY,
sizeof(uint8_t), event);
} else {
if (recovery_events)
sde_connector_event_notify(conn, DRM_EVENT_SDE_HW_RECOVERY,
sizeof(uint8_t), SDE_RECOVERY_CAPTURE);
else
SDE_DBG_DUMP("panic");
}
/* request a ctl reset before the next flush */
phys_enc->enable_state = SDE_ENC_ERR_NEEDS_HW_RESET;