From eaa670cdd3fd69e1a6c8be12d25c2e059458584a Mon Sep 17 00:00:00 2001 From: Jonathan Goyvaerts Date: Thu, 29 Oct 2026 13:36:19 -0300 Subject: [PATCH] drm/apple: show the notch when the boot loader keeps it Showing the notch takes two switches today: aura's chosen.asahi,show-notch=1 keeps the notch rows in the boot framebuffer, and appledrm.show_notch=1 keeps them in the mode. With only the first, the boot framebuffer covers the full panel and the mode does not, so fbcon and Plymouth jump by the notch height at the handoff; with only the second, it is the other way round. aura passes the setting on as /chosen/asahi,show-notch = "1". Read it, so the boot loader setting alone shows the notch from the first frame to the desktop. The module parameters still turn it on as before. On the J616s (MacBook Pro M4 Pro) the mode is 3456x2160 without it and 3456x2234 with it (apple,notch-height = 74). Signed-off-by: Jonathan Goyvaerts Assisted-by: LLM --- drivers/gpu/drm/apple/dcp.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/apple/dcp.c b/drivers/gpu/drm/apple/dcp.c index 7244b8946f643..1879098aef5b6 100644 --- a/drivers/gpu/drm/apple/dcp.c +++ b/drivers/gpu/drm/apple/dcp.c @@ -201,7 +201,7 @@ bool dcp_h17p_external_ready(struct device_node *np) static bool show_notch; module_param(show_notch, bool, 0644); -MODULE_PARM_DESC(show_notch, "Use the full display height and shows the notch"); +MODULE_PARM_DESC(show_notch, "Use the full display height and show the notch (also when /chosen/asahi,show-notch is \"1\")"); static bool dcpext_probe; module_param(dcpext_probe, bool, 0444); @@ -4839,6 +4839,19 @@ static bool dcp_external_is_idle(struct apple_dcp *dcp) (status & APPLE_DCP_COPROC_CPU_STATUS_IDLE); } +/* + * The boot loader keeps the notch rows in its framebuffer when the OS is to + * drive the full panel (aura: chosen.asahi,show-notch=1). Follow it, so the + * mode covers the same rows as the boot framebuffer did. + */ +static bool boot_show_notch(void) +{ + const char *val; + + return !of_property_read_string(of_chosen, "asahi,show-notch", &val) && + !strcmp(val, "1"); +} + /* * The M3 internal displays (14.x and 26.6 IOMFB) also accept * appledrm.t6030_show_notch=1, the switch existing J613/T6030 installs pass, @@ -4847,10 +4860,12 @@ static bool dcp_external_is_idle(struct apple_dcp *dcp) */ static bool dcp_show_notch(struct apple_dcp *dcp) { + bool show = show_notch || boot_show_notch(); + if (dcp->fw_compat != DCP_FIRMWARE_V_14_7 && dcp->fw_compat != DCP_FIRMWARE_V_26_6) - return show_notch; - return show_notch || t6030_show_notch; + return show; + return show || t6030_show_notch; } /*