linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Sam Ravnborg <sam@ravnborg.org>
To: Thomas Zimmermann <tzimmermann@suse.de>
Cc: alexander.deucher@amd.com, christian.koenig@amd.com,
	airlied@gmail.com, daniel@ffwll.ch,
	maarten.lankhorst@linux.intel.com, mripard@kernel.org,
	patrik.r.jakobsson@gmail.com, thierry.reding@gmail.com,
	f.fainelli@gmail.com, james.qian.wang@arm.com,
	liviu.dudau@arm.com, dri-devel@lists.freedesktop.org,
	bcm-kernel-feedback-list@broadcom.com,
	linux-rpi-kernel@lists.infradead.org,
	linux-arm-kernel@lists.infradead.org,
	amd-gfx@lists.freedesktop.org
Subject: Re: [PATCH v2 01/10] drm: Include <linux/backlight.h> where needed
Date: Fri, 13 Jan 2023 16:09:05 +0100	[thread overview]
Message-ID: <Y8F0EW3rVPiuzciK@ravnborg.org> (raw)
In-Reply-To: <20230111130206.29974-2-tzimmermann@suse.de>

Hi Thomas,
On Wed, Jan 11, 2023 at 02:01:57PM +0100, Thomas Zimmermann wrote:
> Include <linux/backlight.h> in source files that need it. Some of
> DRM's source code gets the backlight header via drm_crtc_helper.h
> and <linux/fb.h>, which can leed to unnecessary recompilation. If
> possible, do not include drm_crtc_helper.h any longer.
Are you planning a clean-up of drm_crtc_helper.h later?
With a handful of forward it could losse all includes.

> 
> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
> Acked-by: Christian König <christian.koenig@amd.com> # amd
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c          | 2 +-
>  drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 +
>  drivers/gpu/drm/gma500/backlight.c                | 2 ++
>  drivers/gpu/drm/radeon/radeon_acpi.c              | 2 +-
>  4 files changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c
> index 57b5e11446c6..f29c1d0ad4c1 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c
> @@ -24,6 +24,7 @@
>  
>  #include <linux/pci.h>
>  #include <linux/acpi.h>
> +#include <linux/backlight.h>
>  #include <linux/slab.h>
>  #include <linux/power_supply.h>
>  #include <linux/pm_runtime.h>
> @@ -31,7 +32,6 @@
>  #include <acpi/video.h>
>  #include <acpi/actbl.h>
>  
> -#include <drm/drm_crtc_helper.h>
>  #include "amdgpu.h"
>  #include "amdgpu_pm.h"
>  #include "amdgpu_display.h"
> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> index 1b7f20a9d4ae..55a845eb0c6d 100644
> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> @@ -67,6 +67,7 @@
>  #include "ivsrcid/ivsrcid_vislands30.h"
>  
>  #include "i2caux_interface.h"
> +#include <linux/backlight.h>
>  #include <linux/module.h>
>  #include <linux/moduleparam.h>
>  #include <linux/types.h>
> diff --git a/drivers/gpu/drm/gma500/backlight.c b/drivers/gpu/drm/gma500/backlight.c
> index 577a4987b193..8711a7a5b8da 100644
> --- a/drivers/gpu/drm/gma500/backlight.c
> +++ b/drivers/gpu/drm/gma500/backlight.c
> @@ -7,6 +7,8 @@
>   * Authors: Eric Knopp
>   */
>  
> +#include <linux/backlight.h>
> +
>  #include <acpi/video.h>
>  
>  #include "psb_drv.h"
> diff --git a/drivers/gpu/drm/radeon/radeon_acpi.c b/drivers/gpu/drm/radeon/radeon_acpi.c
> index b603c0b77075..5771d1fcb073 100644
> --- a/drivers/gpu/drm/radeon/radeon_acpi.c
> +++ b/drivers/gpu/drm/radeon/radeon_acpi.c
> @@ -22,6 +22,7 @@
>   */
>  
>  #include <linux/acpi.h>
> +#include <linux/backlight.h>
>  #include <linux/pci.h>
>  #include <linux/pm_runtime.h>
>  #include <linux/power_supply.h>
> @@ -30,7 +31,6 @@
>  #include <acpi/acpi_bus.h>
>  #include <acpi/video.h>
>  
> -#include <drm/drm_crtc_helper.h>
>  #include <drm/drm_probe_helper.h>
>  
>  #include "atom.h"
> -- 
> 2.39.0

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2023-01-13 15:10 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-11 13:01 [PATCH v2 00/10] drm: Do not include <linux/fb.h> unnecessarily Thomas Zimmermann
2023-01-11 13:01 ` [PATCH v2 01/10] drm: Include <linux/backlight.h> where needed Thomas Zimmermann
2023-01-13 15:09   ` Sam Ravnborg [this message]
2023-01-13 15:38     ` Thomas Zimmermann
2023-01-11 13:01 ` [PATCH v2 02/10] drm: Include <linux/of.h> " Thomas Zimmermann
2023-01-11 13:15   ` Liviu Dudau
2023-01-11 16:08   ` Ville Syrjälä
2023-01-13 15:11     ` Sam Ravnborg
2023-01-13 15:47       ` Ville Syrjälä
2023-01-11 13:01 ` [PATCH v2 03/10] drm: Don't include <linux/fb.h> in drm_crtc_helper.h Thomas Zimmermann
2023-01-11 16:03   ` Ville Syrjälä
2023-01-11 13:02 ` [PATCH v2 04/10] drm/amdgpu: Do not include <linux/fb.h> Thomas Zimmermann
2023-01-11 13:02 ` [PATCH v2 05/10] drm/panel: " Thomas Zimmermann
2023-01-13 15:12   ` Sam Ravnborg
2023-01-11 13:02 ` [PATCH v2 06/10] drm: Define enum mode_set_atomic in drm_modeset_helper_tables.h Thomas Zimmermann
2023-01-11 16:03   ` Ville Syrjälä
2023-01-11 13:02 ` [PATCH v2 07/10] drm/amdgpu: Do not include <drm/drm_fb_helper.h> Thomas Zimmermann
2023-01-11 13:21   ` Christian König
2023-01-11 13:34     ` Thomas Zimmermann
2023-01-11 13:02 ` [PATCH v2 08/10] drm/nouveau: " Thomas Zimmermann
2023-01-11 13:02 ` [PATCH v2 09/10] drm/radeon: Remove trailing whitespaces Thomas Zimmermann
2023-01-11 13:02 ` [PATCH v2 10/10] drm/radeon: Do not include <drm/drm_fb_helper.h> Thomas Zimmermann
2023-01-13 15:14 ` [PATCH v2 00/10] drm: Do not include <linux/fb.h> unnecessarily Sam Ravnborg

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=Y8F0EW3rVPiuzciK@ravnborg.org \
    --to=sam@ravnborg.org \
    --cc=airlied@gmail.com \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=christian.koenig@amd.com \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=f.fainelli@gmail.com \
    --cc=james.qian.wang@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-rpi-kernel@lists.infradead.org \
    --cc=liviu.dudau@arm.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=patrik.r.jakobsson@gmail.com \
    --cc=thierry.reding@gmail.com \
    --cc=tzimmermann@suse.de \
    /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).