From: Jani Nikula <jani.nikula@intel.com>
To: Vidya Srinivas <vidya.srinivas@intel.com>,
intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH] drm/i915: Allow panel drrs modes to have differing sync polarities
Date: Tue, 11 Jul 2023 19:03:50 +0300 [thread overview]
Message-ID: <87o7kih1uh.fsf@intel.com> (raw)
In-Reply-To: <20230711002529.9742-1-vidya.srinivas@intel.com>
On Tue, 11 Jul 2023, Vidya Srinivas <vidya.srinivas@intel.com> wrote:
> v2: Add Jani Nikula's change for quirk for sync polarity
This was a quick hack suggestion to try. If it works, I think it works
by concidence, because a fastset won't update the sync flags in
TRANS_DDI_FUNC_CTL register. Did not check whether they can even be
updated while the transcoder is enabled.
> CC: Jani Nikula <jani.nikula@intel.com>
> Credits-to: Jani Nikula <jani.nikula@intel.com>
> Signed-off-by: Vidya Srinivas <vidya.srinivas@intel.com>
It would be useful to have a bug report at fdo gitlab with the EDID
attached.
BR,
Jani.
> ---
> drivers/gpu/drm/i915/display/intel_display.c | 2 +-
> drivers/gpu/drm/i915/display/intel_panel.c | 10 ++++++----
> 2 files changed, 7 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
> index 43cba98f7753..088b45e032aa 100644
> --- a/drivers/gpu/drm/i915/display/intel_display.c
> +++ b/drivers/gpu/drm/i915/display/intel_display.c
> @@ -5234,7 +5234,7 @@ intel_pipe_config_compare(const struct intel_crtc_state *current_config,
> PIPE_CONF_CHECK_FLAGS(hw.adjusted_mode.flags,
> DRM_MODE_FLAG_INTERLACE);
>
> - if (!PIPE_CONF_QUIRK(PIPE_CONFIG_QUIRK_MODE_SYNC_FLAGS)) {
> + if (!PIPE_CONF_QUIRK(PIPE_CONFIG_QUIRK_MODE_SYNC_FLAGS) && !fastset) {
> PIPE_CONF_CHECK_FLAGS(hw.adjusted_mode.flags,
> DRM_MODE_FLAG_PHSYNC);
> PIPE_CONF_CHECK_FLAGS(hw.adjusted_mode.flags,
> diff --git a/drivers/gpu/drm/i915/display/intel_panel.c b/drivers/gpu/drm/i915/display/intel_panel.c
> index 9232a305b1e6..b9eeaedabd22 100644
> --- a/drivers/gpu/drm/i915/display/intel_panel.c
> +++ b/drivers/gpu/drm/i915/display/intel_panel.c
> @@ -112,10 +112,12 @@ intel_panel_fixed_mode(struct intel_connector *connector,
> static bool is_alt_drrs_mode(const struct drm_display_mode *mode,
> const struct drm_display_mode *preferred_mode)
> {
> - return drm_mode_match(mode, preferred_mode,
> - DRM_MODE_MATCH_TIMINGS |
> - DRM_MODE_MATCH_FLAGS |
> - DRM_MODE_MATCH_3D_FLAGS) &&
> + u32 sync_flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NHSYNC |
> + DRM_MODE_FLAG_PVSYNC | DRM_MODE_FLAG_NVSYNC;
> +
> + return (mode->flags & ~sync_flags) == (preferred_mode->flags & ~sync_flags) &&
> + mode->hdisplay == preferred_mode->hdisplay &&
> + mode->vdisplay == preferred_mode->vdisplay &&
> mode->clock != preferred_mode->clock;
> }
--
Jani Nikula, Intel Open Source Graphics Center
next prev parent reply other threads:[~2023-07-11 16:04 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-11 0:25 [Intel-gfx] [PATCH] drm/i915: Allow panel drrs modes to have differing sync polarities Vidya Srinivas
2023-07-11 1:16 ` [Intel-gfx] ✓ Fi.CI.BAT: success for " Patchwork
2023-07-11 3:31 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
2023-07-11 16:03 ` Jani Nikula [this message]
2023-07-11 16:06 ` [Intel-gfx] [PATCH] " Srinivas, Vidya
2023-07-12 8:13 ` Jani Nikula
2023-07-12 8:18 ` Srinivas, Vidya
2023-07-13 13:08 ` Jani Nikula
2023-07-13 15:34 ` Srinivas, Vidya
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87o7kih1uh.fsf@intel.com \
--to=jani.nikula@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=vidya.srinivas@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.