From: Jani Nikula <jani.nikula@linux.intel.com>
To: Damien Lespiau <damien.lespiau@gmail.com>,
intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 4/6] drm/i915/dp: Log the DPCD only if we have successfully retrieved one
Date: Fri, 14 Dec 2012 11:40:59 +0200 [thread overview]
Message-ID: <87lid12cpg.fsf@intel.com> (raw)
In-Reply-To: <1355414944-1494-4-git-send-email-damien.lespiau@gmail.com>
On Thu, 13 Dec 2012, Damien Lespiau <damien.lespiau@gmail.com> wrote:
> From: Damien Lespiau <damien.lespiau@intel.com>
>
> Moving the DPCD just after a successful read will allow to:
> - log all DPCD reads (eDP ones, changes signalled by HPD IRQ)
> - don't log it if we haven't been able to read it
The first part does actually increase DPCD logging a bit, but with the
second part this should result in a nice reduction of dmesg noise. /me
likes.
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
>
> v2: Be sure to log the DPCD when a downstream port does not have HPD
> support and the branch device asserts HPD (Jani Nikula)
>
> Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
> ---
> drivers/gpu/drm/i915/intel_dp.c | 11 ++++++-----
> 1 file changed, 6 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
> index 19a0d89..5ed8fb3 100644
> --- a/drivers/gpu/drm/i915/intel_dp.c
> +++ b/drivers/gpu/drm/i915/intel_dp.c
> @@ -2084,10 +2084,16 @@ intel_dp_link_down(struct intel_dp *intel_dp)
> static bool
> intel_dp_get_dpcd(struct intel_dp *intel_dp)
> {
> + char dpcd_hex_dump[sizeof(intel_dp->dpcd) * 3];
> +
> if (intel_dp_aux_native_read_retry(intel_dp, 0x000, intel_dp->dpcd,
> sizeof(intel_dp->dpcd)) == 0)
> return false; /* aux transfer failed */
>
> + hex_dump_to_buffer(intel_dp->dpcd, sizeof(intel_dp->dpcd),
> + 32, 1, dpcd_hex_dump, sizeof(dpcd_hex_dump), false);
> + DRM_DEBUG_KMS("DPCD: %s\n", dpcd_hex_dump);
> +
> if (intel_dp->dpcd[DP_DPCD_REV] == 0)
> return false; /* DPCD not present */
>
> @@ -2353,7 +2359,6 @@ intel_dp_detect(struct drm_connector *connector, bool force)
> struct drm_device *dev = connector->dev;
> enum drm_connector_status status;
> struct edid *edid = NULL;
> - char dpcd_hex_dump[sizeof(intel_dp->dpcd) * 3];
>
> intel_dp->has_audio = false;
>
> @@ -2362,10 +2367,6 @@ intel_dp_detect(struct drm_connector *connector, bool force)
> else
> status = g4x_dp_detect(intel_dp);
>
> - hex_dump_to_buffer(intel_dp->dpcd, sizeof(intel_dp->dpcd),
> - 32, 1, dpcd_hex_dump, sizeof(dpcd_hex_dump), false);
> - DRM_DEBUG_KMS("DPCD: %s\n", dpcd_hex_dump);
> -
> if (status != connector_status_connected)
> return status;
>
> --
> 1.7.11.7
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2012-12-14 9:39 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-13 16:08 [PATCH 1/6] drm/i915: Cleanup SHOTPLUG_CTL status bits definitions Damien Lespiau
2012-12-13 16:09 ` [PATCH 2/6] drm/i915/hdmi: Read the HPD status before trying to read the EDID Damien Lespiau
2012-12-14 9:34 ` Jani Nikula
2012-12-13 16:09 ` [PATCH 3/6] drm/i915/dp: Read the HPD status before trying to read the DPCD Damien Lespiau
2012-12-14 10:17 ` Daniel Vetter
2012-12-13 16:09 ` [PATCH 4/6] drm/i915/dp: Log the DPCD only if we have successfully retrieved one Damien Lespiau
2012-12-14 9:40 ` Jani Nikula [this message]
2012-12-13 16:09 ` [PATCH 5/6] drm/i915: Implement ibx_digital_port_connected() for IBX Damien Lespiau
2012-12-14 9:43 ` Jani Nikula
2012-12-13 16:09 ` [PATCH 6/6] drm/i915: Remove stale comment about intel_dp_detect() Damien Lespiau
2012-12-14 9:46 ` Jani Nikula
2012-12-14 10:20 ` Daniel Vetter
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=87lid12cpg.fsf@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=damien.lespiau@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox