Skip to contentSkip to conversation

video/efi: Support FIRMWARE_EDID on non-x86

PATCH In review Ard Biesheuvel 3 participants 8 messages Nov 19, 2025 – Nov 21, 2025

Subsystems (7)
lore
Share & tools
lore
#0 lore raw

cover video/efi: Support FIRMWARE_EDID on non-x86

From: Ard Biesheuvel <[email protected]>

Refactor the screen_info handling so non-x86 platforms booting via the EFI stub also have access to the EDID data exposed by the EFI boot services.

Cc Thomas Zimmermann <[email protected]>
Cc Javier Martinez Canillas <[email protected]>

Ard Biesheuvel (3):
efi: Wrap screen_info in efi_screen_info so edid_info can be added
later
video/edid: Use getter function for edid_info
efi: Add FIRMWARE_EDID support

 arch/x86/kernel/setup.c                       |  8 ++++++--
 drivers/firmware/efi/earlycon.c               |  1 -
 drivers/firmware/efi/efi-init.c               | 19 ++++++++++++++-----
 drivers/firmware/efi/libstub/efi-stub-entry.c |  3 +--
 drivers/firmware/efi/libstub/efi-stub.c       | 16 ++++++++++------
 drivers/firmware/efi/libstub/efistub.h        |  9 +++------
 drivers/firmware/efi/libstub/gop.c            |  1 -
 drivers/firmware/efi/libstub/screen_info.c    |  7 +++----
 drivers/firmware/efi/libstub/zboot.c          |  2 +-
 drivers/firmware/efi/sysfb_efi.c              |  1 -
 drivers/gpu/drm/sysfb/efidrm.c                |  4 ++--
 drivers/gpu/drm/sysfb/vesadrm.c               |  4 ++--
 drivers/video/Kconfig                         |  2 +-
 drivers/video/fbdev/core/fbmon.c              |  4 ++--
 include/linux/efi.h                           | 10 +++++++++-
 include/video/edid.h                          |  2 +-
 16 files changed, 55 insertions(+), 38 deletions(-)
Signature · 1 line
2.52.0.rc1.455.g30608eb744-goog
#1 lore raw

PATCH 1/3 efi: Wrap screen_info in efi_screen_info so edid_info can be added later

From: Ard Biesheuvel <[email protected]>

Prepare for adding support to the EFI stub to pass edid_info discovered using EFI boot services to the kernel proper via a EFI configuration table. Instead of passing struct screen_info directly, define a new struct efi_screen_info that encapsulates it. struct edid_info will be added there later.

---
 drivers/firmware/efi/earlycon.c               |  1 -
 drivers/firmware/efi/efi-init.c               | 11 ++++++-----
 drivers/firmware/efi/libstub/efi-stub-entry.c |  3 +--
 drivers/firmware/efi/libstub/efi-stub.c       |  9 ++++-----
 drivers/firmware/efi/libstub/efistub.h        |  6 +++---
 drivers/firmware/efi/libstub/gop.c            |  1 -
 drivers/firmware/efi/libstub/screen_info.c    |  7 +++----
 drivers/firmware/efi/libstub/zboot.c          |  2 +-
 drivers/firmware/efi/sysfb_efi.c              |  1 -
 include/linux/efi.h                           |  6 +++++-
 10 files changed, 23 insertions(+), 24 deletions(-)
drivers/firmware/efi/earlycon.c +0 -1
index d18a1a5de144..23fb23867b56 100644
@@ -9,7 +9,6 @@
 #include <linux/io.h>
 #include <linux/kernel.h>
 #include <linux/serial_core.h>
-#include <linux/screen_info.h>
 #include <linux/string.h>
 
 #include <asm/early_ioremap.h>
drivers/firmware/efi/efi-init.c +6 -5
index a65c2d5b9e7b..5896f4e699a1 100644
@@ -19,7 +19,6 @@
 #include <linux/of_address.h>
 #include <linux/of_fdt.h>
 #include <linux/platform_device.h>
-#include <linux/screen_info.h>
 
 #include <asm/efi.h>
 
@@ -61,13 +60,15 @@ extern __weak const efi_config_table_type_t efi_arch_tables[];
  * everything else can get it from here.
  */
 #if !defined(CONFIG_X86) && (defined(CONFIG_SYSFB) || defined(CONFIG_EFI_EARLYCON))
-struct screen_info screen_info __section(".data");
+struct efi_screen_info efi_screen_info __section(".data");
+
+extern struct screen_info screen_info __alias(efi_screen_info);
 EXPORT_SYMBOL_GPL(screen_info);
 #endif
 
 static void __init init_screen_info(void)
 {
-	struct screen_info *si;
+	struct efi_screen_info *si;
 
 	if (screen_info_table != EFI_INVALID_TABLE_ADDR) {
 		si = early_memremap(screen_info_table, sizeof(*si));
@@ -75,8 +76,8 @@ static void __init init_screen_info(void)
 			pr_err("Could not map screen_info config table\n");
 			return;
 		}
-		screen_info = *si;
-		memset(si, 0, sizeof(*si));
+		efi_screen_info = *si;
+		si->screen_info = (struct screen_info){};
 		early_memunmap(si, sizeof(*si));
 
 		if (memblock_is_map_memory(screen_info.lfb_base))
drivers/firmware/efi/libstub/efi-stub-entry.c +1 -2
index a6c049835190..520f5ea31cfd 100644
@@ -1,7 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0-only
 
 #include <linux/efi.h>
-#include <linux/screen_info.h>
 
 #include <asm/efi.h>
 
@@ -9,7 +8,7 @@
 
 static unsigned long screen_info_offset;
 
-struct screen_info *alloc_screen_info(void)
+struct efi_screen_info *alloc_screen_info(void)
 {
 	if (IS_ENABLED(CONFIG_ARM))
 		return __alloc_screen_info();
drivers/firmware/efi/libstub/efi-stub.c +4 -5
index 9cb814c5ba1b..fe77c285a547 100644
@@ -10,7 +10,6 @@
  */
 
 #include <linux/efi.h>
-#include <linux/screen_info.h>
 #include <asm/efi.h>
 
 #include "efistub.h"
@@ -48,13 +47,13 @@
 static u64 virtmap_base = EFI_RT_VIRTUAL_BASE;
 static bool flat_va_mapping = (EFI_RT_VIRTUAL_OFFSET != 0);
 
-void __weak free_screen_info(struct screen_info *si)
+void __weak free_screen_info(struct efi_screen_info *si)
 {
 }
 
-static struct screen_info *setup_graphics(void)
+static struct efi_screen_info *setup_graphics(void)
 {
-	struct screen_info *si, tmp = {};
+	struct efi_screen_info *si, tmp = {};
 
 	if (efi_setup_graphics(&tmp, NULL) != EFI_SUCCESS)
 		return NULL;
@@ -145,7 +144,7 @@ efi_status_t efi_stub_common(efi_handle_t handle,
 			     unsigned long image_addr,
 			     char *cmdline_ptr)
 {
-	struct screen_info *si;
+	struct efi_screen_info *si;
 	efi_status_t status;
 
 	status = check_platform_features();
drivers/firmware/efi/libstub/efistub.h +3 -3
index b2fb0c3fa721..bdeb28d42a1a 100644
@@ -1175,9 +1175,9 @@ efi_enable_reset_attack_mitigation(void) { }
 
 void efi_retrieve_eventlog(void);
 
-struct screen_info *alloc_screen_info(void);
-struct screen_info *__alloc_screen_info(void);
-void free_screen_info(struct screen_info *si);
+struct efi_screen_info *alloc_screen_info(void);
+struct efi_screen_info *__alloc_screen_info(void);
+void free_screen_info(struct efi_screen_info *si);
 
 void efi_cache_sync_image(unsigned long image_base,
 			  unsigned long alloc_size);
drivers/firmware/efi/libstub/gop.c +0 -1
index 72d74436a7a4..db80f2ad2871 100644
@@ -8,7 +8,6 @@
 #include <linux/bitops.h>
 #include <linux/ctype.h>
 #include <linux/efi.h>
-#include <linux/screen_info.h>
 #include <linux/string.h>
 #include <asm/efi.h>
 #include <asm/setup.h>
drivers/firmware/efi/libstub/screen_info.c +3 -4
index 5d3a1e32d177..189da1efb7b2 100644
@@ -1,7 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0
 
 #include <linux/efi.h>
-#include <linux/screen_info.h>
 
 #include <asm/efi.h>
 
@@ -21,9 +20,9 @@
 
 static efi_guid_t screen_info_guid = LINUX_EFI_SCREEN_INFO_TABLE_GUID;
 
-struct screen_info *__alloc_screen_info(void)
+struct efi_screen_info *__alloc_screen_info(void)
 {
-	struct screen_info *si;
+	struct efi_screen_info *si;
 	efi_status_t status;
 
 	status = efi_bs_call(allocate_pool, EFI_ACPI_RECLAIM_MEMORY,
@@ -43,7 +42,7 @@ struct screen_info *__alloc_screen_info(void)
 	return NULL;
 }
 
-void free_screen_info(struct screen_info *si)
+void free_screen_info(struct efi_screen_info *si)
 {
 	if (!si)
 		return;
drivers/firmware/efi/libstub/zboot.c +1 -1
index c47ace06f010..86f4814cfd47 100644
@@ -26,7 +26,7 @@ void __weak efi_cache_sync_image(unsigned long image_base,
 	// executable code loaded into memory to be safe for execution.
 }
 
-struct screen_info *alloc_screen_info(void)
+struct efi_screen_info *alloc_screen_info(void)
 {
 	return __alloc_screen_info();
 }
drivers/firmware/efi/sysfb_efi.c +0 -1
index 1e509595ac03..092c19771e17 100644
@@ -22,7 +22,6 @@
 #include <linux/of_address.h>
 #include <linux/pci.h>
 #include <linux/platform_device.h>
-#include <linux/screen_info.h>
 #include <linux/sysfb.h>
 #include <video/vga.h>
 
include/linux/efi.h +5 -1
index a01f3fe20dab..75d05dc1b4ee 100644
@@ -27,7 +27,7 @@
 
 #include <asm/page.h>
 
-struct screen_info;
+#include <linux/screen_info.h>
 
 #define EFI_SUCCESS		0
 #define EFI_LOAD_ERROR		( 1 | (1UL << (BITS_PER_LONG-1)))
@@ -1361,4 +1361,8 @@ extern struct blocking_notifier_head efivar_ops_nh;
 void efivars_generic_ops_register(void);
 void efivars_generic_ops_unregister(void);
 
+struct efi_screen_info {
+	struct screen_info	screen_info;
+};
+
 #endif /* _LINUX_EFI_H */
Signature · 1 line
2.52.0.rc1.455.g30608eb744-goog
#2 lore raw

PATCH 2/3 video/edid: Use getter function for edid_info

In reply to Ard Biesheuvel

From: Ard Biesheuvel <[email protected]>

Avoid accessing a global writable buffer directly for edid_info, and instead, define a getter function returning a pointer to it. And considering that all callers access only the 'dummy' field, just return a const u8* directly.

This will be used by non-x86 EFI systems that pass edid_info via a EFI configuration table.

---
 arch/x86/kernel/setup.c          | 8 ++++++--
 drivers/gpu/drm/sysfb/efidrm.c   | 4 ++--
 drivers/gpu/drm/sysfb/vesadrm.c  | 4 ++--
 drivers/video/fbdev/core/fbmon.c | 4 ++--
 include/video/edid.h             | 2 +-
 5 files changed, 13 insertions(+), 9 deletions(-)
arch/x86/kernel/setup.c +6 -2
index 1b2edd07a3e1..526c9c4553c1 100644
@@ -214,8 +214,12 @@ arch_initcall(init_x86_sysctl);
 struct screen_info screen_info;
 EXPORT_SYMBOL(screen_info);
 #if defined(CONFIG_FIRMWARE_EDID)
-struct edid_info edid_info;
-EXPORT_SYMBOL_GPL(edid_info);
+static struct edid_info edid_info __ro_after_init;
+const u8 *get_edid_info(void)
+{
+	return edid_info.dummy;
+}
+EXPORT_SYMBOL_GPL(get_edid_info);
 #endif
 
 extern int root_mountflags;
drivers/gpu/drm/sysfb/efidrm.c +2 -2
index 1883c4a8604c..e30b93ed4264 100644
@@ -203,8 +203,8 @@ static struct efidrm_device *efidrm_device_create(struct drm_driver *drv,
 		&format->format, width, height, stride);
 
 #if defined(CONFIG_FIRMWARE_EDID)
-	if (drm_edid_header_is_valid(edid_info.dummy) == 8)
-		sysfb->edid = edid_info.dummy;
+	if (drm_edid_header_is_valid(get_edid_info()) == 8)
+		sysfb->edid = get_edid_info();
 #endif
 	sysfb->fb_mode = drm_sysfb_mode(width, height, 0, 0);
 	sysfb->fb_format = format;
drivers/gpu/drm/sysfb/vesadrm.c +2 -2
index 16a4b52d45c6..a4ff78fddc0c 100644
@@ -469,8 +469,8 @@ static struct vesadrm_device *vesadrm_device_create(struct drm_driver *drv,
 	}
 
 #if defined(CONFIG_FIRMWARE_EDID)
-	if (drm_edid_header_is_valid(edid_info.dummy) == 8)
-		sysfb->edid = edid_info.dummy;
+	if (drm_edid_header_is_valid(get_edid_info()) == 8)
+		sysfb->edid = get_edid_info();
 #endif
 	sysfb->fb_mode = drm_sysfb_mode(width, height, 0, 0);
 	sysfb->fb_format = format;
drivers/video/fbdev/core/fbmon.c +2 -2
index 0a65bef01e3c..caa057c76a88 100644
@@ -1495,7 +1495,7 @@ const unsigned char *fb_firmware_edid(struct device *device)
 {
 	struct pci_dev *dev = NULL;
 	struct resource *res = NULL;
-	unsigned char *edid = NULL;
+	const unsigned char *edid = NULL;
 
 	if (device)
 		dev = to_pci_dev(device);
@@ -1504,7 +1504,7 @@ const unsigned char *fb_firmware_edid(struct device *device)
 		res = &dev->resource[PCI_ROM_RESOURCE];
 
 	if (res && res->flags & IORESOURCE_ROM_SHADOW)
-		edid = edid_info.dummy;
+		edid = get_edid_info();
 
 	return edid;
 }
include/video/edid.h +1 -1
index c2b186b1933a..b8f24c4b2829 100644
@@ -5,7 +5,7 @@
 #include <uapi/video/edid.h>
 
 #if defined(CONFIG_FIRMWARE_EDID)
-extern struct edid_info edid_info;
+const u8 *get_edid_info(void) __attribute_const__;
 #endif
 
 #endif /* __linux_video_edid_h__ */
Signature · 1 line
2.52.0.rc1.455.g30608eb744-goog
#3 lore raw

PATCH 3/3 efi: Add FIRMWARE_EDID support

In reply to Ard Biesheuvel

From: Ard Biesheuvel <[email protected]>

Add support to non-x86 EFI systems for passing the EDID information discovered by the EFI stub to the kernel proper.

---
 drivers/firmware/efi/efi-init.c         | 8 ++++++++
 drivers/firmware/efi/libstub/efi-stub.c | 7 ++++++-
 drivers/firmware/efi/libstub/efistub.h  | 3 ---
 drivers/video/Kconfig                   | 2 +-
 include/linux/efi.h                     | 4 ++++
 5 files changed, 19 insertions(+), 5 deletions(-)
drivers/firmware/efi/efi-init.c +8 -0
index 5896f4e699a1..d70bd0ec154f 100644
@@ -64,6 +64,14 @@ struct efi_screen_info efi_screen_info __section(".data");
 
 extern struct screen_info screen_info __alias(efi_screen_info);
 EXPORT_SYMBOL_GPL(screen_info);
+
+#ifdef CONFIG_FIRMWARE_EDID
+const u8 *get_edid_info(void)
+{
+       return efi_screen_info.edid_info.dummy;
+}
+EXPORT_SYMBOL_GPL(get_edid_info);
+#endif
 #endif
 
 static void __init init_screen_info(void)
drivers/firmware/efi/libstub/efi-stub.c +6 -1
index fe77c285a547..20b606d1cbf0 100644
@@ -54,8 +54,13 @@ void __weak free_screen_info(struct efi_screen_info *si)
 static struct efi_screen_info *setup_graphics(void)
 {
 	struct efi_screen_info *si, tmp = {};
+	struct edid_info *edid_info = NULL;
 
-	if (efi_setup_graphics(&tmp, NULL) != EFI_SUCCESS)
+#ifdef CONFIG_FIRMWARE_EDID
+	edid_info = &tmp.edid_info;
+#endif
+
+	if (efi_setup_graphics(&tmp.screen_info, edid_info) != EFI_SUCCESS)
 		return NULL;
 
 	si = alloc_screen_info();
drivers/firmware/efi/libstub/efistub.h +0 -3
index bdeb28d42a1a..93940592e88e 100644
@@ -34,9 +34,6 @@
 #define EFI_ALLOC_LIMIT		ULONG_MAX
 #endif
 
-struct edid_info;
-struct screen_info;
-
 extern bool efi_no5lvl;
 extern bool efi_nochunk;
 extern bool efi_nokaslr;
drivers/video/Kconfig +1 -1
index d51777df12d1..6526827fbc55 100644
@@ -63,7 +63,7 @@ endif # HAS_IOMEM
 
 config FIRMWARE_EDID
 	bool "Enable firmware EDID"
-	depends on X86
+	depends on X86 || EFI_GENERIC_STUB
 	help
 	  This enables access to the EDID transferred from the firmware.
 	  On x86, this is from the VESA BIOS. DRM display drivers will
include/linux/efi.h +4 -0
index 75d05dc1b4ee..8d8228d73585 100644
@@ -28,6 +28,7 @@
 #include <asm/page.h>
 
 #include <linux/screen_info.h>
+#include <video/edid.h>
 
 #define EFI_SUCCESS		0
 #define EFI_LOAD_ERROR		( 1 | (1UL << (BITS_PER_LONG-1)))
@@ -1363,6 +1364,9 @@ void efivars_generic_ops_unregister(void);
 
 struct efi_screen_info {
 	struct screen_info	screen_info;
+#ifdef CONFIG_FIRMWARE_EDID
+	struct edid_info	edid_info;
+#endif
 };
 
 #endif /* _LINUX_EFI_H */
Signature · 1 line
2.52.0.rc1.455.g30608eb744-goog
#4 lore raw
In reply to Ard Biesheuvel

Hi,

thanks for addressing the remaining EDID support.

First of all, you need to cc [email protected]  on any further revisions.

Am 19.11.25 um 13:30 schrieb Ard Biesheuvel:

Quoted 5 lines

From: Ard Biesheuvel <[email protected]>

Refactor the screen_info handling so non-x86 platforms booting via the EFI stub also have access to the EDID data exposed by the EFI boot services.

I don't like how this series complicates everything to make non-x86 easier. But the general idea of using efi_screen_info goes into the right direction. It's just not generic enough.

The sysfb code transfers struct screen_info as device parameter [1]. Drivers later fetch it on probe [2].  The direct ref to the global edid_info [3] only exists because we have no means of transferring it as device data.

So instead of using efi_screen_info, let's declare struct sysfb_display with screen_info and edid_info.  The header would be linux/sysfb.h.  We transfer this to all related drivers.  The generic EFI code would set it up like efi_screen_info and the x86 code would decalre it at [4]; replacing the existing state.

Best regards
Thomas

[1] https://elixir.bootlin.com/linux/v6.17.8/source/drivers/firmware/sysfb.c#L205
[2] https://elixir.bootlin.com/linux/v6.17.8/source/drivers/gpu/drm/sysfb/efidrm.c#L162
[3] https://elixir.bootlin.com/linux/v6.17.8/source/drivers/gpu/drm/sysfb/efidrm.c#L206
[4] https://elixir.bootlin.com/linux/v6.17.8/source/arch/x86/kernel/setup.c#L214

Quoted 28 lines
Cc Thomas Zimmermann <[email protected]>
Cc Javier Martinez Canillas <[email protected]>

Ard Biesheuvel (3):
efi: Wrap screen_info in efi_screen_info so edid_info can be added
later
video/edid: Use getter function for edid_info
efi: Add FIRMWARE_EDID support

  arch/x86/kernel/setup.c                       |  8 ++++++--
  drivers/firmware/efi/earlycon.c               |  1 -
  drivers/firmware/efi/efi-init.c               | 19 ++++++++++++++-----
  drivers/firmware/efi/libstub/efi-stub-entry.c |  3 +--
  drivers/firmware/efi/libstub/efi-stub.c       | 16 ++++++++++------
  drivers/firmware/efi/libstub/efistub.h        |  9 +++------
  drivers/firmware/efi/libstub/gop.c            |  1 -
  drivers/firmware/efi/libstub/screen_info.c    |  7 +++----
  drivers/firmware/efi/libstub/zboot.c          |  2 +-
  drivers/firmware/efi/sysfb_efi.c              |  1 -
  drivers/gpu/drm/sysfb/efidrm.c                |  4 ++--
  drivers/gpu/drm/sysfb/vesadrm.c               |  4 ++--
  drivers/video/Kconfig                         |  2 +-
  drivers/video/fbdev/core/fbmon.c              |  4 ++--
  include/linux/efi.h                           | 10 +++++++++-
  include/video/edid.h                          |  2 +-
  16 files changed, 55 insertions(+), 38 deletions(-)
Signature · 6 lines
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com
GF: Jochen Jaser, Andrew McDonald, Werner Knoblich, (HRB 36809, AG Nürnberg)
#5 lore raw

Am 20.11.25 um 08:56 schrieb Thomas Zimmermann:

Quoted 13 lines

Hi,

thanks for addressing the remaining EDID support.

First of all, you need to cc [email protected]  on any further revisions.

Am 19.11.25 um 13:30 schrieb Ard Biesheuvel:

Quoted 5 lines

From: Ard Biesheuvel <[email protected]>

Refactor the screen_info handling so non-x86 platforms booting via the EFI stub also have access to the EDID data exposed by the EFI boot services.

Quoted 5 lines

I don't like how this series complicates everything to make non-x86 easier. But the general idea of using efi_screen_info goes into the right direction. It's just not generic enough.

The sysfb code transfers struct screen_info as device parameter [1]. Drivers later fetch it on probe [2].  The direct ref to the global edid_info [3] only exists because we have no means of transferring it as device data.

So instead of using efi_screen_info, let's declare struct sysfb_display with screen_info and edid_info.  The header would be linux/sysfb.h.  We transfer this to all related drivers.  The generic EFI code would set it up like efi_screen_info and the x86 code would decalre it at [4]; replacing the existing state.

If this proposal works for EFI, I could do the changes in graphics drivers and then resubmit the EDID series with an additional patch for generic EFI.

Quoted 39 lines

Best regards
Thomas

[1] https://elixir.bootlin.com/linux/v6.17.8/source/drivers/firmware/sysfb.c#L205
[2] https://elixir.bootlin.com/linux/v6.17.8/source/drivers/gpu/drm/sysfb/efidrm.c#L162
[3] https://elixir.bootlin.com/linux/v6.17.8/source/drivers/gpu/drm/sysfb/efidrm.c#L206
[4] https://elixir.bootlin.com/linux/v6.17.8/source/arch/x86/kernel/setup.c#L214

Quoted 28 lines
Cc Thomas Zimmermann <[email protected]>
Cc Javier Martinez Canillas <[email protected]>

Ard Biesheuvel (3):
   efi: Wrap screen_info in efi_screen_info so edid_info can be added later
   video/edid: Use getter function for edid_info
   efi: Add FIRMWARE_EDID support

  arch/x86/kernel/setup.c                       |  8 ++++++-- drivers/firmware/efi/earlycon.c               |  1 - drivers/firmware/efi/efi-init.c               | 19 ++++++++++++++----- drivers/firmware/efi/libstub/efi-stub-entry.c |  3 +-- drivers/firmware/efi/libstub/efi-stub.c       | 16 ++++++++++------ drivers/firmware/efi/libstub/efistub.h        |  9 +++------ drivers/firmware/efi/libstub/gop.c            |  1 - drivers/firmware/efi/libstub/screen_info.c    |  7 +++---- drivers/firmware/efi/libstub/zboot.c          |  2 +- drivers/firmware/efi/sysfb_efi.c              |  1 - drivers/gpu/drm/sysfb/efidrm.c                |  4 ++-- drivers/gpu/drm/sysfb/vesadrm.c               |  4 ++-- drivers/video/Kconfig                         |  2 +- drivers/video/fbdev/core/fbmon.c              |  4 ++-- include/linux/efi.h                           | 10 +++++++++- include/video/edid.h                          |  2 +-

  16 files changed, 55 insertions(+), 38 deletions(-)
Signature · 6 lines
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com
GF: Jochen Jaser, Andrew McDonald, Werner Knoblich, (HRB 36809, AG Nürnberg)
maintainer
#6 lore raw
Quoted 33 lines · Thomas Zimmermann

Am 20.11.25 um 08:56 schrieb Thomas Zimmermann:

Quoted 23 lines

Hi,

thanks for addressing the remaining EDID support.

First of all, you need to cc [email protected] on any further revisions.

Am 19.11.25 um 13:30 schrieb Ard Biesheuvel:

Quoted 5 lines

From: Ard Biesheuvel <[email protected]>

Refactor the screen_info handling so non-x86 platforms booting via the EFI stub also have access to the EDID data exposed by the EFI boot services.

I don't like how this series complicates everything to make non-x86 easier. But the general idea of using efi_screen_info goes into the right direction. It's just not generic enough.

The sysfb code transfers struct screen_info as device parameter [1]. Drivers later fetch it on probe [2]. The direct ref to the global edid_info [3] only exists because we have no means of transferring it as device data.

Quoted 5 lines

So instead of using efi_screen_info, let's declare struct sysfb_display with screen_info and edid_info. The header would be linux/sysfb.h. We transfer this to all related drivers. The generic EFI code would set it up like efi_screen_info and the x86 code would decalre it at [4]; replacing the existing state.

Quoted 4 lines

If this proposal works for EFI, I could do the changes in graphics drivers and then resubmit the EDID series with an additional patch for generic EFI.

That sounds great, thanks.

#7 lore raw

Hi

Am 20.11.25 um 09:25 schrieb Ard Biesheuvel:

Quoted 31 lines · Thomas Zimmermann
Quoted 30 lines

Am 20.11.25 um 08:56 schrieb Thomas Zimmermann:

Quoted 27 lines

Hi,

thanks for addressing the remaining EDID support.

First of all, you need to cc [email protected] on any further revisions.

Am 19.11.25 um 13:30 schrieb Ard Biesheuvel:

Quoted 5 lines

From: Ard Biesheuvel <[email protected]>

Refactor the screen_info handling so non-x86 platforms booting via the EFI stub also have access to the EDID data exposed by the EFI boot services.

I don't like how this series complicates everything to make non-x86 easier. But the general idea of using efi_screen_info goes into the right direction. It's just not generic enough.

The sysfb code transfers struct screen_info as device parameter [1]. Drivers later fetch it on probe [2]. The direct ref to the global edid_info [3] only exists because we have no means of transferring it as device data.

So instead of using efi_screen_info, let's declare struct sysfb_display with screen_info and edid_info. The header would be linux/sysfb.h. We transfer this to all related drivers. The generic EFI code would set it up like efi_screen_info and the x86 code would decalre it at [4]; replacing the existing state.

Quoted 5 lines
Quoted 4 lines

If this proposal works for EFI, I could do the changes in graphics drivers and then resubmit the EDID series with an additional patch for generic EFI.

That sounds great, thanks.

Series is out at https://lore.kernel.org/dri-devel/[email protected]/ Once/if merged, we can implement EDID support on top of it for all of EFI.

Best regards
Thomas

Signature · 6 lines
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com
GF: Jochen Jaser, Andrew McDonald, Werner Knoblich, (HRB 36809, AG Nürnberg)