Raspberry Pi 4 Model B Rev 1.5 - error -5 whilst initialising SD card

Hello Everyone,

first of all, thanks for IPFire - i think i use it for 10+ years now and were always happy with it.

But today i ran into a new issue - The new Rev 1.5 of the Raspberry Pi 4 Model B i received last week. (In Raspberry OS Raspbian you can see it via “cat /proc/cpuinfo | egrep -A3 Hardware”)

The issue is somehow similar as it has been with Rev 1.4 booting from the internal ySD card. You always get the: “error -5 whilst initialising SD card” boot loop.

The Version i tried is IPFire 2.27 - Core Update 164 (and also tried 162 and 163 - and even the latest nightly next Core 166)

What i allready did: Read all topics regarding Rev 1.4 of the Raspberry and also did the eeprom update, mentionend in this topic: RPi 4 boot failure with 162 and 163 - #9 by lincoln - But even with eeprom firmware from the stable channel, the Raspberry will not boot from the ySD Card.

To be sure, it has something to do with the eeprom, i also tried to boot via a USB-ySD adapter, which worked. And also installing IPFire on an USB-Stick directly worked without any issues. So the issue is only the internal ySD card slot.

I also found a topic at arch Linux regarding the new Rev 1.5 of the Raspberry - Maybe this can assist in finding, what should be changed on IPFire to be working again with the Rev 1.5 - Here is the arch Linux forum: Arch Linux ARM • View topic - Raspberry Pi 4 Model B 8 GB (2/3 Fail with SD Card error)

If you’d like me to try something out, please, i will do my best to assist in getting IPFire back to work on the Rev 1.5.

Thank you and all the best
wiesel

Hello wiesel - Welcome to the IPFire Community!

Please post the output of this command.

Hardware: BCM2835
Revision: a03115
Serial: …
Model: Raspberry Pi 4 Model B Rev 1.5

Anyone has an idea how to get the 1.5 Raspi booting again from ySD card?

It realy seems to be an issue with the eeprom and 1.5 Rasp in combination and all previous recommended steps did not help (and i tried many of them now.)

Thank you,
wiesel

I am guessing the answer is “unknown” at the moment. @arne_f is the Dev and probably does not have this Revision of the device. He’ll respond when he can…

The boot partition of the bootrom is different in 1.4v and 1.5v.

I just came to know through a YouTube video.
It leads to boot issues.

Idk if it is the same issue in your case, most of the default images must be for 1.4v.

Ok thanks.

Maybe i will try what they did in the Arch Topic “replacing “fdt_addr_r” with “fdt_addr”” - But i will have to see if this can be done easily with IPFire. If there is success i will share it, for sure.

1 Like

Finally i managed to get it working with booting from the ySD card.

So here the steps to get the Raspberry Rev 1.5 working:

  • Flash/dd aarch64 Core 166 Flash image to ySD Card
  • Don’t forget to set “SERIAL-CONSOLE=OFF” in uEnv.txt
  • Edit boot.cmd Lines 90 and 93 (the “booti” lines) from
 booti ${kernel_addr_r} ${ramdisk_addr} ${fdt_addr_r};

to

 booti ${kernel_addr_r} ${ramdisk_addr} ${fdt_addr};

and

booti ${kernel_addr_r} - ${fdt_addr_r};

to

booti ${kernel_addr_r} - ${fdt_addr};
  • To rebuild the boot image i did this on a debian/raspbian:
apt install u-boot-tools

Mount and change to the directory of the ySD card and run:

mkimage -A arm -T script -O linux -d boot.cmd boot.scr
  • Insert ySD into Raspberry and boot it

After this, the first bootup, resizing of the partition with rebooot and IPFire first start with setup finished successfull

1 Like

Hello @wiesel ,

I also have the 1.5 revision.

I have 2 SD Cards , one has raspberry pi os and the other one i flashed with the ipfire you mentioned (166).
I booted raspberry os, plugged in the ipfire sd card with a usb card reader , changed directory and rebuilt the image just like mentioned in your steps.

After rebuilding the image i removed the ipfire from the usb reader and plugged it into the raspberries sd slot , rebooted but the error still appears.

Any help ?

Regards

Hello and welcome Gabriel,

did you check if the boot.src was touched/changed? I touched my raspberry last time in last april (because i struggled on doing some vlan configs on the single network card and did not have time to investigate further) - so i would have to try it again if it is still working.
Did you also do the update i linked in my first post: RPi 4 boot failure with 162 and 163 - #9 by lincoln ?

Greetings

Hello wiesel and Thanks!

Well the boot.src was created ,yes .

The only way i managed to boot ipfire installation was to insert the sd card into a usb card reader.

I did not follow the eeprom flash process yet . Is it necessary to be able to boot from the sd slot?

Cheers

I think, the eeprom flash is needed - so please give it a try.

Hi Gabriel,

i just tried it with my Raspi 4 rev 1.5 and the current core173 - and it is not working :frowning:

I also found a typo in my last post - It was boot.sCR not boot.sRC (but i am not able to edit it) - But besides the typo, it is not working with the current core173 - I will test older versions to see if it is working and post an update here.

Greetings

For everyone who will be coming here to install ipfire on their Raspberry Pi 4 rev 1.4 or 1.5 and want to boot it from SD Card:

With latest rpi-eeprom-update Version 138c0 from 11.01.2023 (Updated via Booting from latest Raspberry OS and running “rpi-eeprom-update -a -d”) and ipfire-2.27 core 171 aarch64 ipfire is working when booting from SD card. (core 172 and 173 are Not working with SD Card)
For SD boot to work, the bootimage still has to be rebuilt like stated in this post: Raspberry Pi 4 Model B Rev 1.5 - error -5 whilst initialising SD card - #8 by wiesel

172 and 173 are working, when booting from USB - I will try to find out the difference, why 171 is the last working version for SD card.

Greetings

1 Like

I have edited the command to boot.scr in that post for you.

2 Likes

Hello,

i did some more testing with core 172 and 173 not working anymore when booting from SD Card - You get an Error:

USB XHCI 1.00
scanning bus xhci_pci for devices… Unexpected XHCI event TRB, skipping… (3df5d620 00000004 01000000 01008401)
BUG at drivers/usb/host/xhci-ring.c:530/abort_td()!
BUG!
resetting …

I now had a look which files where changed from core 171 to 172/173.

Following the boot order the Raspberry / U-Boot does i just did a simple test:

I moved the u-boot-rpi4.bin file from 171 SD card to a 173 SD card - And it is working. So, something must have changed in the u-boot image to trigger the XHCI error.

Don’t know if this is “good” to use the old u-boot file, but it seems to be working without any issues. Maybe someone who has more glue, what is inside this bin file and tell what in regards of xhci could have changed, can have a look at it?

(I also read somewhere, there may be a possible bug in u-boot - But as there is no newer version in the stable firmware channel from rpi-eeprom-update than the 11.01.2023 i can not tell if this can be the source of the issue - maybe i will try to get a firmware from beta branch and see if this issue still occurs)

Greetings

In CU172 u-boot was upgraded from version 2021.07 to 2022.10 combined with arm trusted firmware being upgraded from version 2.6 to 2.7

Maybe you should raise a bug for this.

1 Like

Hi @wiesel - Are you still seeing this issue? Of did other core updates help?

Hi @jon

as the Pi 4 is currently in the housing center and active since i installed it with 173 and the old u-boot image back then (and no IPFire updates were installed since then), i can’t say anything new on this topic.
And i have no Pi 4 here anymore to be able to test it - But i will try to get one more Pi 4 (as i will need it anyways to test how an update on the one in the housing center will go) and see how it is working today and get back to you.