Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/xe/fbdev: Limit the usage of stolen for LNL+
@ 2024-07-11  5:13 Uma Shankar
  2024-07-11  5:11 ` ✓ CI.Patch_applied: success for " Patchwork
                   ` (9 more replies)
  0 siblings, 10 replies; 16+ messages in thread
From: Uma Shankar @ 2024-07-11  5:13 UTC (permalink / raw)
  To: intel-gfx, intel-xe
  Cc: ville.syrjala, daniele.ceraolospurio, vinay.belgaumkar,
	Uma Shankar

As per recommendation in the workarounds:
WA_14021987551, Wa_16023588340:

There is an issue with accessing Stolen memory pages due a
hardware limitation. Limit the usage of stolen memory for
fbdev for LNL+. Don't use BIOS FB from stolen on LNL+ and
assign the same from system memory.

Signed-off-by: Uma Shankar <uma.shankar@intel.com>
---
 drivers/gpu/drm/xe/display/intel_fbdev_fb.c   | 10 +++++++++-
 drivers/gpu/drm/xe/display/xe_plane_initial.c | 10 ++++++++++
 2 files changed, 19 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/xe/display/intel_fbdev_fb.c b/drivers/gpu/drm/xe/display/intel_fbdev_fb.c
index 816ad13821a8..8fda8745ce0a 100644
--- a/drivers/gpu/drm/xe/display/intel_fbdev_fb.c
+++ b/drivers/gpu/drm/xe/display/intel_fbdev_fb.c
@@ -37,7 +37,14 @@ struct intel_framebuffer *intel_fbdev_fb_alloc(struct drm_fb_helper *helper,
 	size = PAGE_ALIGN(size);
 	obj = ERR_PTR(-ENODEV);
 
-	if (!IS_DGFX(xe)) {
+	/*
+	 * WA_14021987551, Wa_16023588340:
+	 * There is an issue with accessing Stolen memory pages
+	 * due a hardware limitation. Limit the usage of stolen
+	 * memory for fbdev for LNL+. Don't use BIOS FB from
+	 * stolen on LNL+ and assign the same from system memory
+	 */
+	if (!IS_DGFX(xe) && (DISPLAY_VER(xe) < 20)) {
 		obj = xe_bo_create_pin_map(xe, xe_device_get_root_tile(xe),
 					   NULL, size,
 					   ttm_bo_type_kernel, XE_BO_FLAG_SCANOUT |
@@ -48,6 +55,7 @@ struct intel_framebuffer *intel_fbdev_fb_alloc(struct drm_fb_helper *helper,
 		else
 			drm_info(&xe->drm, "Allocated fbdev into stolen failed: %li\n", PTR_ERR(obj));
 	}
+
 	if (IS_ERR(obj)) {
 		obj = xe_bo_create_pin_map(xe, xe_device_get_root_tile(xe), NULL, size,
 					   ttm_bo_type_kernel, XE_BO_FLAG_SCANOUT |
diff --git a/drivers/gpu/drm/xe/display/xe_plane_initial.c b/drivers/gpu/drm/xe/display/xe_plane_initial.c
index 5eccd6abb3ef..80dd6b64c921 100644
--- a/drivers/gpu/drm/xe/display/xe_plane_initial.c
+++ b/drivers/gpu/drm/xe/display/xe_plane_initial.c
@@ -104,6 +104,16 @@ initial_plane_bo(struct xe_device *xe,
 		phys_base = base;
 		flags |= XE_BO_FLAG_STOLEN;
 
+		/*
+		 * WA_14021987551, Wa_16023588340:
+		 * There is an issue with accessing Stolen memory pages
+		 * due a hardware limitation. Limit the usage of stolen
+		 * memory for fbdev for LNL+. Don't use BIOS FB from
+		 * stolen on LNL+ and assign the same from system memory
+		 */
+		if (DISPLAY_VER(xe) >= 20)
+			return NULL;
+
 		/*
 		 * If the FB is too big, just don't use it since fbdev is not very
 		 * important and we should probably use that space with FBC or other
-- 
2.42.0


^ permalink raw reply related	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2024-07-14 19:50 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-11  5:13 [PATCH] drm/xe/fbdev: Limit the usage of stolen for LNL+ Uma Shankar
2024-07-11  5:11 ` ✓ CI.Patch_applied: success for " Patchwork
2024-07-11  5:11 ` ✓ CI.checkpatch: " Patchwork
2024-07-11  5:12 ` ✓ CI.KUnit: " Patchwork
2024-07-11  5:24 ` ✓ CI.Build: " Patchwork
2024-07-11  5:26 ` ✓ CI.Hooks: " Patchwork
2024-07-11  5:28 ` ✓ CI.checksparse: " Patchwork
2024-07-11  5:52 ` ✓ CI.BAT: " Patchwork
2024-07-11  6:52 ` ✗ CI.FULL: failure " Patchwork
2024-07-11 16:31 ` [PATCH] " Lucas De Marchi
2024-07-11 17:38   ` Ville Syrjälä
2024-07-14 19:41   ` Shankar, Uma
2024-07-11 16:37 ` Matt Roper
2024-07-11 17:06   ` Lucas De Marchi
2024-07-14 19:49     ` Shankar, Uma
2024-07-14 19:46   ` Shankar, Uma

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox