All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Cc: vincent.abriou@st.com, fabien.dessenne@st.com,
	dri-devel@lists.freedesktop.org,
	Marek Szyprowski <m.szyprowski@samsung.com>
Subject: Re: [PATCH 2/5] drm: sti: add atomic get/set properties for planes
Date: Thu, 7 Jan 2016 14:50:59 +0100	[thread overview]
Message-ID: <20160107135059.GM8076@phenom.ffwll.local> (raw)
In-Reply-To: <1452173441-30033-3-git-send-email-benjamin.gaignard@linaro.org>

On Thu, Jan 07, 2016 at 02:30:38PM +0100, Benjamin Gaignard wrote:
> Without those function zpos property isn't displayed in atomic mode.
> 
> Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>

Oh, another iteration of a driver-private zpos property. This _really_
should be generic, with some consistent cross-driver semantics. Marek from
samsung has started with a patch series for that.

Can you please work together with him, and rebase the sti zpos support on
top of his work? And hold of this patch for now meanwhile?

Also adding Marek.

Thanks, Daniel

> ---
>  drivers/gpu/drm/sti/sti_plane.c | 40 ++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 40 insertions(+)
> 
> diff --git a/drivers/gpu/drm/sti/sti_plane.c b/drivers/gpu/drm/sti/sti_plane.c
> index 2e5c751..e739c5a 100644
> --- a/drivers/gpu/drm/sti/sti_plane.c
> +++ b/drivers/gpu/drm/sti/sti_plane.c
> @@ -69,6 +69,44 @@ static int sti_plane_set_property(struct drm_plane *drm_plane,
>  	return -EINVAL;
>  }
>  
> +static int sti_plane_atomic_set_property(struct drm_plane *drm_plane,
> +					 struct drm_plane_state *state,
> +					 struct drm_property *property,
> +					 uint64_t val)
> +{
> +	struct drm_device *dev = drm_plane->dev;
> +	struct sti_private *private = dev->dev_private;
> +	struct sti_plane *plane = to_sti_plane(drm_plane);
> +
> +	DRM_DEBUG_DRIVER("\n");
> +
> +	if (property == private->plane_zorder_property) {
> +		plane->zorder = val;
> +		return 0;
> +	}
> +
> +	return -EINVAL;
> +}
> +
> +static int sti_plane_atomic_get_property(struct drm_plane *drm_plane,
> +					 const struct drm_plane_state *state,
> +					 struct drm_property *property,
> +					 uint64_t *val)
> +{
> +	struct drm_device *dev = drm_plane->dev;
> +	struct sti_private *private = dev->dev_private;
> +	struct sti_plane *plane = to_sti_plane(drm_plane);
> +
> +	DRM_DEBUG_DRIVER("\n");
> +
> +	if (property == private->plane_zorder_property) {
> +		*val = plane->zorder;
> +		return 0;
> +	}
> +
> +	return -EINVAL;
> +}
> +
>  static void sti_plane_attach_zorder_property(struct drm_plane *drm_plane)
>  {
>  	struct drm_device *dev = drm_plane->dev;
> @@ -116,4 +154,6 @@ struct drm_plane_funcs sti_plane_helpers_funcs = {
>  	.reset = drm_atomic_helper_plane_reset,
>  	.atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
>  	.atomic_destroy_state = drm_atomic_helper_plane_destroy_state,
> +	.atomic_set_property = sti_plane_atomic_set_property,
> +	.atomic_get_property = sti_plane_atomic_get_property,
>  };
> -- 
> 1.9.1
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

  reply	other threads:[~2016-01-07 13:51 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-07 13:30 [PATCH 0/5] sti fix to enable atomic modesetting Benjamin Gaignard
2016-01-07 13:30 ` [PATCH 1/5] drm: sti: fix potential crash in gdp Benjamin Gaignard
2016-01-07 13:30 ` [PATCH 2/5] drm: sti: add atomic get/set properties for planes Benjamin Gaignard
2016-01-07 13:50   ` Daniel Vetter [this message]
2016-01-07 14:05     ` Benjamin Gaignard
2016-01-07 14:47       ` Daniel Vetter
2016-01-13  8:53         ` Benjamin Gaignard
2016-01-13  8:58           ` Daniel Vetter
2016-01-07 13:30 ` [PATCH 3/5] drm: sti: set CRTC modesetting parameters Benjamin Gaignard
2016-01-07 13:52   ` Daniel Vetter
2016-01-07 13:30 ` [PATCH 4/5] drm: sti: fix cursor coordinates Benjamin Gaignard
2016-01-07 13:30 ` [PATCH 5/5] drm: sti: set DRIVER_ATOMIC for sti Benjamin Gaignard

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=20160107135059.GM8076@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=benjamin.gaignard@linaro.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=fabien.dessenne@st.com \
    --cc=m.szyprowski@samsung.com \
    --cc=vincent.abriou@st.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.