linux-renesas-soc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Cc: dri-devel@lists.freedesktop.org,
	linux-renesas-soc@vger.kernel.org,
	kieran.bingham@ideasonboard.com
Subject: Re: [PATCH] drm: rcar-du: Remove inclusion of drmP.h
Date: Thu, 27 Dec 2018 13:18:41 +0100	[thread overview]
Message-ID: <20181227121841.GG9058@dvetter-linux.ger.corp.intel.com> (raw)
In-Reply-To: <20181227101206.1143-1-laurent.pinchart+renesas@ideasonboard.com>

On Thu, Dec 27, 2018 at 12:12:06PM +0200, Laurent Pinchart wrote:
> The DRM kernel API used to be defined in a handful of headers, pulled in
> through drmP.h. It has since been split in multiple headers for the
> different DRM components, and drmP.h turned into a legacy header that
> just pulls in most of the DRM kernel API (and a large number of other
> miscellaneous kernel headers).
> 
> In order to speed up compilation, replace inclusion of drmP.h with only
> the required headers. It turns out that the rcar-du-drm driver already
> includes most of the necessary headers, so the change is simple.
> 
> While at it, remove unneeder inclusion of other headers, and unneeded
> forward declarations of structures.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>

Nice, first driver where all that header cleanup work finally lead
somewhere useful!

Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> ---
>  drivers/gpu/drm/rcar-du/rcar_du_crtc.c    | 1 -
>  drivers/gpu/drm/rcar-du/rcar_du_crtc.h    | 1 -
>  drivers/gpu/drm/rcar-du/rcar_du_drv.c     | 1 -
>  drivers/gpu/drm/rcar-du/rcar_du_drv.h     | 1 +
>  drivers/gpu/drm/rcar-du/rcar_du_encoder.c | 1 -
>  drivers/gpu/drm/rcar-du/rcar_du_encoder.h | 2 --
>  drivers/gpu/drm/rcar-du/rcar_du_kms.c     | 1 -
>  drivers/gpu/drm/rcar-du/rcar_du_plane.c   | 1 -
>  drivers/gpu/drm/rcar-du/rcar_du_plane.h   | 3 +--
>  drivers/gpu/drm/rcar-du/rcar_du_vsp.c     | 1 -
>  drivers/gpu/drm/rcar-du/rcar_du_vsp.h     | 3 +--
>  11 files changed, 3 insertions(+), 13 deletions(-)
> 
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_crtc.c b/drivers/gpu/drm/rcar-du/rcar_du_crtc.c
> index 40b7f17159b0..771b460c7216 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_crtc.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_crtc.c
> @@ -11,7 +11,6 @@
>  #include <linux/mutex.h>
>  #include <linux/sys_soc.h>
>  
> -#include <drm/drmP.h>
>  #include <drm/drm_atomic.h>
>  #include <drm/drm_atomic_helper.h>
>  #include <drm/drm_crtc.h>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_crtc.h b/drivers/gpu/drm/rcar-du/rcar_du_crtc.h
> index ec47f164e69b..bcb35b0b7612 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_crtc.h
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_crtc.h
> @@ -14,7 +14,6 @@
>  #include <linux/spinlock.h>
>  #include <linux/wait.h>
>  
> -#include <drm/drmP.h>
>  #include <drm/drm_crtc.h>
>  
>  #include <media/vsp1.h>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_drv.c b/drivers/gpu/drm/rcar-du/rcar_du_drv.c
> index eef86c48edad..d1f305694367 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_drv.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_drv.c
> @@ -17,7 +17,6 @@
>  #include <linux/slab.h>
>  #include <linux/wait.h>
>  
> -#include <drm/drmP.h>
>  #include <drm/drm_atomic_helper.h>
>  #include <drm/drm_crtc_helper.h>
>  #include <drm/drm_fb_cma_helper.h>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_drv.h b/drivers/gpu/drm/rcar-du/rcar_du_drv.h
> index 752617c73c73..6c187d0bf7c2 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_drv.h
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_drv.h
> @@ -20,6 +20,7 @@
>  struct clk;
>  struct device;
>  struct drm_device;
> +struct drm_property;
>  struct rcar_du_device;
>  
>  #define RCAR_DU_FEATURE_CRTC_IRQ_CLOCK	BIT(0)	/* Per-CRTC IRQ and clock */
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_encoder.c b/drivers/gpu/drm/rcar-du/rcar_du_encoder.c
> index a123c28ea6ed..f16209499117 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_encoder.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_encoder.c
> @@ -9,7 +9,6 @@
>  
>  #include <linux/export.h>
>  
> -#include <drm/drmP.h>
>  #include <drm/drm_crtc.h>
>  #include <drm/drm_crtc_helper.h>
>  #include <drm/drm_panel.h>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_encoder.h b/drivers/gpu/drm/rcar-du/rcar_du_encoder.h
> index ce3cbc85695e..552f2a02e5b5 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_encoder.h
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_encoder.h
> @@ -10,10 +10,8 @@
>  #ifndef __RCAR_DU_ENCODER_H__
>  #define __RCAR_DU_ENCODER_H__
>  
> -#include <drm/drm_crtc.h>
>  #include <drm/drm_encoder.h>
>  
> -struct drm_panel;
>  struct rcar_du_device;
>  
>  struct rcar_du_encoder {
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_kms.c b/drivers/gpu/drm/rcar-du/rcar_du_kms.c
> index d8ef3a86b0b2..e4b248e368d6 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_kms.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_kms.c
> @@ -7,7 +7,6 @@
>   * Contact: Laurent Pinchart (laurent.pinchart@ideasonboard.com)
>   */
>  
> -#include <drm/drmP.h>
>  #include <drm/drm_atomic.h>
>  #include <drm/drm_atomic_helper.h>
>  #include <drm/drm_crtc.h>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_plane.c b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> index 39d5ae3fdf72..fa6b9aabc832 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_plane.c
> @@ -7,7 +7,6 @@
>   * Contact: Laurent Pinchart (laurent.pinchart@ideasonboard.com)
>   */
>  
> -#include <drm/drmP.h>
>  #include <drm/drm_atomic.h>
>  #include <drm/drm_atomic_helper.h>
>  #include <drm/drm_crtc.h>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_plane.h b/drivers/gpu/drm/rcar-du/rcar_du_plane.h
> index 2f223a4c1d33..81bbf207ad0e 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_plane.h
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_plane.h
> @@ -10,8 +10,7 @@
>  #ifndef __RCAR_DU_PLANE_H__
>  #define __RCAR_DU_PLANE_H__
>  
> -#include <drm/drmP.h>
> -#include <drm/drm_crtc.h>
> +#include <drm/drm_plane.h>
>  
>  struct rcar_du_format_info;
>  struct rcar_du_group;
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_vsp.c b/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> index 4576119e7777..dec314a687e0 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_vsp.c
> @@ -7,7 +7,6 @@
>   * Contact: Laurent Pinchart (laurent.pinchart@ideasonboard.com)
>   */
>  
> -#include <drm/drmP.h>
>  #include <drm/drm_atomic_helper.h>
>  #include <drm/drm_crtc.h>
>  #include <drm/drm_crtc_helper.h>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_vsp.h b/drivers/gpu/drm/rcar-du/rcar_du_vsp.h
> index e8c14dc5cb93..db232037f24a 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_vsp.h
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_vsp.h
> @@ -10,8 +10,7 @@
>  #ifndef __RCAR_DU_VSP_H__
>  #define __RCAR_DU_VSP_H__
>  
> -#include <drm/drmP.h>
> -#include <drm/drm_crtc.h>
> +#include <drm/drm_plane.h>
>  
>  struct rcar_du_format_info;
>  struct rcar_du_vsp;
> -- 
> Regards,
> 
> Laurent Pinchart
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

  reply	other threads:[~2018-12-27 12:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-27 10:12 [PATCH] drm: rcar-du: Remove inclusion of drmP.h Laurent Pinchart
2018-12-27 12:18 ` Daniel Vetter [this message]
2018-12-29 13:07 ` Kieran Bingham

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=20181227121841.GG9058@dvetter-linux.ger.corp.intel.com \
    --to=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=kieran.bingham@ideasonboard.com \
    --cc=laurent.pinchart+renesas@ideasonboard.com \
    --cc=linux-renesas-soc@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).