Re: [PATCH v2 14/19] drm/tilcdc: drop use of drmP.h

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 16/07/2019 09:42, Sam Ravnborg wrote:
> Dropped drmP.h and all other header files not used by tilcdc_drv.h.
> Added the minimal includes and forwards to make the header file
> self-contained.
> 
> Then dropped the remaining uses of drmP.h and fixed all fall-out.
> 
> Signed-off-by: Sam Ravnborg <sam@xxxxxxxxxxxx>
> Acked-by: Emil Velikov <emil.velikov@xxxxxxxxxxxxx>
> Cc: Jyri Sarha <jsarha@xxxxxx>
> Cc: Tomi Valkeinen <tomi.valkeinen@xxxxxx>
> Cc: David Airlie <airlied@xxxxxxxx>
> Cc: Daniel Vetter <daniel@xxxxxxxx>

Acked-by: Jyri Sarha <jsarha@xxxxxx>

> ---
>  drivers/gpu/drm/tilcdc/tilcdc_crtc.c     | 18 ++++++++------
>  drivers/gpu/drm/tilcdc/tilcdc_drv.c      | 19 ++++++++++++---
>  drivers/gpu/drm/tilcdc/tilcdc_drv.h      | 31 +++++++++++++-----------
>  drivers/gpu/drm/tilcdc/tilcdc_external.c |  1 +
>  drivers/gpu/drm/tilcdc/tilcdc_panel.c    | 11 ++++++---
>  drivers/gpu/drm/tilcdc/tilcdc_plane.c    |  4 +--
>  drivers/gpu/drm/tilcdc/tilcdc_tfp410.c   |  8 +++---
>  7 files changed, 57 insertions(+), 35 deletions(-)
> 
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> index 1067e702c22c..8c2025780372 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> @@ -15,16 +15,20 @@
>   * this program.  If not, see <http://www.gnu.org/licenses/>.
>   */
>  
> +#include <linux/delay.h>
> +#include <linux/dma-mapping.h>
> +#include <linux/of_graph.h>
> +#include <linux/pm_runtime.h>
> +
>  #include <drm/drm_atomic.h>
>  #include <drm/drm_atomic_helper.h>
>  #include <drm/drm_crtc.h>
> -#include <drm/drm_flip_work.h>
> -#include <drm/drm_plane_helper.h>
> -#include <linux/workqueue.h>
> -#include <linux/completion.h>
> -#include <linux/dma-mapping.h>
> -#include <linux/of_graph.h>
> -#include <linux/math64.h>
> +#include <drm/drm_fb_cma_helper.h>
> +#include <drm/drm_fourcc.h>
> +#include <drm/drm_gem_cma_helper.h>
> +#include <drm/drm_modeset_helper_vtables.h>
> +#include <drm/drm_print.h>
> +#include <drm/drm_vblank.h>
>  
>  #include "tilcdc_drv.h"
>  #include "tilcdc_regs.h"
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_drv.c b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> index b6b71e86e238..8e228c75b68e 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> @@ -18,19 +18,30 @@
>  /* LCDC DRM driver, based on da8xx-fb */
>  
>  #include <linux/component.h>
> +#include <linux/mod_devicetable.h>
> +#include <linux/module.h>
>  #include <linux/pinctrl/consumer.h>
> -#include <linux/suspend.h>
> -#include <drm/drm_atomic.h>
> +#include <linux/platform_device.h>
> +#include <linux/pm_runtime.h>
> +
>  #include <drm/drm_atomic_helper.h>
> +#include <drm/drm_debugfs.h>
> +#include <drm/drm_drv.h>
>  #include <drm/drm_fb_helper.h>
> +#include <drm/drm_fourcc.h>
> +#include <drm/drm_gem_cma_helper.h>
>  #include <drm/drm_gem_framebuffer_helper.h>
> +#include <drm/drm_irq.h>
> +#include <drm/drm_mm.h>
>  #include <drm/drm_probe_helper.h>
> +#include <drm/drm_vblank.h>
> +
>  
>  #include "tilcdc_drv.h"
> +#include "tilcdc_external.h"
> +#include "tilcdc_panel.h"
>  #include "tilcdc_regs.h"
>  #include "tilcdc_tfp410.h"
> -#include "tilcdc_panel.h"
> -#include "tilcdc_external.h"
>  
>  static LIST_HEAD(module_list);
>  
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_drv.h b/drivers/gpu/drm/tilcdc/tilcdc_drv.h
> index d86397da12a9..50c208c48be0 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_drv.h
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_drv.h
> @@ -18,21 +18,24 @@
>  #ifndef __TILCDC_DRV_H__
>  #define __TILCDC_DRV_H__
>  
> -#include <linux/clk.h>
>  #include <linux/cpufreq.h>
> -#include <linux/module.h>
> -#include <linux/platform_device.h>
> -#include <linux/pm.h>
> -#include <linux/pm_runtime.h>
> -#include <linux/slab.h>
> -#include <linux/of.h>
> -#include <linux/of_device.h>
> -#include <linux/list.h>
> -
> -#include <drm/drmP.h>
> -#include <drm/drm_bridge.h>
> -#include <drm/drm_fb_cma_helper.h>
> -#include <drm/drm_gem_cma_helper.h>
> +#include <linux/irqreturn.h>
> +
> +#include <drm/drm_print.h>
> +
> +struct clk;
> +struct workqueue_struct;
> +
> +struct drm_connector;
> +struct drm_connector_helper_funcs;
> +struct drm_crtc;
> +struct drm_device;
> +struct drm_display_mode;
> +struct drm_encoder;
> +struct drm_framebuffer;
> +struct drm_minor;
> +struct drm_pending_vblank_event;
> +struct drm_plane;
>  
>  /* Defaulting to pixel clock defined on AM335x */
>  #define TILCDC_DEFAULT_MAX_PIXELCLOCK  126000
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_external.c b/drivers/gpu/drm/tilcdc/tilcdc_external.c
> index e9969cd36610..0f3419a19d71 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_external.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_external.c
> @@ -10,6 +10,7 @@
>  
>  #include <linux/component.h>
>  #include <linux/of_graph.h>
> +
>  #include <drm/drm_atomic_helper.h>
>  #include <drm/drm_of.h>
>  
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_panel.c b/drivers/gpu/drm/tilcdc/tilcdc_panel.c
> index 5d532a596e1e..e1c39712b67a 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_panel.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_panel.c
> @@ -15,14 +15,17 @@
>   * this program.  If not, see <http://www.gnu.org/licenses/>.
>   */
>  
> -#include <linux/pinctrl/pinmux.h>
> -#include <linux/pinctrl/consumer.h>
> -#include <linux/backlight.h>
>  #include <linux/gpio/consumer.h>
> +#include <linux/pinctrl/consumer.h>
> +#include <linux/platform_device.h>
> +
>  #include <video/display_timing.h>
>  #include <video/of_display_timing.h>
>  #include <video/videomode.h>
> -#include <drm/drm_atomic_helper.h>
> +
> +#include <drm/drm_atomic_state_helper.h>
> +#include <drm/drm_connector.h>
> +#include <drm/drm_modeset_helper_vtables.h>
>  #include <drm/drm_probe_helper.h>
>  
>  #include "tilcdc_drv.h"
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_plane.c b/drivers/gpu/drm/tilcdc/tilcdc_plane.c
> index 7667b038ae7f..347ca8656aef 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_plane.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_plane.c
> @@ -15,12 +15,10 @@
>   * this program.  If not, see <http://www.gnu.org/licenses/>.
>   */
>  
> -#include <drm/drmP.h>
> -
>  #include <drm/drm_atomic.h>
>  #include <drm/drm_plane_helper.h>
>  #include <drm/drm_atomic_helper.h>
> -#include <uapi/drm/drm_fourcc.h>
> +#include <drm/drm_fourcc.h>
>  
>  #include "tilcdc_drv.h"
>  
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_tfp410.c b/drivers/gpu/drm/tilcdc/tilcdc_tfp410.c
> index fe59fbfdde69..da642c725cd6 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_tfp410.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_tfp410.c
> @@ -15,12 +15,14 @@
>   * this program.  If not, see <http://www.gnu.org/licenses/>.
>   */
>  
> -#include <linux/i2c.h>
>  #include <linux/gpio.h>
> +#include <linux/mod_devicetable.h>
>  #include <linux/of_gpio.h>
> -#include <linux/pinctrl/pinmux.h>
> -#include <linux/pinctrl/consumer.h>
> +#include <linux/platform_device.h>
> +
>  #include <drm/drm_atomic_helper.h>
> +#include <drm/drm_encoder.h>
> +#include <drm/drm_modeset_helper_vtables.h>
>  #include <drm/drm_probe_helper.h>
>  
>  #include "tilcdc_drv.h"
> 


-- 
Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki.
Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux