diff mbox series

drm/blend: Define the direction of Z position values

Message ID 20190906144459.16025-1-daniel.vetter@ffwll.ch (mailing list archive)
State New, archived
Headers show
Series drm/blend: Define the direction of Z position values | expand

Commit Message

Daniel Vetter Sept. 6, 2019, 2:44 p.m. UTC
We forgot that.

Proof is the one igt testcase we have:

https://gitlab.freedesktop.org/drm/igt-gpu-tools/blob/master/tests/kms_atomic.c#L280

While at it also document that we have immutable zpos properties in
some cases.

Reported-by: Pekka Paalanen <pekka.paalanen@collabora.com>
Cc: Pekka Paalanen <pekka.paalanen@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.com>
Cc: Ilia Mirkin <imirkin@alum.mit.edu>
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
---
 drivers/gpu/drm/drm_blend.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

Comments

Daniel Vetter Sept. 6, 2019, 3:19 p.m. UTC | #1
On Fri, Sep 6, 2019 at 4:45 PM Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
>
> We forgot that.
>
> Proof is the one igt testcase we have:
>
> https://gitlab.freedesktop.org/drm/igt-gpu-tools/blob/master/tests/kms_atomic.c#L280
>
> While at it also document that we have immutable zpos properties in
> some cases.
>
> Reported-by: Pekka Paalanen <pekka.paalanen@collabora.com>
> Cc: Pekka Paalanen <pekka.paalanen@collabora.com>
> Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.com>
> Cc: Ilia Mirkin <imirkin@alum.mit.edu>
> Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>

From irc: Reviewed-by: Daniel Stone <daniels@collabora.com>

> ---
>  drivers/gpu/drm/drm_blend.c | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/drm_blend.c b/drivers/gpu/drm/drm_blend.c
> index 37ac168fcb60..d02709dd2d4a 100644
> --- a/drivers/gpu/drm/drm_blend.c
> +++ b/drivers/gpu/drm/drm_blend.c
> @@ -130,7 +130,12 @@
>   *     Z position is set up with drm_plane_create_zpos_immutable_property() and
>   *     drm_plane_create_zpos_property(). It controls the visibility of overlapping
>   *     planes. Without this property the primary plane is always below the cursor
> - *     plane, and ordering between all other planes is undefined.
> + *     plane, and ordering between all other planes is undefined. The positive
> + *     Z axis points towards the user, i.e. planes with lower Z position values
> + *     are underneath planes with higher Z position values. Note that the Z
> + *     position value can also be immutable, to inform userspace about the
> + *     hard-coded stacking of overlay planes, see
> + *     drm_plane_create_zpos_immutable_property().
>   *
>   * pixel blend mode:
>   *     Pixel blend mode is set up with drm_plane_create_blend_mode_property().
> --
> 2.23.0
>
Daniel Stone Sept. 6, 2019, 3:26 p.m. UTC | #2
On Fri, 6 Sep 2019 at 16:19, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> On Fri, Sep 6, 2019 at 4:45 PM Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> > We forgot that.
> >
> > Proof is the one igt testcase we have:
> >
> > https://gitlab.freedesktop.org/drm/igt-gpu-tools/blob/master/tests/kms_atomic.c#L280
> >
> > While at it also document that we have immutable zpos properties in
> > some cases.
> >
> > Reported-by: Pekka Paalanen <pekka.paalanen@collabora.com>
> > Cc: Pekka Paalanen <pekka.paalanen@collabora.com>
> > Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.com>
> > Cc: Ilia Mirkin <imirkin@alum.mit.edu>
> > Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
> > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
>
> From irc: Reviewed-by: Daniel Stone <daniels@collabora.com>

And from mail also.

Cheers,
Daniel
Daniel Vetter Sept. 6, 2019, 6:23 p.m. UTC | #3
On Fri, Sep 06, 2019 at 04:26:15PM +0100, Daniel Stone wrote:
> On Fri, 6 Sep 2019 at 16:19, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> > On Fri, Sep 6, 2019 at 4:45 PM Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> > > We forgot that.
> > >
> > > Proof is the one igt testcase we have:
> > >
> > > https://gitlab.freedesktop.org/drm/igt-gpu-tools/blob/master/tests/kms_atomic.c#L280
> > >
> > > While at it also document that we have immutable zpos properties in
> > > some cases.
> > >
> > > Reported-by: Pekka Paalanen <pekka.paalanen@collabora.com>
> > > Cc: Pekka Paalanen <pekka.paalanen@collabora.com>
> > > Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.com>
> > > Cc: Ilia Mirkin <imirkin@alum.mit.edu>
> > > Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
> > > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> >
> > From irc: Reviewed-by: Daniel Stone <daniels@collabora.com>
> 
> And from mail also.

And applied.
-Daniel
diff mbox series

Patch

diff --git a/drivers/gpu/drm/drm_blend.c b/drivers/gpu/drm/drm_blend.c
index 37ac168fcb60..d02709dd2d4a 100644
--- a/drivers/gpu/drm/drm_blend.c
+++ b/drivers/gpu/drm/drm_blend.c
@@ -130,7 +130,12 @@ 
  *	Z position is set up with drm_plane_create_zpos_immutable_property() and
  *	drm_plane_create_zpos_property(). It controls the visibility of overlapping
  *	planes. Without this property the primary plane is always below the cursor
- *	plane, and ordering between all other planes is undefined.
+ *	plane, and ordering between all other planes is undefined. The positive
+ *	Z axis points towards the user, i.e. planes with lower Z position values
+ *	are underneath planes with higher Z position values. Note that the Z
+ *	position value can also be immutable, to inform userspace about the
+ *	hard-coded stacking of overlay planes, see
+ *	drm_plane_create_zpos_immutable_property().
  *
  * pixel blend mode:
  *	Pixel blend mode is set up with drm_plane_create_blend_mode_property().