All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Ville Syrjala <ville.syrjala@linux.intel.com>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 1/5] drm/rcar-du: Use drm_mode_get_hv_timing() to populate plane clip rectangle
Date: Wed, 24 Jan 2018 02:07:30 +0200	[thread overview]
Message-ID: <3491323.Vvjl2Tpm6D@avalon> (raw)
In-Reply-To: <20180123170857.13818-1-ville.syrjala@linux.intel.com>

Hi Ville,

Thank you for the patch.

On Tuesday, 23 January 2018 19:08:53 EET Ville Syrjala wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> 
> Use drm_mode_get_hv_timing() to fill out the plane clip rectangle.
> 
> No functional changes as the code already uses crtc_state->mode
> to populate the clip, which is also what drm_mode_get_hv_timing()
> uses.
> 
> Once everyone agrees on this we can move the clip handling into
> drm_atomic_helper_check_plane_state().
> 
> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
>  drivers/gpu/drm/rcar-du/rcar_du_plane.c | 9 ++++-----
>  1 file changed, 4 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> b/drivers/gpu/drm/rcar-du/rcar_du_plane.c index 4a3d16cf3ed6..5687a94d4cb1
> 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> @@ -572,7 +572,7 @@ int __rcar_du_plane_atomic_check(struct drm_plane
> *plane, {
>  	struct drm_device *dev = plane->dev;
>  	struct drm_crtc_state *crtc_state;
> -	struct drm_rect clip;
> +	struct drm_rect clip = {};

Nitpicking, isn't the correct C99 zero initializer { 0 } ? I doesn't matter 
too much as the variable is removed in patch 5/5 but we could as well fix it 
if needed.

Apart from that,

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

>  	int ret;
> 
>  	if (!state->crtc) {
> @@ -589,10 +589,9 @@ int __rcar_du_plane_atomic_check(struct drm_plane
> *plane, if (IS_ERR(crtc_state))
>  		return PTR_ERR(crtc_state);
> 
> -	clip.x1 = 0;
> -	clip.y1 = 0;
> -	clip.x2 = crtc_state->mode.hdisplay;
> -	clip.y2 = crtc_state->mode.vdisplay;
> +	if (crtc_state->enable)
> +		drm_mode_get_hv_timing(&crtc_state->mode,
> +				       &clip.x2, &clip.y2);
> 
>  	ret = drm_atomic_helper_check_plane_state(state, crtc_state, &clip,
>  						  DRM_PLANE_HELPER_NO_SCALING,

-- 
Regards,

Laurent Pinchart

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  parent reply	other threads:[~2018-01-24  0:07 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-23 17:08 [PATCH 1/5] drm/rcar-du: Use drm_mode_get_hv_timing() to populate plane clip rectangle Ville Syrjala
2018-01-23 17:08 ` [PATCH 2/5] drm/sun4i: " Ville Syrjala
2018-02-02 15:04   ` Ville Syrjälä
2018-01-23 17:08 ` [PATCH 3/5] drm/armada: Construct a temporary crtc state for plane checks Ville Syrjala
2018-01-23 18:42   ` Russell King - ARM Linux
2018-01-23 19:02     ` Ville Syrjälä
2018-02-02 14:10       ` Ville Syrjälä
2018-02-02 15:10         ` Ville Syrjälä
2018-02-23 15:55           ` Ville Syrjälä
2018-02-23 19:14             ` Russell King - ARM Linux
2018-01-23 17:08 ` [PATCH 4/5] drm/armada: Use drm_mode_get_hv_timing() to populate plane clip rectangle Ville Syrjala
2018-03-05  8:41   ` Daniel Vetter
2018-03-05 18:58     ` Ville Syrjälä
2018-01-23 17:08 ` [PATCH 5/5] drm: Don't pass clip to drm_atomic_helper_check_plane_state() Ville Syrjala
2018-01-23 17:08   ` Ville Syrjala
2018-01-23 17:08   ` Ville Syrjala
2018-01-23 17:46   ` Liviu Dudau
2018-01-23 17:46     ` Liviu Dudau
2018-01-23 17:46     ` Liviu Dudau
2018-01-23 18:06   ` Philipp Zabel
2018-01-23 18:06     ` Philipp Zabel
2018-01-23 18:06     ` Philipp Zabel
2018-01-24  0:12   ` Laurent Pinchart
2018-01-24 19:48   ` Sinclair Yeh
2018-01-24 19:48     ` Sinclair Yeh
2018-01-24 19:48     ` Sinclair Yeh
2018-01-26  5:23   ` Neil Armstrong
2018-01-26  5:23     ` Neil Armstrong
2018-01-26  5:23     ` Neil Armstrong
2018-02-05  6:50   ` Shawn Guo
2018-02-05  6:50     ` Shawn Guo
2018-02-05  6:50     ` Shawn Guo
2018-01-24  0:07 ` Laurent Pinchart [this message]
2018-01-24 15:01   ` [PATCH 1/5] drm/rcar-du: Use drm_mode_get_hv_timing() to populate plane clip rectangle Ville Syrjälä

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=3491323.Vvjl2Tpm6D@avalon \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=ville.syrjala@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 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.