From: Michal Wajdeczko Date: Tue, 3 Feb 2026 21:12:36 +0000 (+0100) Subject: drm/xe: Move xe_root_tile_mmio() to xe_device.h X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8965e00883cc4d66749e1aa89322588c860077cd;p=thirdparty%2Flinux.git drm/xe: Move xe_root_tile_mmio() to xe_device.h It seems to be a better place for this helper function, where we already have other 'root' oriented helpers. Signed-off-by: Michal Wajdeczko Reviewed-by: Stuart Summers Reviewed-by: Matt Roper Link: https://patch.msgid.link/20260203211240.745-2-michal.wajdeczko@intel.com --- diff --git a/drivers/gpu/drm/xe/xe_device.h b/drivers/gpu/drm/xe/xe_device.h index 58d7d8b2fea39..39464650533b5 100644 --- a/drivers/gpu/drm/xe/xe_device.h +++ b/drivers/gpu/drm/xe/xe_device.h @@ -109,6 +109,11 @@ static inline struct xe_gt *xe_root_mmio_gt(struct xe_device *xe) return xe_device_get_root_tile(xe)->primary_gt; } +static inline struct xe_mmio *xe_root_tile_mmio(struct xe_device *xe) +{ + return &xe->tiles[0].mmio; +} + static inline bool xe_device_uc_enabled(struct xe_device *xe) { return !xe->info.force_execlist; diff --git a/drivers/gpu/drm/xe/xe_i2c.c b/drivers/gpu/drm/xe/xe_i2c.c index 1e1fb72e49bf2..1deb812fe01dc 100644 --- a/drivers/gpu/drm/xe/xe_i2c.c +++ b/drivers/gpu/drm/xe/xe_i2c.c @@ -27,7 +27,7 @@ #include "regs/xe_i2c_regs.h" #include "regs/xe_irq_regs.h" -#include "xe_device_types.h" +#include "xe_device.h" #include "xe_i2c.h" #include "xe_mmio.h" #include "xe_sriov.h" diff --git a/drivers/gpu/drm/xe/xe_mmio.h b/drivers/gpu/drm/xe/xe_mmio.h index 15362789ab994..6a8faebb2c298 100644 --- a/drivers/gpu/drm/xe/xe_mmio.h +++ b/drivers/gpu/drm/xe/xe_mmio.h @@ -37,11 +37,6 @@ static inline u32 xe_mmio_adjusted_addr(const struct xe_mmio *mmio, u32 addr) return addr; } -static inline struct xe_mmio *xe_root_tile_mmio(struct xe_device *xe) -{ - return &xe->tiles[0].mmio; -} - #ifdef CONFIG_PCI_IOV void xe_mmio_init_vf_view(struct xe_mmio *mmio, const struct xe_mmio *base, unsigned int vfid); #endif diff --git a/drivers/gpu/drm/xe/xe_nvm.c b/drivers/gpu/drm/xe/xe_nvm.c index bc88804de5146..1fdfb690ea3d3 100644 --- a/drivers/gpu/drm/xe/xe_nvm.c +++ b/drivers/gpu/drm/xe/xe_nvm.c @@ -6,7 +6,7 @@ #include #include -#include "xe_device_types.h" +#include "xe_device.h" #include "xe_mmio.h" #include "xe_nvm.h" #include "xe_pcode_api.h" diff --git a/drivers/gpu/drm/xe/xe_soc_remapper.c b/drivers/gpu/drm/xe/xe_soc_remapper.c index 1c391d7191966..c031336a6d753 100644 --- a/drivers/gpu/drm/xe/xe_soc_remapper.c +++ b/drivers/gpu/drm/xe/xe_soc_remapper.c @@ -4,6 +4,7 @@ */ #include "regs/xe_soc_remapper_regs.h" +#include "xe_device.h" #include "xe_mmio.h" #include "xe_soc_remapper.h"