From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Intel Graphics Development <intel-gfx@lists.freedesktop.org>
Subject: Re: [PATCH v2] drm/i915: Remove all ->config dereferences from intel_hdmi, v2.
Date: Wed, 23 Nov 2016 17:22:58 +0200 [thread overview]
Message-ID: <20161123152258.GI31595@intel.com> (raw)
In-Reply-To: <8b02a6b4-606a-e43a-b357-ad17f491525b@linux.intel.com>
On Wed, Nov 23, 2016 at 03:57:00PM +0100, Maarten Lankhorst wrote:
> In all cases we can now obtain the relevant crtc_state/conn_state
> from the relevant callbacks, which means all the ->config accesses
> can be removed and the code cleaned up.
>
> Changes since v1:
> - cstate -> crtc_state
>
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> ---
<snip>
> @@ -560,28 +566,16 @@ static void g4x_set_infoframes(struct drm_encoder *encoder,
> I915_WRITE(reg, val);
> POSTING_READ(reg);
>
> - intel_hdmi_set_avi_infoframe(encoder, adjusted_mode);
> - intel_hdmi_set_spd_infoframe(encoder);
> - intel_hdmi_set_hdmi_infoframe(encoder, adjusted_mode);
> + intel_hdmi_set_avi_infoframe(encoder, crtc_state);
> + intel_hdmi_set_spd_infoframe(encoder, crtc_state);
> + intel_hdmi_set_hdmi_infoframe(encoder, crtc_state);
> }
>
> -static bool hdmi_sink_is_deep_color(struct drm_encoder *encoder)
> +static bool hdmi_sink_is_deep_color(const struct drm_connector_state *conn_state)
> {
> - struct drm_device *dev = encoder->dev;
> - struct drm_connector *connector;
> -
> - WARN_ON(!drm_modeset_is_locked(&dev->mode_config.connection_mutex));
> + struct drm_connector *connector = conn_state->connector;
>
> - /*
> - * HDMI cloning is only supported on g4x which doesn't
> - * support deep color or GCP infoframes anyway so no
> - * need to worry about multiple HDMI sinks here.
> - */
Please don't remove that comment.
With the comment restored this is
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> - list_for_each_entry(connector, &dev->mode_config.connector_list, head)
> - if (connector->encoder == encoder)
> - return connector->display_info.bpc > 8;
> -
> - return false;
> + return connector->display_info.bpc > 8;
> }
>
> /*
--
Ville Syrjälä
Intel OTC
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
prev parent reply other threads:[~2016-11-23 15:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-22 12:38 [PATCH] drm/i915: Remove all ->config dereferences from intel_hdmi Maarten Lankhorst
2016-11-22 13:20 ` Ville Syrjälä
2016-11-23 14:57 ` [PATCH v2] drm/i915: Remove all ->config dereferences from intel_hdmi, v2 Maarten Lankhorst
2016-11-23 15:22 ` Ville Syrjälä [this message]
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=20161123152258.GI31595@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=maarten.lankhorst@linux.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox