[SRU] Pi 4B 2GB boot failure

Bug #1940400 reported by Juerg Haefliger
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux-firmware-raspi2 (Ubuntu)
Fix Released
Undecided
Unassigned
Bionic
Fix Released
Critical
Dave Jones

Bug Description

[ Impact ]

Boot failures are being observed with the current Bionic image in some (but not all) Pi 4 2GB rev 1.4 boards (identified by revision code b03114 in /proc/cpuinfo). The back-port is intended to rectify booting on these machines. It is expected that most future 2GB boards in the market are likely to be revision 1.4 as this is the latest revision of the Pi 4 board.

[ Test Case ]

* Flash Ubuntu 18.04.5 preinstalled server arm64 image to an SD card
* Boot the card on a Raspberry Pi
  - Please note that failure has only been observed (and only intermittently) on the Pi 4 2GB rev 1.4 boards
  - These boards can be identified as having the Revision b03114 in /proc/cpuinfo
  - On these boards, boot *may* fail during kernel startup with the current firmware. If it fails, boot the card on another Pi and ensure it completes successfully
  - On all other boards, expect successful boot at this point
* Upgrade all packages: sudo apt update && sudo apt upgrade
* Enable proposed: https://wiki.ubuntu.com/Testing/EnableProposed
* Upgrade linux-firmware-raspi2 to -proposed version: sudo apt install -t bionic-proposed linux-firmware-raspi2
* Reboot and ensure boot completes successfully on all Pi models
  - Please note that if you switched the SD card to successfully boot previously (due to boot failure on a 2GB rev 1.4 board), remember to switch the card back to the original Pi to re-test boot and verify it completes successfully

[ Regression Potential ]

As with anything updating with the boot sequence, boot failure is a possibility. However, the boot firmware being back-ported is currently in active use on focal and hirsute with no issues, and the purpose of the back-port is to fix an existing observed boot failure in the new generation of Pi 4 2GB boards (which are now becoming more prevalent in the market).

[ Original Description ]

Some Pi 4B 2GBs fail to boot the current raspi bionic server image (and core18). The kernel starts running but then just stops:

PM_RSTS: 0x00000020
RPi: BOOTLOADER release VERSION:c2f8c388 DATE: Apr 29 2021 TIME: 17:11:29 BOOTMODE: 0x00000006 part: 0 BUILD_TIMESTAMP=1619712685 0x70fc87a2 0x00b03114 0x000d1bfc
PM_RSTS: 0x00000020
part 00000000 reset_info 00000000
uSD voltage 3.3V
Initialising SDRAM 'Samsung' 16Gb x1 total-size: 16 Gbit 3200
PCI reset
PCI reset
VLI: HUB2: 0xfff00000 0x24e6 MCU: 0xfff20000 0x15218
XHCI-STOP
xHC ver: 256 HCS: 05000420 fc000031 00e70004 HCC: 002841eb
xHC ver: 256 HCS: 05000420 fc000031 00e70004 HCC: 002841eb
xHC ports 5 slots 32 intrs 4
Boot mode: SD (01) order 0
SD HOST: 250000000 CTL0: 0x00000000 BUS: 100000 Hz actual: 100000 HZ div: 2500 (1250) status: 0x1fff0000 delay: 1080
SD HOST: 250000000 CTL0: 0x00000f00 BUS: 100000 Hz actual: 100000 HZ div: 2500 (1250) status: 0x1fff0000 delay: 1080
OCR c0ff8000 [18]
CID: 000357445348333247801a9f373b013a
CSD: 400e0032db790000edc87f800a404000
SD: bus-width: 4 spec: 2 SCR: 0x02358483 0x00000000
SD HOST: 250000000 CTL0: 0x00000f04 BUS: 50000000 Hz actual: 41666666 HZ div: 6 (3) status: 0x1fff0000 delay: 2
MBR: 0x00000800, 524288 type: 0x0c
MBR: 0x00080800,61807583 type: 0x83
MBR: 0x00000000, 0 type: 0x00
MBR: 0x00000000, 0 type: 0x00
Trying partition: 0
lba: 2048 oem: 'mkfs.fat' volume: ' system-boot'
rsc 32 fat-sectors 4033 c-count 516190 c-size 1 r-dir 2 r-sec 0
PM_RSTS: 0x00000020
Trying partition: 0
lba: 2048 oem: 'mkfs.fat' volume: ' system-boot'
rsc 32 fat-sectors 4033 c-count 516190 c-size 1 r-dir 2 r-sec 0
Read config.txt bytes 1233 hnd 0x0002478c
gpio4 0=1
Read start4.elf bytes 2278432 hnd 0x0005facb
Read fixup4.dat bytes 5418 hnd 0x00054c4d
Firmware: 4439d2aaa6c376a2d1ef4402f142e1cf4de37c43 Sep 2 2020 21:13:13
0x00b03114 0x00000000 0x0000001f
MEM GPU: 76 ARM: 948 TOTAL: 1024
Starting start4.elf @ 0xfec00200 partition 0
PCI reset
+

U-Boot 2020.10+dfsg-1ubuntu0~20.04.2 (Jan 08 2021 - 13:03:11 +0000)

DRAM: 1.9 GiB
RPI 4 Model B (0xb03114)
MMC: mmcnr@7e300000: 1, emmc2@7e340000: 0
Loading Environment from FAT... *** Warning - bad CRC, using default environment

In: serial
Out: vidconsole
Err: vidconsole
Net: eth0: ethernet@7d580000
starting USB...
No working controllers found
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1...
Found U-Boot script /boot.scr
4660 bytes read in 33 ms (137.7 KiB/s)
## Executing script at 02400000
Failed to load '//uboot/ubuntu/boot.sel'
8393691 bytes read in 634 ms (12.6 MiB/s)
Total of 1 halfword(s) were the same
Decompressing kernel...
Uncompressed size: 23843328 = 0x16BD200
29957183 bytes read in 2190 ms (13 MiB/s)
Booting Ubuntu (with booti) from mmc 0:...
## Flattened Device Tree blob at 02600000
   Booting using the fdt blob at 0x2600000
   Using Device Tree in place at 0000000002600000, end 000000000260ee67

Starting kernel ...

[ 0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd083]
[ 0.000000] Linux version 5.4.0-1034-raspi (buildd@bos02-arm64-050) (gcc version 9.3.0 (Ubuntu 9.3.0-17ubuntu1~20.04)) #37-Ubuntu SMP PREEMPT Mon Apr 12 23:14:49 UTC 2021 (Ubuntu 5.4.0-1034.37-raspi 5.4.101)
[ 0.000000] Machine model: Raspberry Pi 4 Model B Rev 1.4
[ 0.000000] earlycon: uart8250 at MMIO32 0x00000000fe215040 (options '')
[ 0.000000] printk: bootconsole [uart8250] enabled
[ 0.000000] efi: Getting EFI parameters from FDT:
[ 0.000000] efi: UEFI not found.
[ 0.000000] Reserved memory: created CMA memory pool at 0x000000002c000000, size 64 MiB
[ 0.000000] OF: reserved mem: initialized node linux,cma, compatible id shared-dma-pool
[ 0.000000] On node 0 totalpages: 504832
[ 0.000000] DMA zone: 3792 pages used for memmap
[ 0.000000] DMA zone: 0 pages reserved
[ 0.000000] DMA zone: 242688 pages, LIFO batch:63
[ 0.000000] DMA32 zone: 4096 pages used for memmap
[ 0.000000] DMA32 zone: 262144 pages, LIFO batch:63
[ 0.000000] percpu: Embedded 32 pages/cpu s92120 r8192 d30760 u131072
[ 0.000000] pcpu-alloc: s92120 r8192 d30760 u131072 alloc=32*4096
[ 0.000000] pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3
[ 0.000000] Detected PIPT I-cache on CPU0
[ 0.000000] CPU features: detected: EL2 vector hardening
[ 0.000000] CPU features: kernel page table isolation forced ON by KASLR
[ 0.000000] CPU features: detected: Kernel page table isolation (KPTI)
[ 0.000000] ARM_SMCCC_ARCH_WORKAROUND_1 missing from firmware
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 496944
[ 0.000000] Kernel command line: coherent_pool=1M 8250.nr_uarts=1 snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1 bcm2708_fb.fbwidth=1824 bcm2708_fb.fbheight=984 bcm2708_fb.fbswap=1 smsc95xx.macaddr=E4:5F:01:49:37:9A vc_mem.mem_base=0x3ec00000 vc_mem.mem_size=0x40000000 net.ifnames=0 dwc_otg.lpm_enable=0 root=LABEL=writable rootfstype=ext4 elevator=deadline rootwait fixrtc console=tty1 console=ttyS0,115200 loglevel=8 earlycon=uart8250,mmio32,0xfe215040
[ 0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes, linear)
[ 0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
[ 0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[ 0.000000] software IO TLB: mapped [mem 0x37400000-0x3b400000] (64MB)
[ 0.000000] Memory: 1793644K/2019328K available (11772K kernel code, 1268K rwdata, 4288K rodata, 4096K init, 1076K bss, 160148K reserved, 65536K cma-reserved)
[ 0.000000] random: get_random_u64 called from kmem_cache_open+0x3c/0x3e0 with crng_init=0
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[ 0.000000] ftrace: allocating 39069 entries in 153 pages
[ 0.000000] rcu: Preemptible hierarchical RCU implementation.
[ 0.000000] Tasks RCU enabled.
[ 0.000000] rcu: RCU calculated value of scheduler-enlistment delay is 25 jiffies.
[ 0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[ 0.000000] GIC: Using split EOI/Deactivate mode
[ 0.000000] arch_timer: cp15 timer(s) running at 54.00MHz (phys).
[ 0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0xc743ce346, max_idle_ns: 440795203123 ns
[ 0.000006] sched_clock: 56 bits at 54MHz, resolution 18ns, wraps every 4398046511102ns
[ 0.008337] Console: colour dummy device 80x25
[ 0.013363] printk: console [tty1] enabled
[ 0.017566] Calibrating delay loop (skipped), value calculated using timer frequency.. 108.00 BogoMIPS (lpj=216000)
[ 0.028153] pid_max: default: 32768 minimum: 301
[ 0.033052] LSM: Security Framework initializing
[ 0.037789] Yama: becoming mindful.
[ 0.041413] AppArmor: AppArmor initialized
[ 0.045774] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
[ 0.053307] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
[ 0.061314] *** VALIDATE tmpfs ***
[ 0.065446] *** VALIDATE proc ***
[ 0.069396] Disabling memory control group subsystem
[ 0.074507] *** VALIDATE cgroup1 ***
[ 0.078131] *** VALIDATE cgroup2 ***
[ 0.083066] ASID allocator initialised with 32768 entries
[ 0.088741] rcu: Hierarchical SRCU implementation.
[ 0.095776] EFI services will not be available.
[ 0.101311] smp: Bringing up secondary CPUs ...
[ 0.106937] Detected PIPT I-cache on CPU1
[ 0.106991] CPU1: Booted secondary processor 0x0000000001 [0x410fd083]
[ 0.108063] Detected PIPT I-cache on CPU2
[ 0.108102] CPU2: Booted secondary processor 0x0000000002 [0x410fd083]
[ 0.109152] Detected PIPT I-cache on CPU3
[ 0.109189] CPU3: Booted secondary processor 0x0000000003 [0x410fd083]
[ 0.109338] smp: Brought up 1 node, 4 CPUs
[ 0.145582] SMP: Total of 4 processors activated.
[ 0.150365] CPU features: detected: 32-bit EL0 Support
[ 0.155627] CPU features: detected: CRC32 instructions
[ 0.168524] CPU features: emulated: Privileged Access Never (PAN) using TTBR0_EL1 switching
[ 0.177003] CPU: All CPU(s) started at EL2
[ 0.181244] alternatives: patching kernel code
[ 0.187214] devtmpfs: initialized
[ 0.200656] Enabled cp15_barrier support
[ 0.204683] Enabled setend support
[ 0.208603] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns
[ 0.218507] futex hash table entries: 1024 (order: 4, 65536 bytes, linear)
[ 0.227797] pinctrl core: initialized pinctrl subsystem
[ 0.233762] DMI not present or invalid.
[ 0.238327] NET: Registered protocol family 16
[ 0.245375] DMA: preallocated 1024 KiB pool for atomic allocations
[ 0.251663] audit: initializing netlink subsys (disabled)
[ 0.257405] audit: type=2000 audit(0.192:1): state=initialized audit_enabled=0 res=1
[ 0.265320] cpuidle: using governor ladder
[ 0.269531] cpuidle: using governor menu
[ 0.274026] hw-breakpoint: found 6 breakpoint and 4 watchpoint registers.
[ 0.281220] Serial: AMBA PL011 UART driver
[ 0.288441] bcm2835-mbox fe00b880.mailbox: mailbox enabled
[ 0.306096] raspberrypi-firmware soc:firmware: Attached to firmware from 2020-09-02 21:13, variant start
[ 0.319748] raspberrypi-firmware soc:firmware: Firmware hash is 4439d2aaa6c376a2d1ef4402f142e1cf4de37c43
[ 0.372452] bcm2835-dma fe007000.dma: DMA legacy API manager, dmachans=0x1
[ 0.382547] iommu: Default domain type: Translated
[ 0.388770] SCSI subsystem initialized
[ 0.392820] libata version 3.00 loaded.
[ 0.396920] usbcore: registered new interface driver usbfs
[ 0.402542] usbcore: registered new interface driver hub
[ 0.407989] usbcore: registered new device driver usb
[ 0.413484] pps_core: LinuxPPS API ver. 1 registered
[ 0.418529] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <email address hidden>
[ 0.427801] PTP clock support registered
[ 0.432025] EDAC MC: Ver: 3.0.0
[ 0.436554] NetLabel: Initializing
[ 0.440035] NetLabel: domain hash size = 128
[ 0.444466] NetLabel: protocols = UNLABELED CIPSOv4 CALIPSO
[ 0.450277] NetLabel: unlabeled traffic allowed by default
[ 0.456854] clocksource: Switched to clocksource arch_sys_counter
[ 0.561061] *** VALIDATE bpf ***
[ 0.564679] VFS: Disk quotas dquot_6.6.0
[ 0.568770] VFS: Dquot-cache hash table entries: 512 (order 0, 4096 bytes)
[ 0.575877] *** VALIDATE ramfs ***
[ 0.579960] AppArmor: AppArmor Filesystem Enabled
[ 0.585188] simple-framebuffer 3e513000.framebuffer: framebuffer at 0x3e513000, 0x6d8c00 bytes, mapped to 0x(____ptrval____)
[ 0.596573] simple-framebuffer 3e513000.framebuffer: format=a8r8g8b8, mode=1824x984x32, linelength=7296
[ 0.616375] Console: switching to colour frame buffer device 228x61
[ 0.631942] simple-framebuffer 3e513000.framebuffer: fb0: simplefb registered!
[ 0.649421] thermal_sys: Registered thermal governor 'fair_share'
[ 0.649427] thermal_sys: Registered thermal governor 'bang_bang'
[ 0.655691] thermal_sys: Registered thermal governor 'step_wise'
[ 0.661840] thermal_sys: Registered thermal governor 'user_space'
[ 0.667988] thermal_sys: Registered thermal governor 'power_allocator'
[ 0.674734] NET: Registered protocol family 2
[ 0.686601] tcp_listen_portaddr_hash hash table entries: 1024 (order: 2, 16384 bytes, linear)
[ 0.695372] TCP established hash table entries: 16384 (order: 5, 131072 bytes, linear)
[ 0.703566] TCP bind hash table entries: 16384 (order: 6, 262144 bytes, linear)
[ 0.711265] TCP: Hash tables configured (established 16384 bind 16384)
[ 0.718150] UDP hash table entries: 1024 (order: 3, 32768 bytes, linear)
[ 0.725036] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes, linear)
[ 0.732570] NET: Registered protocol family 1
[ 0.737065] NET: Registered protocol family 44
[ 0.741625] PCI: CLS 0 bytes, default 64
[ 0.745903] Trying to unpack rootfs image as initramfs...
[ 1.437227] Freeing initrd memory: 29252K
[ 1.443047] hw perfevents: enabled with armv8_cortex_a72 PMU driver, 7 counters available
[ 1.451631] kvm [1]: IPA Size Limit: 44bits
[ 1.456850] kvm [1]: vgic interrupt IRQ1
[ 1.461127] kvm [1]: Hyp mode initialized successfully
[ 1.468625] Initialise system trusted keyrings
[ 1.473269] Key type blacklist registered
[ 1.477659] workingset: timestamp_bits=46 max_order=19 bucket_order=0
[ 1.491206] zbud: loaded
[ 1.495877] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[ 1.502933] fuse: init (API version 7.31)
[ 1.507173] *** VALIDATE fuse ***
[ 1.510591] *** VALIDATE fuse ***
[ 1.537669] Key type asymmetric registered
[ 1.544140] Asymmetric key parser 'x509' registered
[ 1.551407] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 242)
[ 1.561406] io scheduler mq-deadline registered
[ 1.572749] brcm-pcie fd500000.pcie: host bridge /scb/pcie@7d500000 ranges:
[ 1.582239] brcm-pcie fd500000.pcie: No bus range found for /scb/pcie@7d500000, using [bus 00-ff]
[ 1.593864] brcm-pcie fd500000.pcie: MEM 0x0600000000..0x0603ffffff -> 0x00f8000000
[ 1.604513] brcm-pcie fd500000.pcie: IB MEM 0x0000000000..0x007fffffff -> 0x0000000000
[ 1.678948] brcm-pcie fd500000.pcie: link up, 5 GT/s x1 (SSC)
[ 1.687422] brcm-pcie fd500000.pcie: PCI host bridge to bus 0000:00
[ 1.696167] pci_bus 0000:00: root bus resource [bus 00-ff]
[ 1.704114] pci_bus 0000:00: root bus resource [mem 0x600000000-0x603ffffff] (bus address [0xf8000000-0xfbffffff])
[ 1.717081] pci 0000:00:00.0: [14e4:2711] type 01 class 0x060400
[ 1.725815] pci 0000:00:00.0: PME# supported from D0 D3hot
[ 1.737667] pci 0000:01:00.0: [1106:3483] type 00 class 0x0c0330
[ 1.746329] pci 0000:01:00.0: reg 0x10: [mem 0x00000000-0x00000fff 64bit]
[ 1.756041] pci 0000:01:00.0: PME# supported from D0 D3hot
[ 1.767833] pci 0000:00:00.0: BAR 14: assigned [mem 0x600000000-0x6000fffff]
[ 1.777441] pci 0000:01:00.0: BAR 0: assigned [mem 0x600000000-0x600000fff 64bit]
[ 1.787479] pci 0000:00:00.0: PCI bridge to [bus 01]
[ 1.794950] pci 0000:00:00.0: bridge window [mem 0x600000000-0x6000fffff]
[ 1.804713] pcieport 0000:00:00.0: enabling device (0000 -> 0002)
[ 1.813515] pcieport 0000:00:00.0: PME: Signaling with IRQ 41
[ 1.822107] pcieport 0000:00:00.0: AER: enabled with IRQ 41
[ 1.830373] pci 0000:01:00.0: enabling device (0000 -> 0002)
[ 1.883240] pci 0000:01:00.0: quirk_usb_early_handoff+0x0/0x658 took 51619 usecs
[ 1.893475] bcm2708_fb soc:fb: FB found 1 display(s)
[ 1.912150] bcm2708_fb soc:fb: Registered framebuffer for display 0, size 1824x984
[ 1.987512] Serial: 8250/16550 driver, 1 ports, IRQ sharing enabled
[ 1.998913] iproc-rng200 fe104000.rng: hwrng registered
[ 2.007084] vc-mem: phys_addr:0x00000000 mem_base=0x3ec00000 mem_size:0x40000000(1024 MiB)
[ 2.018792] gpiomem-bcm2835 fe200000.gpiomem: Initialised: Registers at 0xfe200000
[ 2.029314] cacheinfo: Unable to detect cache hierarchy for CPU 0
[ 2.410834] loop: module loaded
[ 2.419245] spi-bcm2835 fe204000.spi: could not get clk: -517
[ 2.429340] libphy: Fixed MDIO Bus: probed
[ 2.435959] tun: Universal TUN/TAP device driver, 1.6
[ 2.444128] bcmgenet fd580000.ethernet: failed to get enet clock
[ 2.452645] bcmgenet fd580000.ethernet: GENET 5.0 EPHY: 0x0000
[ 2.460941] bcmgenet fd580000.ethernet: failed to get enet-wol clock
[ 2.469784] bcmgenet fd580000.ethernet: failed to get enet-eee clock
[ 2.478613] bcmgenet: Skipping UMAC reset
[ 2.496893] libphy: bcmgenet MII bus: probed
[ 2.556953] unimac-mdio unimac-mdio.-19: Broadcom UniMAC MDIO bus
[ 2.566368] PPP generic driver version 2.4.2
[ 2.573308] usbcore: registered new interface driver lan78xx
[ 2.581479] usbcore: registered new interface driver smsc95xx
[ 2.589673] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 2.598656] ehci-pci: EHCI PCI platform driver
[ 2.605559] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[ 2.614196] ohci-pci: OHCI PCI platform driver
[ 2.621079] uhci_hcd: USB Universal Host Controller Interface driver
[ 2.630318] xhci_hcd 0000:01:00.0: xHCI Host Controller
[ 2.637986] xhci_hcd 0000:01:00.0: new USB bus registered, assigned bus number 1
[ 2.648416] xhci_hcd 0000:01:00.0: hcc params 0x002841eb hci version 0x100 quirks 0x0000009000000890
[ 2.661235] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.04
[ 2.672095] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 2.681887] usb usb1: Product: xHCI Host Controller
[ 2.689274] usb usb1: Manufacturer: Linux 5.4.0-1034-raspi xhci-hcd
[ 2.698063] usb usb1: SerialNumber: 0000:01:00.0
[ 2.705741] hub 1-0:1.0: USB hub found
[ 2.712034] hub 1-0:1.0: 1 port detected
[ 2.718985] xhci_hcd 0000:01:00.0: xHCI Host Controller
[ 2.726689] xhci_hcd 0000:01:00.0: new USB bus registered, assigned bus number 2
[ 2.736596] xhci_hcd 0000:01:00.0: Host supports USB 3.0 SuperSpeed
[ 2.745699] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 5.04
[ 2.756531] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 2.766274] usb usb2: Product: xHCI Host Controller
[ 2.773597] usb usb2: Manufacturer: Linux 5.4.0-1034-raspi xhci-hcd
[ 2.782340] usb usb2: SerialNumber: 0000:01:00.0
[ 2.789947] hub 2-0:1.0: USB hub found
[ 2.796228] hub 2-0:1.0: 4 ports detected
[ 2.803658] dwc_otg: version 3.00a 10-AUG-2012 (platform bus)
[ 2.812127] dwc_otg: FIQ enabled
[ 2.817759] dwc_otg: NAK holdoff enabled
[ 2.824080] dwc_otg: FIQ split-transaction FSM enabled
[ 2.831635] Module dwc_common_port init
[ 2.838407] mousedev: PS/2 mouse device common for all mice
[ 2.846863] i2c /dev entries driver
[ 2.855789] bcm2835-wdt bcm2835-wdt: Broadcom BCM2835 watchdog timer
[ 2.864868] device-mapper: uevent: version 1.0.3
[ 2.872204] device-mapper: ioctl: 4.41.0-ioctl (2019-09-16) initialised: <email address hidden>

It seems there's something different about some Pi 4s since the same image boots just fine on other Pi 4s. I found that updating the Pi firmware to at least 1.20201022 'fixes' the boot problem of these 'special' Pis.

CVE References

Juerg Haefliger (juergh)
summary: - Some Pi 4Bs fail to boot
+ Pi 4B 2GB boot failure
Changed in linux-firmware-raspi2 (Ubuntu Bionic):
importance: Undecided → Critical
Juerg Haefliger (juergh)
Changed in linux-firmware-raspi2 (Ubuntu Bionic):
assignee: nobody → Dave Jones (waveform)
status: New → Confirmed
tags: added: fr-1669
tags: added: rls-ii-incoming
Revision history for this message
William Wilson (jawn-smith) wrote : Re: Pi 4B 2GB boot failure

I've installed the edge kernel on my Pi 4 Rev 1.4 2GB board and haven't been able to recreate the issue:

jawn-smith@localhost:~$ snap info pi-kernel | egrep "installed|18-pi/edge"
tracking: 18-pi/edge
18-pi/edge: 5.4.0-1043.47~18.04.1 2021-08-25 (343) 193MB -
installed: 5.4.0-1043.47~18.04.1 (343) 193MB kernel
jawn-smith@localhost:~$ uname -r
5.4.0-1043-raspi
jawn-smith@localhost:~$ cat /proc/device-tree/model ; echo
Raspberry Pi 4 Model B Rev 1.4
jawn-smith@localhost:~$ free -h
total used free shared buff/cache available
Mem: 1.8G 146M 1.4G 9.4M 226M 1.6G
Swap: 0B 0B 0B

Revision history for this message
Dave Jones (waveform) wrote :

Discussed jawn-smith's failure to reproduce with juergh; it appears the issue only affects certain Pi 4 2GB rev 1.4's but not others. The test package prepared in https://launchpad.net/~waveform/+archive/ubuntu/firmware appears to fix the issue over several devices juergh has tested so I've pushed it (with one further fix to excise the pointless flash-kernel trigger) to bionic-proposed.

tags: removed: rls-ii-incoming
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

I'm generally +1 on getting this accepted, and I know that writing SRU information for such cases is not really easy (since it is not a targeted fix just a new release version). But could we at least get a formalized test case people might run? + any other nice-to-run tests to make sure that we didn't regress any other devices.

Also, this might just be how this upload is, but let me double-confirm: looking at the diffstat of the generated debdiff I see:
9512 files changed, 309 insertions(+), 711758 deletions(-)

...but I guess that's just how it is?

Changed in linux-firmware-raspi2 (Ubuntu Bionic):
status: Confirmed → Incomplete
Revision history for this message
Juerg Haefliger (juergh) wrote :

The 'fix' is to backport the Pi fw from focal. The testcase is booting a Pi :-)

The current bionic 5.4 raspi kernel is also a backport from focal so that new combo for bionic is what we're currently running in focal. If that's problematic we should have received focal bug reports by now.

Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Yes, sure, but SRU procedures require defining at least some base test criteria. So I'd like us to include info about which exact Pi device is affected and needs to be tested + maybe a requirement to test it on a few other Pi's as well, just to be sure we did not regress. We need to look at the bigger picture here - and that's what the SRU procedures are for. So that we have clarity on what to test, what's the impact and how to gauge the risk. Anyway, this is basically just paperwork to fill in.

I checked the diff and compared it with the diff we had in focal - and it seems sane, there we also had so many removed lines (guess bluez etc. went away). I'm a bit worried about one more change, but I *think* I know why it was in focal. So in focal there was "+Breaks: flash-kernel (<<3.103)", and I assume it's because we had some bad changes in flash-kernel 3.98ubuntu12 (which was the previous version). Bionic was stuck on 3.98ubuntu11~18.04.2. But the question is: is that flash-kernel version good enough? What was this interaction between the two packages?

That's useful to check. I'll let it in as-is, but I'll need both the paperwork filled in and the flash-kernel breaks explained before we go out with this.

Changed in linux-firmware-raspi2 (Ubuntu Bionic):
status: Incomplete → Fix Committed
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

Hello Juerg, or anyone else affected,

Accepted linux-firmware-raspi2 into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/linux-firmware-raspi2/4-0ubuntu0~18.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Łukasz Zemczak (sil2100) wrote : Re: Pi 4B 2GB boot failure

Okay, I think I see that the missing breaks in flash-kernel might be planned (per debian/changelog).

Dave Jones (waveform)
description: updated
summary: - Pi 4B 2GB boot failure
+ [SRU] Pi 4B 2GB boot failure
Revision history for this message
Dave Jones (waveform) wrote :

@sil2100 -- sorry, forgot SRU procedures were necessary in this case! I've amended the description as requested.

You are correct that the "Breaks: flash-kernel" omission in d/control is indeed deliberate: in flash-kernel 3.100 onwards (which isn't present in Bionic, and which I don't fancy *also* back-porting simultaneously as the changes are more invasive) handles the transfer of the boot firmware (and everything else, u-boot, kernel, initrd, etc.) to the boot partition. Prior to this, the task was fragmented across packages (but only on the pi, and not on any other platforms flash-kernel dealt with):

* pi boot firmware was copied by this package's postinst (hence why this is re-instated in the proposed package)
* u-boot binaries were copied by that package's postinst
* kernel and initrd were copied by flash-kernel

tags: added: verification-needed verification-needed-bionic
Dave Jones (waveform)
tags: added: verification-done-bionic
removed: verification-needed-bionic
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in linux-firmware-raspi2 (Ubuntu):
status: New → Confirmed
Revision history for this message
Brian Murray (brian-murray) wrote :

@Dave Jones - Could you add some more details regarding the verification that you did. Did you test booting on all the Pi models?

Revision history for this message
Juerg Haefliger (juergh) wrote (last edit ):

I did some additional testing and found another defect with the current linux-firmware-raspi2 version 1.20200601+arm64-0ubuntu2~18.04.1.

The Pi 400 and CM4 models are not correctly identified:

Pi 400:
ubuntu@ubuntu:~$ tail -4 /proc/cpuinfo
Hardware : BCM2835
Revision : c03130
Serial : 100000008a8f5e8e
Model : Raspberry Pi ? Rev 1.0

Pi CM4:
ubuntu@ubuntu:~$ tail -4 /proc/cpuinfo
Hardware : BCM2835
Revision : c03140
Serial : 10000000535a0643
Model : Raspberry Pi ? Rev 1.0

After upgrading to 4-0ubuntu0~18.04.1 from bionic-proposed all seems fine:

ubuntu@rpi-400-rev1d0-5e8e:~$ tail -4 /proc/cpuinfo
Hardware : BCM2835
Revision : c03130
Serial : 100000008a8f5e8e
Model : Raspberry Pi 400 Rev 1.0

ubuntu@rpi-cm4-rev1d0-0643:~$ tail -4 /proc/cpuinfo
Hardware : BCM2835
Revision : c03140
Serial : 10000000535a0643
Model : Raspberry Pi Compute Module 4 Rev 1.0

Revision history for this message
Juerg Haefliger (juergh) wrote :

Successfully boot tested linux-firmware-raspi2 4-0ubuntu0~18.04.1 arm64 on Pi 4B, 400, CM4, CM3+, 3B+, 3B and 3A+.

Revision history for this message
Dave Jones (waveform) wrote :

@brian-murray Yes, booted on 2B (rev 1.1), 3B, 3B+, 3A+, 4B (rev 1.1 and a rev 1.4, though I don't have a 2GB rev 1.4 -- jawn-smith and juergh both kindly tested that specific model), 400, and a model of the CM4 (specifically one with wifi, 4GB RAM, 8GB eMMC)

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package linux-firmware-raspi2 - 4-0ubuntu0~18.04.1

---------------
linux-firmware-raspi2 (4-0ubuntu0~18.04.1) bionic; urgency=medium

  * Backport to bionic (LP: #1940400)
    - Removed Breaks on flash-kernel and reinstated postinst to install boot
      firmware
    - Added diversions for all wifi firmware blobs
    - New upstream boot firmware release, 1.20210303
    - New upstream bluetooth firmware release, 1.2-4+rpt8

      [ Phil Elwell ]
      - Second Spectra fix for CYW43455 (CVE-2020-10370)
        - Original firmware name: BCM4345C0_003.001.025.0174.0342.hcd

    - New upstream wifi firmware release, 1:20190114-1+rpt11

      [ Serge Schneider ]
      - Update CYW43455 firmware
        - brcm/brcmfmac43455-sdio.bin 7.45.229
        - See: https://github.com/raspberrypi/linux/issues/3849

 -- Dave Jones <email address hidden> Tue, 31 Aug 2021 15:43:35 +0100

Changed in linux-firmware-raspi2 (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Brian Murray (brian-murray) wrote : Update Released

The verification of the Stable Release Update for linux-firmware-raspi2 has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Dave Jones (waveform)
Changed in linux-firmware-raspi2 (Ubuntu):
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.