* [PATCH 1/3] drm/amdgpu: reserve 64M stolen memory for Apple 5K iMac
@ 2026-10-26 22:46 Richard Lane
0 siblings, 0 replies; only message in thread
From: Richard Lane @ 2026-10-26 22:46 UTC (permalink / raw)
To: amd-gfx
Cc: Alex Deucher, Christian König, Harry Wentland, Leo Li,
Rodrigo Siqueira, Mario Limonciello, David Airlie, Simona Vetter,
Richard Lane, dri-devel, linux-kernel
Apple 27" 5K iMacs report a single 2560x2880 tile (28.125 MiB) in
VIEWPORT_SIZE while scanning out up to 64 MiB across the relocated EFI
framebuffer.
Override the stolen VGA memory allocation size to 64 MiB when matching
PCI_VENDOR_ID_APPLE with a 2560x2880x4 viewport size to prevent
framebuffer corruption during boot handover.
Signed-off-by: Richard Lane <richardlanedev@gmail.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
index 4204c3c750a8..8b196fbfa724 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
@@ -1232,7 +1232,15 @@ void amdgpu_gmc_init_vga_resv_regions(struct amdgpu_device *adev)
} else {
size = amdgpu_gmc_get_vbios_fb_size(adev);
- if (adev->mman.keep_stolen_vga_memory)
+ /*
+ * Apple 5K iMacs report one 2560x2880 tile in VIEWPORT_SIZE
+ * while scanning out up to 64M across the relocated EFI
+ * framebuffer.
+ */
+ if (adev->pdev->subsystem_vendor == PCI_VENDOR_ID_APPLE &&
+ size == (2560 * 2880 * 4))
+ size = 64U * 1024 * 1024;
+ else if (adev->mman.keep_stolen_vga_memory)
size = max(size, (unsigned)AMDGPU_VBIOS_VGA_ALLOCATION);
}
--
2.55.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-10-26 22:46 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-26 22:46 [PATCH 1/3] drm/amdgpu: reserve 64M stolen memory for Apple 5K iMac Richard Lane
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®