All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: Ben Kao <ben.kao@intel.com>, intel-gfx@lists.freedesktop.org
Cc: Ben Kao <ben.kao@intel.com>
Subject: Re: [PATCH v1] drm/i915/dp: Modify DP lane count from DPCD reading
Date: Fri, 28 Jun 2024 10:36:32 +0300	[thread overview]
Message-ID: <87o77lbjsv.fsf@intel.com> (raw)
In-Reply-To: <20240628073013.17233-1-ben.kao@intel.com>

On Fri, 28 Jun 2024, Ben Kao <ben.kao@intel.com> wrote:
> We found that the external monitor would be failed to display
> when hot-plug with dual Type-C USB cable on Dell WD19DC dock.
> Due to the host would receive 2 lanes setting when the first HPD,
> then receive 4 lanes setting later, but the host only sets 2 lanes
> DP and skips to set 4 lanes DP. I modify DP lane count if the
> current DP lane count is not the same as DPCD reading.
>
> Signed-off-by: Ben Kao <ben.kao@intel.com>

Please file a bug according to [1].

BR,
Jani.

[1] https://drm.pages.freedesktop.org/intel-docs/how-to-file-i915-bugs.html


> ---
>  drivers/gpu/drm/i915/display/intel_dp.c | 6 ++++++
>  1 file changed, 6 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
> index 5b3b6ae1e3d7..a9b9023c6744 100644
> --- a/drivers/gpu/drm/i915/display/intel_dp.c
> +++ b/drivers/gpu/drm/i915/display/intel_dp.c
> @@ -5545,6 +5545,12 @@ intel_dp_detect_dpcd(struct intel_dp *intel_dp)
>  	if (!intel_dp_get_dpcd(intel_dp))
>  		return connector_status_disconnected;
>  
> +	/* lanes count changed */
> +	if (intel_dp->lane_count != drm_dp_max_lane_count(intel_dp->dpcd)) {
> +		intel_dp->lane_count = drm_dp_max_lane_count(intel_dp->dpcd);
> +		return connector_status_disconnected;
> +	}
> +
>  	intel_dp->mst_detect = intel_dp_mst_detect(intel_dp);
>  
>  	/* if there's no downstream port, we're done */

-- 
Jani Nikula, Intel

  reply	other threads:[~2024-06-28  7:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-28  7:30 [PATCH v1] drm/i915/dp: Modify DP lane count from DPCD reading Ben Kao
2024-06-28  7:36 ` Jani Nikula [this message]
2024-06-28  7:52   ` Kao, Ben
2024-06-28  9:45 ` ✗ Fi.CI.BAT: failure for " Patchwork

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=87o77lbjsv.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=ben.kao@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    /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.