disp: msm: sde: remove drm panel callback

For GKI2.0, the old drm_panel_notifier function could not
be used anymore, so removed it.

Change-Id: I858f90d7c39816dc95ab59f88c8988237319eadc
Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
This commit is contained in:
Yuan Zhao
2021-01-13 12:06:16 +08:00
parent a005a785fe
commit 73cb7a36c5
2 changed files with 22 additions and 12 deletions

View File

@@ -917,6 +917,7 @@ static void _sde_kms_drm_check_dpms(struct drm_atomic_state *old_state,
struct drm_connector_state *old_conn_state; struct drm_connector_state *old_conn_state;
struct drm_crtc_state *old_crtc_state; struct drm_crtc_state *old_crtc_state;
struct drm_crtc *crtc; struct drm_crtc *crtc;
struct sde_connector *c_conn;
int i, old_mode, new_mode, old_fps, new_fps; int i, old_mode, new_mode, old_fps, new_fps;
for_each_old_connector_in_state(old_state, connector, for_each_old_connector_in_state(old_state, connector,
@@ -941,10 +942,9 @@ static void _sde_kms_drm_check_dpms(struct drm_atomic_state *old_state,
} }
if ((old_mode != new_mode) || (old_fps != new_fps)) { if ((old_mode != new_mode) || (old_fps != new_fps)) {
struct drm_panel_notifier notifier_data; c_conn = to_sde_connector(connector);
SDE_EVT32(old_mode, new_mode, old_fps, new_fps, SDE_EVT32(old_mode, new_mode, old_fps, new_fps,
connector->panel, crtc->state->active, c_conn->panel, crtc->state->active,
old_conn_state->crtc, event); old_conn_state->crtc, event);
pr_debug("change detected (power mode %d->%d, fps %d->%d)\n", pr_debug("change detected (power mode %d->%d, fps %d->%d)\n",
old_mode, new_mode, old_fps, new_fps); old_mode, new_mode, old_fps, new_fps);
@@ -956,14 +956,6 @@ static void _sde_kms_drm_check_dpms(struct drm_atomic_state *old_state,
if ((old_mode == new_mode) && (old_fps != new_fps)) if ((old_mode == new_mode) && (old_fps != new_fps))
new_mode = DRM_PANEL_BLANK_FPS_CHANGE; new_mode = DRM_PANEL_BLANK_FPS_CHANGE;
notifier_data.data = &new_mode;
notifier_data.refresh_rate = new_fps;
notifier_data.id = connector->base.id;
if (connector->panel)
drm_panel_notifier_call_chain(connector->panel,
event, &notifier_data);
} }
} }

View File

@@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2015-2020, The Linux Foundation. All rights reserved. * Copyright (c) 2015-2021, The Linux Foundation. All rights reserved.
* Copyright (C) 2013 Red Hat * Copyright (C) 2013 Red Hat
* Author: Rob Clark <robdclark@gmail.com> * Author: Rob Clark <robdclark@gmail.com>
* *
@@ -128,6 +128,11 @@
/* ESD status check interval in miliseconds */ /* ESD status check interval in miliseconds */
#define STATUS_CHECK_INTERVAL_MS 5000 #define STATUS_CHECK_INTERVAL_MS 5000
/* A hardware display blank change occurred */
#define DRM_PANEL_EVENT_BLANK 0x01
/* A hardware display blank early change occurred */
#define DRM_PANEL_EARLY_EVENT_BLANK 0x02
/** /**
* enum sde_kms_smmu_state: smmu state * enum sde_kms_smmu_state: smmu state
* @ATTACHED: all the context banks are attached. * @ATTACHED: all the context banks are attached.
@@ -186,6 +191,19 @@ enum frame_trigger_mode_type {
FRAME_DONE_WAIT_POSTED_START, FRAME_DONE_WAIT_POSTED_START,
}; };
/*
* @DRM_PANEL_BLANK_UNBLANK: power on
* @DRM_PANEL_BLANK_POWERDOWN: power off
* @DRM_PANEL_BLANK_LP: low power mode
* @DRM_PANEL_BLANK_FPS_CHANGE: fps change
*/
enum {
DRM_PANEL_BLANK_UNBLANK,
DRM_PANEL_BLANK_POWERDOWN,
DRM_PANEL_BLANK_LP,
DRM_PANEL_BLANK_FPS_CHANGE,
};
/** /**
* struct sde_kms_smmu_state_data: stores the smmu state and transition type * struct sde_kms_smmu_state_data: stores the smmu state and transition type
* @state: current state of smmu context banks * @state: current state of smmu context banks