Re: [PATCH 2/3] drm/xe: Don't rely on indirect includes from xe_mmio.h

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

 



Hi Michal,

On Mon, May 20, 2024 at 08:18:13PM +0200, Michal Wajdeczko wrote:
> These compilation units use udelay() or some GT oriented printk
> functions without explicitly including proper header files, and
> relying on #includes from the xe_mmio.h instead. Fix that.
> 
> Signed-off-by: Michal Wajdeczko <michal.wajdeczko@xxxxxxxxx>
> ---
>  drivers/gpu/drm/xe/xe_device.c         | 2 ++
>  drivers/gpu/drm/xe/xe_gsc.c            | 2 ++
>  drivers/gpu/drm/xe/xe_gt_ccs_mode.c    | 1 +
>  drivers/gpu/drm/xe/xe_guc_ads.c        | 1 +
>  drivers/gpu/drm/xe/xe_huc.c            | 2 ++
>  drivers/gpu/drm/xe/xe_mocs.c           | 1 +
>  drivers/gpu/drm/xe/xe_ttm_stolen_mgr.c | 1 +
>  drivers/gpu/drm/xe/xe_uc_fw.c          | 1 +
>  8 files changed, 11 insertions(+)
> 
> diff --git a/drivers/gpu/drm/xe/xe_device.c b/drivers/gpu/drm/xe/xe_device.c
> index 8da90934c900..28a4e0c3b1fe 100644
> --- a/drivers/gpu/drm/xe/xe_device.c
> +++ b/drivers/gpu/drm/xe/xe_device.c
> @@ -5,6 +5,7 @@
>  
>  #include "xe_device.h"
>  
> +#include <linux/delay.h>
>  #include <linux/units.h>
>  
>  #include <drm/drm_aperture.h>
> @@ -33,6 +34,7 @@
>  #include "xe_gsc_proxy.h"
>  #include "xe_gt.h"
>  #include "xe_gt_mcr.h"
> +#include "xe_gt_printk.h"

It is obvious in the occurrences of this include in other compilation
units below, but in xe_device.c I am not seeing the need for
xe_gt_printk.h, am I missing something?

Francois

>  #include "xe_hwmon.h"
>  #include "xe_irq.h"
>  #include "xe_memirq.h"
> diff --git a/drivers/gpu/drm/xe/xe_gsc.c b/drivers/gpu/drm/xe/xe_gsc.c
> index 8cc6420a9e7f..80a61934decc 100644
> --- a/drivers/gpu/drm/xe/xe_gsc.c
> +++ b/drivers/gpu/drm/xe/xe_gsc.c
> @@ -5,6 +5,8 @@
>  
>  #include "xe_gsc.h"
>  
> +#include <linux/delay.h>
> +
>  #include <drm/drm_managed.h>
>  
>  #include <generated/xe_wa_oob.h>
> diff --git a/drivers/gpu/drm/xe/xe_gt_ccs_mode.c b/drivers/gpu/drm/xe/xe_gt_ccs_mode.c
> index a34c9a24dafc..f90cf679c5d7 100644
> --- a/drivers/gpu/drm/xe/xe_gt_ccs_mode.c
> +++ b/drivers/gpu/drm/xe/xe_gt_ccs_mode.c
> @@ -9,6 +9,7 @@
>  #include "xe_assert.h"
>  #include "xe_gt.h"
>  #include "xe_gt_ccs_mode.h"
> +#include "xe_gt_printk.h"
>  #include "xe_gt_sysfs.h"
>  #include "xe_mmio.h"
>  
> diff --git a/drivers/gpu/drm/xe/xe_guc_ads.c b/drivers/gpu/drm/xe/xe_guc_ads.c
> index 9c33cca4e370..1c60b685dbc6 100644
> --- a/drivers/gpu/drm/xe/xe_guc_ads.c
> +++ b/drivers/gpu/drm/xe/xe_guc_ads.c
> @@ -16,6 +16,7 @@
>  #include "xe_bo.h"
>  #include "xe_gt.h"
>  #include "xe_gt_ccs_mode.h"
> +#include "xe_gt_printk.h"
>  #include "xe_guc.h"
>  #include "xe_guc_ct.h"
>  #include "xe_hw_engine.h"
> diff --git a/drivers/gpu/drm/xe/xe_huc.c b/drivers/gpu/drm/xe/xe_huc.c
> index 39a484a57585..b039ff49341b 100644
> --- a/drivers/gpu/drm/xe/xe_huc.c
> +++ b/drivers/gpu/drm/xe/xe_huc.c
> @@ -5,6 +5,8 @@
>  
>  #include "xe_huc.h"
>  
> +#include <linux/delay.h>
> +
>  #include <drm/drm_managed.h>
>  
>  #include "abi/gsc_pxp_commands_abi.h"
> diff --git a/drivers/gpu/drm/xe/xe_mocs.c b/drivers/gpu/drm/xe/xe_mocs.c
> index f04754ad911b..de3f2d3f1b04 100644
> --- a/drivers/gpu/drm/xe/xe_mocs.c
> +++ b/drivers/gpu/drm/xe/xe_mocs.c
> @@ -12,6 +12,7 @@
>  #include "xe_force_wake.h"
>  #include "xe_gt.h"
>  #include "xe_gt_mcr.h"
> +#include "xe_gt_printk.h"
>  #include "xe_mmio.h"
>  #include "xe_platform_types.h"
>  #include "xe_pm.h"
> diff --git a/drivers/gpu/drm/xe/xe_ttm_stolen_mgr.c b/drivers/gpu/drm/xe/xe_ttm_stolen_mgr.c
> index f77367329760..64592a8e527b 100644
> --- a/drivers/gpu/drm/xe/xe_ttm_stolen_mgr.c
> +++ b/drivers/gpu/drm/xe/xe_ttm_stolen_mgr.c
> @@ -18,6 +18,7 @@
>  #include "xe_bo.h"
>  #include "xe_device.h"
>  #include "xe_gt.h"
> +#include "xe_gt_printk.h"
>  #include "xe_mmio.h"
>  #include "xe_res_cursor.h"
>  #include "xe_sriov.h"
> diff --git a/drivers/gpu/drm/xe/xe_uc_fw.c b/drivers/gpu/drm/xe/xe_uc_fw.c
> index ed819f1df888..12346645a8e5 100644
> --- a/drivers/gpu/drm/xe/xe_uc_fw.c
> +++ b/drivers/gpu/drm/xe/xe_uc_fw.c
> @@ -14,6 +14,7 @@
>  #include "xe_force_wake.h"
>  #include "xe_gsc.h"
>  #include "xe_gt.h"
> +#include "xe_gt_printk.h"
>  #include "xe_map.h"
>  #include "xe_mmio.h"
>  #include "xe_module.h"
> -- 
> 2.43.0
> 



[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux