mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-10 03:20:25 -04:00
drm/i915: Add intel_atomic_add_affected_planes()
drm_atomic_add_affected_planes() only considers planes which are logically enabled in the uapi state. For bigjoiner we need to consider planes logically enabled in the hw state. Add a helper for that. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20201124201156.17095-2-ville.syrjala@linux.intel.com Reviewed-by: Manasi Navare <manasi.d.navare@intel.com>
This commit is contained in:
@@ -2415,8 +2415,7 @@ static int intel_modeset_all_pipes(struct intel_atomic_state *state)
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = drm_atomic_add_affected_planes(&state->base,
|
||||
&crtc->base);
|
||||
ret = intel_atomic_add_affected_planes(state, crtc);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
|
||||
@@ -15069,6 +15069,19 @@ static int intel_crtc_add_planes_to_state(struct intel_atomic_state *state,
|
||||
return 0;
|
||||
}
|
||||
|
||||
int intel_atomic_add_affected_planes(struct intel_atomic_state *state,
|
||||
struct intel_crtc *crtc)
|
||||
{
|
||||
const struct intel_crtc_state *old_crtc_state =
|
||||
intel_atomic_get_old_crtc_state(state, crtc);
|
||||
const struct intel_crtc_state *new_crtc_state =
|
||||
intel_atomic_get_new_crtc_state(state, crtc);
|
||||
|
||||
return intel_crtc_add_planes_to_state(state, crtc,
|
||||
old_crtc_state->enabled_planes |
|
||||
new_crtc_state->enabled_planes);
|
||||
}
|
||||
|
||||
static bool active_planes_affects_min_cdclk(struct drm_i915_private *dev_priv)
|
||||
{
|
||||
/* See {hsw,vlv,ivb}_plane_ratio() */
|
||||
|
||||
@@ -499,6 +499,8 @@ enum phy_fia {
|
||||
((connector) = to_intel_connector((__state)->base.connectors[__i].ptr), \
|
||||
(new_connector_state) = to_intel_digital_connector_state((__state)->base.connectors[__i].new_state), 1))
|
||||
|
||||
int intel_atomic_add_affected_planes(struct intel_atomic_state *state,
|
||||
struct intel_crtc *crtc);
|
||||
u8 intel_calc_active_pipes(struct intel_atomic_state *state,
|
||||
u8 active_pipes);
|
||||
void intel_link_compute_m_n(u16 bpp, int nlanes,
|
||||
|
||||
Reference in New Issue
Block a user