Commit 9d293478 authored by Ville Syrjälä's avatar Ville Syrjälä
Browse files

drm/i915: Use intel_memory_region_type_is_local() in the BIOS FB takeover



Replace the hardcoded PTE vs. memory region is_local checks
in the BIOS FB takeover with intel_memory_region_type_is_local().

Signed-off-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250313140838.29742-10-ville.syrjala@linux.intel.com


Reviewed-by: default avatarJouni Högander <jouni.hogander@intel.com>
parent a47720c5
Loading
Loading
Loading
Loading
+6 −4
Original line number Diff line number Diff line
@@ -94,9 +94,10 @@ initial_plane_phys_lmem(struct intel_display *display,
		return false;
	}

	if (!is_local) {
	if (intel_memory_type_is_local(mem->type) != is_local) {
		drm_err(display->drm,
			"Initial plane FB PTE not LMEM\n");
			"Initial plane FB PTE unsuitable for %s\n",
			mem->region.name);
		return false;
	}

@@ -152,9 +153,10 @@ initial_plane_phys_smem(struct intel_display *display,
		return false;
	}

	if (is_local) {
	if (intel_memory_type_is_local(mem->type) != is_local) {
		drm_err(display->drm,
			"Initial plane FB PTE LMEM\n");
			"Initial plane FB PTE unsuitable for %s\n",
			mem->region.name);
		return false;
	}