@@ -5420,8 +5420,8 @@ intel_verify_planes(struct intel_atomic_state *state)
plane_state->uapi.visible);
}
-int intel_modeset_all_pipes(struct intel_atomic_state *state,
- const char *reason)
+int intel_modeset_pipes_in_mask(struct intel_atomic_state *state,
+ const char *reason, u8 mask)
{
struct drm_i915_private *dev_priv = to_i915(state->base.dev);
struct intel_crtc *crtc;
@@ -5430,7 +5430,7 @@ int intel_modeset_all_pipes(struct intel_atomic_state *state,
* Add all pipes to the state, and force
* a modeset on all the active ones.
*/
- for_each_intel_crtc(&dev_priv->drm, crtc) {
+ for_each_intel_crtc_in_pipe_mask(&dev_priv->drm, crtc, mask) {
struct intel_crtc_state *crtc_state;
int ret;
@@ -5469,6 +5469,12 @@ int intel_modeset_all_pipes(struct intel_atomic_state *state,
return 0;
}
+int intel_modeset_all_pipes(struct intel_atomic_state *state,
+ const char *reason)
+{
+ return intel_modeset_pipes_in_mask(state, reason, -1);
+}
+
/*
* This implements the workaround described in the "notes" section of the mode
* set sequence documentation. When going from no pipes or single pipe to
@@ -515,6 +515,8 @@ void intel_update_watermarks(struct drm_i915_private *i915);
/* modesetting */
int intel_modeset_all_pipes(struct intel_atomic_state *state,
const char *reason);
+int intel_modeset_pipes_in_mask(struct intel_atomic_state *state,
+ const char *reason, u8 pipe_mask);
void intel_modeset_get_crtc_power_domains(struct intel_crtc_state *crtc_state,
struct intel_power_domain_mask *old_domains);
void intel_modeset_put_crtc_power_domains(struct intel_crtc *crtc,
Add intel_modeset_pipes_in_mask() to modeset a provided set of pipes, used in a follow-up patch. Signed-off-by: Imre Deak <imre.deak@intel.com> --- drivers/gpu/drm/i915/display/intel_display.c | 12 +++++++++--- drivers/gpu/drm/i915/display/intel_display.h | 2 ++ 2 files changed, 11 insertions(+), 3 deletions(-)