drm/i915/de: Simplify intel_de_read8()

intel_de_read8() is only needed for VGA register MMIO access
by the CRT code on gen2/3. Remove the redundant wakelock stuff,
and add a platform check to make sure this won't get used on
any platform where MMIO VGA register accesses don't work.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patch.msgid.link/20251208182637.334-11-ville.syrjala@linux.intel.com
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
Ville Syrjälä
2025-12-08 20:26:28 +02:00
parent 7e47a14b02
commit d2bfe35f84

View File

@@ -6,6 +6,8 @@
#ifndef __INTEL_DE_H__
#define __INTEL_DE_H__
#include <drm/drm_print.h>
#include "intel_display_core.h"
#include "intel_dmc_wl.h"
#include "intel_dsb.h"
@@ -34,15 +36,10 @@ intel_de_read(struct intel_display *display, i915_reg_t reg)
static inline u8
intel_de_read8(struct intel_display *display, i915_reg_t reg)
{
u8 val;
/* this is only used on VGA registers (possible on pre-g4x) */
drm_WARN_ON(display->drm, DISPLAY_VER(display) >= 5 || display->platform.g4x);
intel_dmc_wl_get(display, reg);
val = intel_uncore_read8(__to_uncore(display), reg);
intel_dmc_wl_put(display, reg);
return val;
return intel_uncore_read8(__to_uncore(display), reg);
}
static inline u64