Skip to content

Commit

Permalink
rpi-cmdline: Fix earlycon for Raspberry Pi 5
Browse files Browse the repository at this point in the history
The UART for earlycon has moved from UART0 on the 40 pin GPIO header
(now wired through the RP1 south bridge chip), to a dedicated debug
header. Using the old configuration with a Raspberry Pi 5 makes
the kernel hang with the fan spinning at full speed.

Change-type: patch
Signed-off-by: Michal Toman <michalt@balena.io>
  • Loading branch information
mtoman committed Jan 10, 2025
1 parent 505bc83 commit d03581f
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ CMDLINE += " dwc_otg.lpm_enable=0 rootwait"
CMDLINE += "${OS_KERNEL_CMDLINE} ${@oe.utils.conditional('SIGN_API','','',"${OS_KERNEL_SECUREBOOT_CMDLINE}",d)}"
CMDLINE =+ " ${@bb.utils.contains('DISTRO_FEATURES','osdev-image',"earlycon=uart8250,mmio32,0xfe215040 console=tty1","",d)}"

# earlycon on the Pi5 is on a dedicated debug header,
# while UART0 on the 40 pin GPIO header is wired behind the RP1 south bridge chip
CMDLINE:remove:raspberrypi5 = "earlycon=uart8250,mmio32,0xfe215040"
CMDLINE:prepend:raspberrypi5 := " ${@bb.utils.contains('DISTRO_FEATURES','osdev-image',"earlycon=pl011,0x107d001000,115200n8","",d)}"

# See https://github.com/raspberrypi/linux/commit/9b0efcc1ec497b2985c6aaa60cd97f0d2d96d203
CMDLINE += " cgroup_enable=memory"
CMDLINE:remove = "root=/dev/mmcblk0p2"
Expand Down

0 comments on commit d03581f

Please sign in to comment.