From: Jani Nikula Date: Mon, 22 Dec 2025 12:34:02 +0000 (+0200) Subject: drm/xe/compat: convert uncore macro to static inlines X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=80d3db9b62d2740b7cd1a10228ec04f6d61f1bae;p=thirdparty%2Fkernel%2Flinux.git drm/xe/compat: convert uncore macro to static inlines Use static inline instead of macro for intel_uncore_arm_unclaimed_mmio_detection() to avoid the need for __maybe_unused annotations. v2: Rebase, intel_uncore_arm_unclaimed_mmio_detection() Cc: Ville Syrjala Reviewed-by: Ville Syrjälä # v1 Reviewed-by: Michał Grzelak Link: https://patch.msgid.link/7ddee71952315e70e4a7df23638100b664e293bd.1766406794.git.jani.nikula@intel.com Signed-off-by: Jani Nikula --- diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c index 1e3c5761fc5e..c7f4d5e3b4d1 100644 --- a/drivers/gpu/drm/i915/display/intel_display.c +++ b/drivers/gpu/drm/i915/display/intel_display.c @@ -7381,7 +7381,7 @@ static void intel_atomic_dsb_finish(struct intel_atomic_state *state, static void intel_atomic_commit_tail(struct intel_atomic_state *state) { struct intel_display *display = to_intel_display(state); - struct drm_i915_private __maybe_unused *dev_priv = to_i915(display->drm); + struct drm_i915_private *dev_priv = to_i915(display->drm); struct intel_crtc_state *new_crtc_state, *old_crtc_state; struct intel_crtc *crtc; struct intel_power_domain_mask put_domains[I915_MAX_PIPES] = {}; diff --git a/drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h b/drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h index 0d60a0bf2e4b..c05d4c4292d3 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h @@ -152,6 +152,10 @@ static inline void intel_uncore_write_notrace(struct intel_uncore *uncore, xe_mmio_write32(__compat_uncore_to_mmio(uncore), reg, val); } -#define intel_uncore_arm_unclaimed_mmio_detection(x) do { } while (0) +static inline bool +intel_uncore_arm_unclaimed_mmio_detection(struct intel_uncore *uncore) +{ + return false; +} #endif /* __INTEL_UNCORE_H__ */