All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@intel.com>
To: "Kandpal, Suraj" <suraj.kandpal@intel.com>,
	"intel-gfx@lists.freedesktop.org"
	<intel-gfx@lists.freedesktop.org>,
	"intel-xe@lists.freedesktop.org" <intel-xe@lists.freedesktop.org>
Subject: RE: [PATCH v2] drm/i915/display: drop unnecessary i915_drv.h includes
Date: Wed, 18 Dec 2024 15:05:42 +0200	[thread overview]
Message-ID: <87cyhpqgyh.fsf@intel.com> (raw)
In-Reply-To: <SN7PR11MB67508C4AF50023C28E2D35D5E3052@SN7PR11MB6750.namprd11.prod.outlook.com>

On Wed, 18 Dec 2024, "Kandpal, Suraj" <suraj.kandpal@intel.com> wrote:
>> -----Original Message-----
>> From: Intel-gfx <intel-gfx-bounces@lists.freedesktop.org> On Behalf Of Jani
>> Nikula
>> Sent: Tuesday, December 17, 2024 6:52 PM
>> To: intel-gfx@lists.freedesktop.org; intel-xe@lists.freedesktop.org
>> Cc: Nikula, Jani <jani.nikula@intel.com>
>> Subject: [PATCH v2] drm/i915/display: drop unnecessary i915_drv.h includes
>>
>> Now that we don't include i915_drv.h via any headers from display, we can
>> reliably remove unnecessary i915_drv.h includes and be sure they're not
>> indirectly included. Add other includes where needed.
>>
>> v2: Fix 32-bit build
>>
>> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>
> LGTM,
> Reviewed-by: Suraj Kandpal <suraj.kandpal@intel.com>

Thanks, pushed to din.

BR,
Jani.

>
>> ---
>>  drivers/gpu/drm/i915/display/dvo_ns2501.c                  | 1 -
>>  drivers/gpu/drm/i915/display/i9xx_display_sr.c             | 3 ++-
>>  drivers/gpu/drm/i915/display/intel_acpi.c                  | 3 ++-
>>  drivers/gpu/drm/i915/display/intel_alpm.c                  | 1 -
>>  .../gpu/drm/i915/display/intel_display_debugfs_params.c    | 3 ++-
>>  drivers/gpu/drm/i915/display/intel_display_params.c        | 7 ++++++-
>>  drivers/gpu/drm/i915/display/intel_display_power_map.c     | 6 ++----
>>  drivers/gpu/drm/i915/display/intel_display_snapshot.c      | 4 +++-
>>  drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c      | 3 ++-
>>  drivers/gpu/drm/i915/display/intel_dp_hdcp.c               | 1 -
>>  drivers/gpu/drm/i915/display/intel_dp_link_training.c      | 3 ++-
>>  drivers/gpu/drm/i915/display/intel_dp_test.c               | 1 -
>>  drivers/gpu/drm/i915/display/intel_dp_tunnel.c             | 3 +--
>>  drivers/gpu/drm/i915/display/intel_hti.c                   | 3 ++-
>>  drivers/gpu/drm/i915/display/intel_link_bw.c               | 3 +--
>>  drivers/gpu/drm/i915/display/intel_load_detect.c           | 2 +-
>>  drivers/gpu/drm/i915/display/intel_lspcon.c                | 4 ++--
>>  drivers/gpu/drm/i915/display/intel_panel.c                 | 1 -
>>  drivers/gpu/drm/i915/display/intel_pfit.c                  | 2 +-
>>  drivers/gpu/drm/i915/display/intel_quirks.c                | 2 +-
>>  drivers/gpu/drm/i915/display/intel_vrr.c                   | 1 -
>>  21 files changed, 30 insertions(+), 27 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/i915/display/dvo_ns2501.c
>> b/drivers/gpu/drm/i915/display/dvo_ns2501.c
>> index 9d47f8a93e94..686393dfbbf5 100644
>> --- a/drivers/gpu/drm/i915/display/dvo_ns2501.c
>> +++ b/drivers/gpu/drm/i915/display/dvo_ns2501.c
>> @@ -26,7 +26,6 @@
>>   *
>>   */
>>
>> -#include "i915_drv.h"
>>  #include "intel_display_types.h"
>>  #include "intel_dvo_dev.h"
>>
>> diff --git a/drivers/gpu/drm/i915/display/i9xx_display_sr.c
>> b/drivers/gpu/drm/i915/display/i9xx_display_sr.c
>> index f7d4a6cfce5f..32abe9743014 100644
>> --- a/drivers/gpu/drm/i915/display/i9xx_display_sr.c
>> +++ b/drivers/gpu/drm/i915/display/i9xx_display_sr.c
>> @@ -3,7 +3,8 @@
>>   * Copyright © 2024 Intel Corporation
>>   */
>>
>> -#include "i915_drv.h"
>> +#include <drm/drm_device.h>
>> +
>>  #include "i915_reg.h"
>>  #include "i9xx_display_sr.h"
>>  #include "i9xx_wm_regs.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_acpi.c
>> b/drivers/gpu/drm/i915/display/intel_acpi.c
>> index c3b29a331d72..bbf8c5a8fdbd 100644
>> --- a/drivers/gpu/drm/i915/display/intel_acpi.c
>> +++ b/drivers/gpu/drm/i915/display/intel_acpi.c
>> @@ -9,8 +9,9 @@
>>  #include <linux/acpi.h>
>>  #include <acpi/video.h>
>>
>> -#include "i915_drv.h"
>> +#include "i915_utils.h"
>>  #include "intel_acpi.h"
>> +#include "intel_display_core.h"
>>  #include "intel_display_types.h"
>>
>>  #define INTEL_DSM_REVISION_ID 1 /* For Calpella anyway... */ diff --git
>> a/drivers/gpu/drm/i915/display/intel_alpm.c
>> b/drivers/gpu/drm/i915/display/intel_alpm.c
>> index c7ccd5a10012..55f3ae1e68c9 100644
>> --- a/drivers/gpu/drm/i915/display/intel_alpm.c
>> +++ b/drivers/gpu/drm/i915/display/intel_alpm.c
>> @@ -5,7 +5,6 @@
>>
>>  #include <linux/debugfs.h>
>>
>> -#include "i915_drv.h"
>>  #include "intel_alpm.h"
>>  #include "intel_crtc.h"
>>  #include "intel_de.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_display_debugfs_params.c
>> b/drivers/gpu/drm/i915/display/intel_display_debugfs_params.c
>> index ec3ed29a83c9..88914a1f3f62 100644
>> --- a/drivers/gpu/drm/i915/display/intel_display_debugfs_params.c
>> +++ b/drivers/gpu/drm/i915/display/intel_display_debugfs_params.c
>> @@ -7,9 +7,10 @@
>>  #include <linux/kernel.h>
>>
>>  #include <drm/drm_drv.h>
>> +#include <drm/drm_file.h>
>>
>> +#include "intel_display_core.h"
>>  #include "intel_display_debugfs_params.h"
>> -#include "i915_drv.h"
>>  #include "intel_display_params.h"
>>
>>  /* int param */
>> diff --git a/drivers/gpu/drm/i915/display/intel_display_params.c
>> b/drivers/gpu/drm/i915/display/intel_display_params.c
>> index dc666aefa362..f92e4640a613 100644
>> --- a/drivers/gpu/drm/i915/display/intel_display_params.c
>> +++ b/drivers/gpu/drm/i915/display/intel_display_params.c
>> @@ -3,8 +3,13 @@
>>   * Copyright © 2023 Intel Corporation
>>   */
>>
>> +#include <linux/moduleparam.h>
>> +#include <linux/slab.h>
>> +#include <linux/string_choices.h>
>> +
>> +#include <drm/drm_print.h>
>> +
>>  #include "intel_display_params.h"
>> -#include "i915_drv.h"
>>
>>  #define intel_display_param_named(name, T, perm, desc) \
>>       module_param_named(name, intel_display_modparams.name, T,
>> perm); \ diff --git a/drivers/gpu/drm/i915/display/intel_display_power_map.c
>> b/drivers/gpu/drm/i915/display/intel_display_power_map.c
>> index fb2df5c382d8..0c8ac1af6db7 100644
>> --- a/drivers/gpu/drm/i915/display/intel_display_power_map.c
>> +++ b/drivers/gpu/drm/i915/display/intel_display_power_map.c
>> @@ -3,14 +3,12 @@
>>   * Copyright © 2022 Intel Corporation
>>   */
>>
>> -#include "i915_drv.h"
>>  #include "i915_reg.h"
>> -
>> -#include "vlv_sideband_reg.h"
>> -
>> +#include "intel_display_core.h"
>>  #include "intel_display_power_map.h"
>>  #include "intel_display_power_well.h"
>>  #include "intel_display_types.h"
>> +#include "vlv_sideband_reg.h"
>>
>>  #define __LIST_INLINE_ELEMS(__elem_type, ...) \
>>       ((__elem_type[]) { __VA_ARGS__ })
>> diff --git a/drivers/gpu/drm/i915/display/intel_display_snapshot.c
>> b/drivers/gpu/drm/i915/display/intel_display_snapshot.c
>> index 030c4f873da1..25ba043cbb65 100644
>> --- a/drivers/gpu/drm/i915/display/intel_display_snapshot.c
>> +++ b/drivers/gpu/drm/i915/display/intel_display_snapshot.c
>> @@ -3,7 +3,9 @@
>>
>>  #include <linux/slab.h>
>>
>> -#include "i915_drv.h"
>> +#include <drm/drm_drv.h>
>> +
>> +#include "intel_display_core.h"
>>  #include "intel_display_device.h"
>>  #include "intel_display_params.h"
>>  #include "intel_display_snapshot.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> index 33f72db99b58..c846ef4acf5b 100644
>> --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> @@ -34,8 +34,9 @@
>>   * for some reason.
>>   */
>>
>> -#include "i915_drv.h"
>> +#include "i915_utils.h"
>>  #include "intel_backlight.h"
>> +#include "intel_display_core.h"
>>  #include "intel_display_types.h"
>>  #include "intel_dp.h"
>>  #include "intel_dp_aux_backlight.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_dp_hdcp.c
>> b/drivers/gpu/drm/i915/display/intel_dp_hdcp.c
>> index 6cea66069abd..00c493cc8a4b 100644
>> --- a/drivers/gpu/drm/i915/display/intel_dp_hdcp.c
>> +++ b/drivers/gpu/drm/i915/display/intel_dp_hdcp.c
>> @@ -11,7 +11,6 @@
>>  #include <drm/display/drm_hdcp_helper.h>  #include <drm/drm_print.h>
>>
>> -#include "i915_drv.h"
>>  #include "i915_reg.h"
>>  #include "intel_ddi.h"
>>  #include "intel_de.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_dp_link_training.c
>> b/drivers/gpu/drm/i915/display/intel_dp_link_training.c
>> index 02ad0fbb1859..8b1977cfec50 100644
>> --- a/drivers/gpu/drm/i915/display/intel_dp_link_training.c
>> +++ b/drivers/gpu/drm/i915/display/intel_dp_link_training.c
>> @@ -25,7 +25,8 @@
>>
>>  #include <drm/display/drm_dp_helper.h>
>>
>> -#include "i915_drv.h"
>> +#include "i915_utils.h"
>> +#include "intel_display_core.h"
>>  #include "intel_display_types.h"
>>  #include "intel_dp.h"
>>  #include "intel_dp_link_training.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_dp_test.c
>> b/drivers/gpu/drm/i915/display/intel_dp_test.c
>> index e05819300d77..380b359b0420 100644
>> --- a/drivers/gpu/drm/i915/display/intel_dp_test.c
>> +++ b/drivers/gpu/drm/i915/display/intel_dp_test.c
>> @@ -8,7 +8,6 @@
>>  #include <drm/drm_edid.h>
>>  #include <drm/drm_probe_helper.h>
>>
>> -#include "i915_drv.h"
>>  #include "i915_reg.h"
>>  #include "intel_ddi.h"
>>  #include "intel_de.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_dp_tunnel.c
>> b/drivers/gpu/drm/i915/display/intel_dp_tunnel.c
>> index 94198bc04939..589872babdd7 100644
>> --- a/drivers/gpu/drm/i915/display/intel_dp_tunnel.c
>> +++ b/drivers/gpu/drm/i915/display/intel_dp_tunnel.c
>> @@ -3,11 +3,10 @@
>>   * Copyright © 2023 Intel Corporation
>>   */
>>
>> -#include "i915_drv.h"
>> -
>>  #include <drm/display/drm_dp_tunnel.h>
>>
>>  #include "intel_atomic.h"
>> +#include "intel_display_core.h"
>>  #include "intel_display_limits.h"
>>  #include "intel_display_types.h"
>>  #include "intel_dp.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_hti.c
>> b/drivers/gpu/drm/i915/display/intel_hti.c
>> index 19d1f196d9fb..fb6b84f6a81d 100644
>> --- a/drivers/gpu/drm/i915/display/intel_hti.c
>> +++ b/drivers/gpu/drm/i915/display/intel_hti.c
>> @@ -3,7 +3,8 @@
>>   * Copyright © 2022 Intel Corporation
>>   */
>>
>> -#include "i915_drv.h"
>> +#include <drm/drm_device.h>
>> +
>>  #include "intel_de.h"
>>  #include "intel_display.h"
>>  #include "intel_hti.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_link_bw.c
>> b/drivers/gpu/drm/i915/display/intel_link_bw.c
>> index c87cd1d16d0a..29705c159119 100644
>> --- a/drivers/gpu/drm/i915/display/intel_link_bw.c
>> +++ b/drivers/gpu/drm/i915/display/intel_link_bw.c
>> @@ -5,10 +5,9 @@
>>
>>  #include <drm/drm_fixed.h>
>>
>> -#include "i915_drv.h"
>> -
>>  #include "intel_atomic.h"
>>  #include "intel_crtc.h"
>> +#include "intel_display_core.h"
>>  #include "intel_display_types.h"
>>  #include "intel_dp_mst.h"
>>  #include "intel_dp_tunnel.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_load_detect.c
>> b/drivers/gpu/drm/i915/display/intel_load_detect.c
>> index b457c69dc0be..86cc03a4413c 100644
>> --- a/drivers/gpu/drm/i915/display/intel_load_detect.c
>> +++ b/drivers/gpu/drm/i915/display/intel_load_detect.c
>> @@ -7,9 +7,9 @@
>>  #include <drm/drm_atomic_helper.h>
>>  #include <drm/drm_atomic_uapi.h>
>>
>> -#include "i915_drv.h"
>>  #include "intel_atomic.h"
>>  #include "intel_crtc.h"
>> +#include "intel_display_core.h"
>>  #include "intel_display_types.h"
>>  #include "intel_load_detect.h"
>>
>> diff --git a/drivers/gpu/drm/i915/display/intel_lspcon.c
>> b/drivers/gpu/drm/i915/display/intel_lspcon.c
>> index 16a7d888f1ee..d75dd17fad32 100644
>> --- a/drivers/gpu/drm/i915/display/intel_lspcon.c
>> +++ b/drivers/gpu/drm/i915/display/intel_lspcon.c
>> @@ -28,13 +28,13 @@
>>  #include <drm/drm_atomic_helper.h>
>>  #include <drm/drm_edid.h>
>>
>> -#include "i915_drv.h"
>>  #include "i915_reg.h"
>> +#include "i915_utils.h"
>>  #include "intel_de.h"
>>  #include "intel_display_types.h"
>>  #include "intel_dp.h"
>> -#include "intel_lspcon.h"
>>  #include "intel_hdmi.h"
>> +#include "intel_lspcon.h"
>>
>>  /* LSPCON OUI Vendor ID(signatures) */
>>  #define LSPCON_VENDOR_PARADE_OUI 0x001CF8 diff --git
>> a/drivers/gpu/drm/i915/display/intel_panel.c
>> b/drivers/gpu/drm/i915/display/intel_panel.c
>> index 8aa93c2bf801..4e6c5592c7ae 100644
>> --- a/drivers/gpu/drm/i915/display/intel_panel.c
>> +++ b/drivers/gpu/drm/i915/display/intel_panel.c
>> @@ -33,7 +33,6 @@
>>
>>  #include <drm/drm_edid.h>
>>
>> -#include "i915_drv.h"
>>  #include "intel_backlight.h"
>>  #include "intel_connector.h"
>>  #include "intel_display_core.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_pfit.c
>> b/drivers/gpu/drm/i915/display/intel_pfit.c
>> index 50861aa78a89..4ee03d9d14ad 100644
>> --- a/drivers/gpu/drm/i915/display/intel_pfit.c
>> +++ b/drivers/gpu/drm/i915/display/intel_pfit.c
>> @@ -3,8 +3,8 @@
>>   * Copyright © 2024 Intel Corporation
>>   */
>>
>> -#include "i915_drv.h"
>>  #include "i915_reg.h"
>> +#include "i915_utils.h"
>>  #include "intel_display_core.h"
>>  #include "intel_display_driver.h"
>>  #include "intel_display_types.h"
>> diff --git a/drivers/gpu/drm/i915/display/intel_quirks.c
>> b/drivers/gpu/drm/i915/display/intel_quirks.c
>> index 28f497ae785b..8b30e9fd936e 100644
>> --- a/drivers/gpu/drm/i915/display/intel_quirks.c
>> +++ b/drivers/gpu/drm/i915/display/intel_quirks.c
>> @@ -5,7 +5,7 @@
>>
>>  #include <linux/dmi.h>
>>
>> -#include "i915_drv.h"
>> +#include "intel_display_core.h"
>>  #include "intel_display_types.h"
>>  #include "intel_quirks.h"
>>
>> diff --git a/drivers/gpu/drm/i915/display/intel_vrr.c
>> b/drivers/gpu/drm/i915/display/intel_vrr.c
>> index b386e62d1664..70088e355055 100644
>> --- a/drivers/gpu/drm/i915/display/intel_vrr.c
>> +++ b/drivers/gpu/drm/i915/display/intel_vrr.c
>> @@ -4,7 +4,6 @@
>>   *
>>   */
>>
>> -#include "i915_drv.h"
>>  #include "i915_reg.h"
>>  #include "intel_de.h"
>>  #include "intel_display_types.h"
>> --
>> 2.39.5
>

-- 
Jani Nikula, Intel

  reply	other threads:[~2024-12-18 13:06 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-17 13:21 [PATCH v2] drm/i915/display: drop unnecessary i915_drv.h includes Jani Nikula
2024-12-17 18:40 ` ✓ CI.Patch_applied: success for drm/i915/display: drop unnecessary i915_drv.h includes (rev2) Patchwork
2024-12-17 18:40 ` ✓ CI.checkpatch: " Patchwork
2024-12-17 18:41 ` ✓ CI.KUnit: " Patchwork
2024-12-17 18:59 ` ✓ CI.Build: " Patchwork
2024-12-17 19:02 ` ✓ CI.Hooks: " Patchwork
2024-12-17 19:03 ` ✓ CI.checksparse: " Patchwork
2024-12-17 19:40 ` ✓ Xe.CI.BAT: " Patchwork
2024-12-18  4:03 ` [PATCH v2] drm/i915/display: drop unnecessary i915_drv.h includes Kandpal, Suraj
2024-12-18 13:05   ` Jani Nikula [this message]
2024-12-18  4:30 ` ✗ Xe.CI.Full: failure for drm/i915/display: drop unnecessary i915_drv.h includes (rev2) Patchwork
2024-12-18  7:43 ` ✓ i915.CI.BAT: success " Patchwork
2024-12-18 10:40 ` ✗ 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=87cyhpqgyh.fsf@intel.com \
    --to=jani.nikula@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=suraj.kandpal@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.