Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: Ville Syrjala <ville.syrjala@linux.intel.com>,
	intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 06/12] drm/i915: Move intel_plane_destroy() into intel_atomic_plane.c
Date: Thu, 13 Feb 2025 21:17:19 +0200	[thread overview]
Message-ID: <8734ghy7r4.fsf@intel.com> (raw)
In-Reply-To: <20250213150220.13580-7-ville.syrjala@linux.intel.com>

On Thu, 13 Feb 2025, Ville Syrjala <ville.syrjala@linux.intel.com> wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>
> intel_atomic_plane.c (should rename it really) has become our
> standard place for generic plane code. Move intel_plane_destroy()
> there so it doesn't clutter intel_display.c.
>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>

Agreed on the renaming.

Reviewed-by: Jani Nikula <jani.nikula@intel.com>

> ---
>  drivers/gpu/drm/i915/display/intel_atomic_plane.c | 13 +++++++++++++
>  drivers/gpu/drm/i915/display/intel_atomic_plane.h |  1 +
>  drivers/gpu/drm/i915/display/intel_display.c      | 13 -------------
>  drivers/gpu/drm/i915/display/intel_display.h      |  1 -
>  4 files changed, 14 insertions(+), 14 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_atomic_plane.c b/drivers/gpu/drm/i915/display/intel_atomic_plane.c
> index 8a49d87d9bd9..7e87c052be45 100644
> --- a/drivers/gpu/drm/i915/display/intel_atomic_plane.c
> +++ b/drivers/gpu/drm/i915/display/intel_atomic_plane.c
> @@ -92,6 +92,19 @@ void intel_plane_free(struct intel_plane *plane)
>  	kfree(plane);
>  }
>  
> +/**
> + * intel_plane_destroy - destroy a plane
> + * @plane: plane to destroy
> + *
> + * Common destruction function for all types of planes (primary, cursor,
> + * sprite).
> + */
> +void intel_plane_destroy(struct drm_plane *plane)
> +{
> +	drm_plane_cleanup(plane);
> +	kfree(to_intel_plane(plane));
> +}
> +
>  /**
>   * intel_plane_duplicate_state - duplicate plane state
>   * @plane: drm plane
> diff --git a/drivers/gpu/drm/i915/display/intel_atomic_plane.h b/drivers/gpu/drm/i915/display/intel_atomic_plane.h
> index fb87b3353ab0..e965ea0cb15c 100644
> --- a/drivers/gpu/drm/i915/display/intel_atomic_plane.h
> +++ b/drivers/gpu/drm/i915/display/intel_atomic_plane.h
> @@ -52,6 +52,7 @@ void intel_plane_disable_arm(struct intel_dsb *dsb,
>  			     const struct intel_crtc_state *crtc_state);
>  struct intel_plane *intel_plane_alloc(void);
>  void intel_plane_free(struct intel_plane *plane);
> +void intel_plane_destroy(struct drm_plane *plane);
>  struct drm_plane_state *intel_plane_duplicate_state(struct drm_plane *plane);
>  void intel_plane_destroy_state(struct drm_plane *plane,
>  			       struct drm_plane_state *state);
> diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
> index 0807a4979ea2..4278212a2496 100644
> --- a/drivers/gpu/drm/i915/display/intel_display.c
> +++ b/drivers/gpu/drm/i915/display/intel_display.c
> @@ -8117,19 +8117,6 @@ int intel_atomic_commit(struct drm_device *dev, struct drm_atomic_state *_state,
>  	return 0;
>  }
>  
> -/**
> - * intel_plane_destroy - destroy a plane
> - * @plane: plane to destroy
> - *
> - * Common destruction function for all types of planes (primary, cursor,
> - * sprite).
> - */
> -void intel_plane_destroy(struct drm_plane *plane)
> -{
> -	drm_plane_cleanup(plane);
> -	kfree(to_intel_plane(plane));
> -}
> -
>  static u32 intel_encoder_possible_clones(struct intel_encoder *encoder)
>  {
>  	struct drm_device *dev = encoder->base.dev;
> diff --git a/drivers/gpu/drm/i915/display/intel_display.h b/drivers/gpu/drm/i915/display/intel_display.h
> index e14aa773323e..2e11fc2ba1f4 100644
> --- a/drivers/gpu/drm/i915/display/intel_display.h
> +++ b/drivers/gpu/drm/i915/display/intel_display.h
> @@ -450,7 +450,6 @@ bool intel_pipe_config_compare(const struct intel_crtc_state *current_config,
>  			       const struct intel_crtc_state *pipe_config,
>  			       bool fastset);
>  
> -void intel_plane_destroy(struct drm_plane *plane);
>  void i9xx_set_pipeconf(const struct intel_crtc_state *crtc_state);
>  void ilk_set_pipeconf(const struct intel_crtc_state *crtc_state);
>  void intel_enable_transcoder(const struct intel_crtc_state *new_crtc_state);

-- 
Jani Nikula, Intel

  reply	other threads:[~2025-02-13 19:17 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-13 15:02 [PATCH 00/12] drm/i915: Hoist some stuff out from intel_display.c Ville Syrjala
2025-02-13 15:02 ` [PATCH 01/12] drm/i915: Move modeset_retry stuff into intel_connector.c Ville Syrjala
2025-02-13 19:11   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 02/12] drm/i915: Always initialize connector->modeset_retry_work Ville Syrjala
2025-02-13 19:11   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 03/12] drm/i915: Extract intel_connector_cancel_modeset_retry_work() Ville Syrjala
2025-02-13 19:12   ` Jani Nikula
2025-02-13 19:13   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 04/12] drm/i915: Extract intel_hdcp_cancel_works() Ville Syrjala
2025-02-13 19:14   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 05/12] drm/i915: Move intel_hpd_poll_fini() into intel_hotplug.c Ville Syrjala
2025-02-13 19:15   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 06/12] drm/i915: Move intel_plane_destroy() into intel_atomic_plane.c Ville Syrjala
2025-02-13 19:17   ` Jani Nikula [this message]
2025-02-13 15:02 ` [PATCH 07/12] drm/i915: Relocate vlv_wait_port_ready() Ville Syrjala
2025-02-13 19:18   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 08/12] drm/i915: Simplify vlv_wait_port_ready() arguments Ville Syrjala
2025-02-13 19:19   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 09/12] drm/i915: Relocate intel_plane_uses_fence() Ville Syrjala
2025-02-13 19:20   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 10/12] drm/i915: Relocate intel_{rotation, remapped}_info_size() Ville Syrjala
2025-02-13 19:21   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 11/12] drm/i915: Relocate some other plane fb related stuff into intel_fb.c Ville Syrjala
2025-02-13 19:22   ` Jani Nikula
2025-02-13 15:02 ` [PATCH 12/12] drm/i915: s/state/plane_state/ Ville Syrjala
2025-02-13 19:23   ` Jani Nikula
2025-02-13 15:25 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915: Hoist some stuff out from intel_display.c Patchwork
2025-02-13 15:25 ` ✗ Fi.CI.SPARSE: " Patchwork
2025-02-13 15:44 ` ✗ i915.CI.BAT: failure " Patchwork
2025-02-14 18:22 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915: Hoist some stuff out from intel_display.c (rev2) Patchwork
2025-02-14 18:22 ` ✗ Fi.CI.SPARSE: " Patchwork
2025-02-14 18:39 ` ✗ i915.CI.BAT: failure " Patchwork
2025-02-15  3:02 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915: Hoist some stuff out from intel_display.c (rev3) Patchwork
2025-02-15  3:02 ` ✗ Fi.CI.SPARSE: " Patchwork
2025-02-15  3:18 ` ✓ i915.CI.BAT: success " Patchwork
2025-02-15  6:56 ` ✗ i915.CI.Full: failure " Patchwork

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=8734ghy7r4.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=intel-gfx@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox