mirror of
https://github.com/torvalds/linux.git
synced 2026-05-26 16:12:59 +02:00
drm/i915/display: switch to display->platform.dgfx from IS_DGFX()
Prefer display->platform.dgfx based platform detection over the old IS_DGFX() macro. Reviewed-by: Chaitanya Kumar Borah <chaitanya.kumar.borah@intel.com> Link: https://lore.kernel.org/r/99de7f8f26156afbddcdac850088e6a96d322c55.1744222449.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
parent
4a3506d174
commit
69cb72d393
|
|
@ -3126,7 +3126,7 @@ static const struct vbt_header *intel_bios_get_vbt(struct intel_display *display
|
|||
* If the OpRegion does not have VBT, look in SPI flash
|
||||
* through MMIO or PCI mapping
|
||||
*/
|
||||
if (!vbt && IS_DGFX(i915))
|
||||
if (!vbt && display->platform.dgfx)
|
||||
with_intel_display_rpm(display)
|
||||
vbt = oprom_get_vbt(display, intel_rom_spi(i915), sizep, "SPI flash");
|
||||
|
||||
|
|
|
|||
|
|
@ -560,11 +560,11 @@ static bool plane_has_modifier(struct intel_display *display,
|
|||
return false;
|
||||
|
||||
if (md->modifier == I915_FORMAT_MOD_4_TILED_BMG_CCS &&
|
||||
(GRAPHICS_VER(i915) < 20 || !IS_DGFX(i915)))
|
||||
(GRAPHICS_VER(i915) < 20 || !display->platform.dgfx))
|
||||
return false;
|
||||
|
||||
if (md->modifier == I915_FORMAT_MOD_4_TILED_LNL_CCS &&
|
||||
(GRAPHICS_VER(i915) < 20 || IS_DGFX(i915)))
|
||||
(GRAPHICS_VER(i915) < 20 || display->platform.dgfx))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -53,9 +53,11 @@ intel_reuse_initial_plane_obj(struct intel_crtc *this,
|
|||
}
|
||||
|
||||
static enum intel_memory_type
|
||||
initial_plane_memory_type(struct drm_i915_private *i915)
|
||||
initial_plane_memory_type(struct intel_display *display)
|
||||
{
|
||||
if (IS_DGFX(i915))
|
||||
struct drm_i915_private *i915 = to_i915(display->drm);
|
||||
|
||||
if (display->platform.dgfx)
|
||||
return INTEL_MEMORY_LOCAL;
|
||||
else if (HAS_LMEMBAR_SMEM_STOLEN(i915))
|
||||
return INTEL_MEMORY_STOLEN_LOCAL;
|
||||
|
|
@ -75,7 +77,7 @@ initial_plane_phys(struct intel_display *display,
|
|||
dma_addr_t dma_addr;
|
||||
u32 base;
|
||||
|
||||
mem_type = initial_plane_memory_type(i915);
|
||||
mem_type = initial_plane_memory_type(display);
|
||||
mem = intel_memory_region_by_type(i915, mem_type);
|
||||
if (!mem) {
|
||||
drm_dbg_kms(display->drm,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user