* [PATCH 16/23] drm/rcar: plane: Remove redundant zpos initialisation
[not found] <20220207163515.1038648-1-maxime@cerno.tech>
@ 2022-02-07 16:35 ` Maxime Ripard
2022-02-07 22:06 ` Laurent Pinchart
2022-02-08 12:16 ` Kieran Bingham
0 siblings, 2 replies; 3+ messages in thread
From: Maxime Ripard @ 2022-02-07 16:35 UTC (permalink / raw)
To: Daniel Vetter, David Airlie
Cc: dri-devel, Maarten Lankhorst, Thomas Zimmermann, Maxime Ripard,
Dave Stevenson, Phil Elwell, Tim Gover, Dom Cobley,
linux-renesas-soc, Kieran Bingham, Laurent Pinchart
The rcar-du KMS driver will call drm_plane_create_zpos_property() with an
init value depending on the plane type.
Since the initial value wasn't carried over in the state, the driver had
to set it again in rcar_du_plane_reset() and rcar_du_vsp_plane_reset().
However, the helpers have been adjusted to set it properly at reset, so
this is not needed anymore.
Cc: linux-renesas-soc@vger.kernel.org
Cc: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
---
drivers/gpu/drm/rcar-du/rcar_du_plane.c | 1 -
drivers/gpu/drm/rcar-du/rcar_du_vsp.c | 1 -
2 files changed, 2 deletions(-)
diff --git a/drivers/gpu/drm/rcar-du/rcar_du_plane.c b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
index 862197be1e01..9dda5e06457d 100644
--- a/drivers/gpu/drm/rcar-du/rcar_du_plane.c
+++ b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
@@ -696,7 +696,6 @@ static void rcar_du_plane_reset(struct drm_plane *plane)
state->hwindex = -1;
state->source = RCAR_DU_PLANE_MEMORY;
state->colorkey = RCAR_DU_COLORKEY_NONE;
- state->state.zpos = plane->type == DRM_PLANE_TYPE_PRIMARY ? 0 : 1;
}
static int rcar_du_plane_atomic_set_property(struct drm_plane *plane,
diff --git a/drivers/gpu/drm/rcar-du/rcar_du_vsp.c b/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
index b7fc5b069cbc..719c60034952 100644
--- a/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
+++ b/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
@@ -362,7 +362,6 @@ static void rcar_du_vsp_plane_reset(struct drm_plane *plane)
return;
__drm_atomic_helper_plane_reset(plane, &state->state);
- state->state.zpos = plane->type == DRM_PLANE_TYPE_PRIMARY ? 0 : 1;
}
static const struct drm_plane_funcs rcar_du_vsp_plane_funcs = {
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 16/23] drm/rcar: plane: Remove redundant zpos initialisation
2022-02-07 16:35 ` [PATCH 16/23] drm/rcar: plane: Remove redundant zpos initialisation Maxime Ripard
@ 2022-02-07 22:06 ` Laurent Pinchart
2022-02-08 12:16 ` Kieran Bingham
1 sibling, 0 replies; 3+ messages in thread
From: Laurent Pinchart @ 2022-02-07 22:06 UTC (permalink / raw)
To: Maxime Ripard
Cc: Daniel Vetter, David Airlie, dri-devel, Maarten Lankhorst,
Thomas Zimmermann, Dave Stevenson, Phil Elwell, Tim Gover,
Dom Cobley, linux-renesas-soc, Kieran Bingham
Hello Maxime,
Thank you for the patch.
On Mon, Feb 07, 2022 at 05:35:08PM +0100, Maxime Ripard wrote:
> The rcar-du KMS driver will call drm_plane_create_zpos_property() with an
> init value depending on the plane type.
>
> Since the initial value wasn't carried over in the state, the driver had
> to set it again in rcar_du_plane_reset() and rcar_du_vsp_plane_reset().
> However, the helpers have been adjusted to set it properly at reset, so
> this is not needed anymore.
>
> Cc: linux-renesas-soc@vger.kernel.org
> Cc: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---
> drivers/gpu/drm/rcar-du/rcar_du_plane.c | 1 -
> drivers/gpu/drm/rcar-du/rcar_du_vsp.c | 1 -
> 2 files changed, 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_plane.c b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> index 862197be1e01..9dda5e06457d 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> @@ -696,7 +696,6 @@ static void rcar_du_plane_reset(struct drm_plane *plane)
> state->hwindex = -1;
> state->source = RCAR_DU_PLANE_MEMORY;
> state->colorkey = RCAR_DU_COLORKEY_NONE;
> - state->state.zpos = plane->type == DRM_PLANE_TYPE_PRIMARY ? 0 : 1;
> }
>
> static int rcar_du_plane_atomic_set_property(struct drm_plane *plane,
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_vsp.c b/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> index b7fc5b069cbc..719c60034952 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> @@ -362,7 +362,6 @@ static void rcar_du_vsp_plane_reset(struct drm_plane *plane)
> return;
>
> __drm_atomic_helper_plane_reset(plane, &state->state);
> - state->state.zpos = plane->type == DRM_PLANE_TYPE_PRIMARY ? 0 : 1;
> }
>
> static const struct drm_plane_funcs rcar_du_vsp_plane_funcs = {
--
Regards,
Laurent Pinchart
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 16/23] drm/rcar: plane: Remove redundant zpos initialisation
2022-02-07 16:35 ` [PATCH 16/23] drm/rcar: plane: Remove redundant zpos initialisation Maxime Ripard
2022-02-07 22:06 ` Laurent Pinchart
@ 2022-02-08 12:16 ` Kieran Bingham
1 sibling, 0 replies; 3+ messages in thread
From: Kieran Bingham @ 2022-02-08 12:16 UTC (permalink / raw)
To: Daniel Vetter, David Airlie, Maxime Ripard
Cc: dri-devel, Maarten Lankhorst, Thomas Zimmermann, Maxime Ripard,
Dave Stevenson, Phil Elwell, Tim Gover, Dom Cobley,
linux-renesas-soc, Laurent Pinchart
Quoting Maxime Ripard (2022-02-07 16:35:08)
> The rcar-du KMS driver will call drm_plane_create_zpos_property() with an
> init value depending on the plane type.
>
> Since the initial value wasn't carried over in the state, the driver had
> to set it again in rcar_du_plane_reset() and rcar_du_vsp_plane_reset().
> However, the helpers have been adjusted to set it properly at reset, so
> this is not needed anymore.
Sounds helpful ;-)
> Cc: linux-renesas-soc@vger.kernel.org
> Cc: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
> ---
> drivers/gpu/drm/rcar-du/rcar_du_plane.c | 1 -
> drivers/gpu/drm/rcar-du/rcar_du_vsp.c | 1 -
> 2 files changed, 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_plane.c b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> index 862197be1e01..9dda5e06457d 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> @@ -696,7 +696,6 @@ static void rcar_du_plane_reset(struct drm_plane *plane)
> state->hwindex = -1;
> state->source = RCAR_DU_PLANE_MEMORY;
> state->colorkey = RCAR_DU_COLORKEY_NONE;
> - state->state.zpos = plane->type == DRM_PLANE_TYPE_PRIMARY ? 0 : 1;
> }
>
> static int rcar_du_plane_atomic_set_property(struct drm_plane *plane,
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_vsp.c b/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> index b7fc5b069cbc..719c60034952 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> @@ -362,7 +362,6 @@ static void rcar_du_vsp_plane_reset(struct drm_plane *plane)
> return;
>
> __drm_atomic_helper_plane_reset(plane, &state->state);
> - state->state.zpos = plane->type == DRM_PLANE_TYPE_PRIMARY ? 0 : 1;
> }
>
> static const struct drm_plane_funcs rcar_du_vsp_plane_funcs = {
> --
> 2.34.1
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-02-08 13:17 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20220207163515.1038648-1-maxime@cerno.tech>
2022-02-07 16:35 ` [PATCH 16/23] drm/rcar: plane: Remove redundant zpos initialisation Maxime Ripard
2022-02-07 22:06 ` Laurent Pinchart
2022-02-08 12:16 ` Kieran Bingham
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).