Journal: Debian Bookworm build for MangoPI quad H616

2024-01-04T05:00:00Z

I am starting this thread so that efforts to produce a running bookworm Debian image can be journaled and logged. Please feel free to step in and offer any input you feel may be of interest. Unfortunately, there appears to be very little forthcoming from the developer or vendor of these boards, so, so far at least, we seem to be on our own. A kernel build on the updated MangoPi failed, so I am currently building one on a Raspberry Pi 4G.

I performed a standard upgrade which resulted in:

bracka@MangoPi:~$ hostnamectl
Static hostname: MangoPi
Icon name: computer
Machine ID: 72220208b82d41a89e94c2e17deeba01
Boot ID: 144b3305e0be4adbabec81e2008ff454
Operating System: Debian GNU/Linux 12 (bookworm)
Kernel: Linux 5.16.17-sun50iw9
Architecture: arm64

The working U-Boot is dated:
U-Boot SPL 2021.10-orangepi (Oct 05 2022 - 14:25:44 +0800)

The kernel should be:
Linux 6.1.31-sun50iw9

Booting from the OrangePi image that seems to have been the source results in:

U-Boot SPL 2021.07-orangepi (Sep 07 2023 - 17:38:50 +0800)
DRAM:This DRAM setup is currently not supported.

resetting …

link from Frontesque (January 3)

  • Thanks!

Does anybody have thoughts on where to put this stuff?

Tony

I was recently looking into porting the most recent orangepi build to the mq-quad as a starting point. I replaced the /boot partition with no such luck. Not sure what the difference is in the boot sequence, but I’ll keep looking.

I looked up the details of U-Boot and have the complete kit for it, but decided to go after low hanging fruit first. I did not use your image since I had already simply done the upgrade of the existing piece of bloatware, and since I’m using a 32G microSD, I have lots of room to play.

It looks like the standard build system wants to be some kind of 64 bit X86 with a cross compiler. When I get far enough into this I’ll set up some kind of shared storage. Ideally, once this is all done it would be great to build a distribution from scratch, possibly ARMbian since it seems to have a better user support community.

I have both boot directories - BIG differences - one is 52 files, the other is 93. This is the U-Boot stuff I was talking about … U-Boot is the Universal Bootloader. Once I get the new kernel up, I’ll checkpoint what I’ve done and make a detailed entry here. For now, the kernel build is still running, but at least no errors this time (so far).

If you already have a place for me to push it, I can drop my files up there for you, otherwise it’ll have to wait until I get set up. From my build directory on my Pi 4B

bracka@pi4b-flirc:~/build $ pwd ; date ; ls -l
/home/bracka/build
Thu 04 Jan 2024 04:42:09 PM EST
total 436660
-rw-r–r-- 1 bracka bracka 33640363 Jan 4 13:33 boot-5.16.17-sun50iw9.tar.gz
-rw-r–r-- 1 bracka bracka 34148044 Jan 4 13:33 boot-6.1.31-sun50iw9.tar.gz
drwxr-xr-x 27 bracka bracka 4096 Jan 4 14:47 linux-source-6.1
-rw-r–r-- 1 bracka bracka 197886 Jan 4 13:32 MangoPi-.config
-rw-r–r-- 1 bracka bracka 137497796 Jan 4 13:33 MangoPi-linux-source-6.1.tar.xz
-rw-r–r-- 1 bracka bracka 241644783 Jan 4 13:35 u-boot.tar.gz

bracka@pi4b-flirc:~/build $ tar tzvf boot-5.16.17-sun50iw9.tar.gz | wc -l
93
bracka@pi4b-flirc:~/build $ tar tzvf boot-6.1.31-sun50iw9.tar.gz | wc -l
52

Step 1 is to create and boot Debian 11 from a microSD card

The first thing is to create a bootable microSD card. From what I can tell, there appears to be only 1 option, that being to create IMG with XFCE, and the only working link is MEGA. The links pertaining to “Baidu” dont seem to work, or at least I don’t understand or trust how to make them work (I am not loading a program that I don’t understand).

The first problem encountered is that most if not all of the documentation is written in an oriental language that I do not understand. It is located here:

MQ-Quad H616 Mainline Kernel Compilation and Debugging Records (u-boot, kernel, buildroot)
https://bbs.aw-ol.com/topic/2054/mq-quad-h616-主线内核编译调试记录-u-boot-kernel-buildroot?lang=en-US

So, we’ll go through the steps to work with what we have and understand. The only bootable image so far is from the official web page and is again uploaded from a web site whose primary language is oriental.

https://mangopi.org/mqquad

The only Debian uploads that work seem to be Mega and the source code. This gets you an image called::
1506-nogpu.img.gz

  1. Burn the OS image onto a suitable microSD and boot. This is a Debian release with XFCE. Using Raspberry Pi imager, we can write this to a microUSB and boot. I am using an Adafruit PiUART on the GPIO as a serial console.

Orange Pi 3.0.8 Bullseye ttyS0

orangepizero2 login: orangepi
Password:
. . .
Welcome to Orange Pi 3.0.8 Bullseye with Linux 5.16.17-sun50iw9

System load: 2% Up time: 37 min
Memory usage: 34% of 983M IP:
CPU temp: 51°C Usage of /: 14% of 29G

Configured profile sync daemon.
orangepi@orangepizero2:~$ hostnamectl
Static hostname: orangepizero2
Icon name: computer
Machine ID: 72220208b82d41a89e94c2e17deeba01
Boot ID: 207a9a550bb64ce6a752d11054977d85
Operating System: Orange Pi 3.0.8 Bullseye
Kernel: Linux 5.16.17-sun50iw9
Architecture: arm64

orangepi@orangepizero2:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 11 (bullseye)
Release: 11
Codename: bullseye

orangepi@orangepizero2:~$ uname -mrs
Linux 5.16.17-sun50iw9 aarch64

orangepi@orangepizero2:~$ cat /etc/debian_version
11.6

The initial password is orangepi - change it!

  1. Run: sudo orangepi-config to set up a WiFi network

  2. Get up to date on all software releases. Now we should have an up to date Bullseye system with a ton of bloatware, but it is otherwise workable. I also choose to load cockpit at this time.

orangepi@orangepizero2:~$ history
7 sudo orangepi-config
8 sudo apt update -y
9 sudo ifconfig -a
10 sudo apt update -y
11 sudo apt upgrade -y
12 sudo apt install -y cockpit
13 sudo systemctl enable cockpit.socket

orangepi@orangepizero2:~$ sudo reboot

Here is what we end up with (note bloatware) …

orangepi@orangepizero2:~$ hostnamectl
Static hostname: orangepizero2
Icon name: computer
Machine ID: 72220208b82d41a89e94c2e17deeba01
Boot ID: b14d708550b241f58999f880d23e0268
Operating System: Debian GNU/Linux 11 (bullseye)
Kernel: Linux 5.16.17-sun50iw9
Architecture: arm64

orangepi@orangepizero2:~$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 422M 0 422M 0% /dev
tmpfs 99M 892K 98M 1% /run
/dev/mmcblk1p1 29G 4.4G 24G 16% /
tmpfs 492M 0 492M 0% /dev/shm
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 492M 8.0K 492M 1% /tmp
/dev/zram1 49M 21M 25M 45% /var/log
tmpfs 99M 48K 99M 1% /run/user/1000

orangepi@orangepizero2:~$ free -h
total used free shared buff/cache available
Mem: 983Mi 338Mi 332Mi 1.0Mi 313Mi 574Mi
Swap: 491Mi 0B 491Mi

orangepi@orangepizero2:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 11 (bullseye)
Release: 11
Codename: bullseye

orangepi@orangepizero2:~$ uname -mrs
Linux 5.16.17-sun50iw9 aarch64

orangepi@orangepizero2:~$ cat /etc/debian_version
11.8

The following is a log of the U-Boot activation as distributed, up to the point where the kernel is invoked. We will need this information later as a cold boot from power up of an upgraded SD card failed using standard procedures I will document later.

With the updated image, we don’t even see an attempt to boot.

U-Boot SPL 2021.10-orangepi (Apr 15 2023 - 14:55:25 +0800)
pmic id is 0x4b
DRAM: 1024 MiB
Trying to boot from MMC1
NOTICE: BL31: v2.7(debug):ea7aee20
NOTICE: BL31: Built : 04:47:26, Oct 3 2022
NOTICE: BL31: Detected Allwinner H616 SoC (1823)
NOTICE: BL31: Found U-Boot DTB at 0x4a082610, model: OrangePi Zero2
INFO: ARM GICv2 driver initialized
INFO: Configuring SPC Controller
INFO: PMIC: Probing AXP305 on RSB
ERROR: RSB: set run-time address: 0x10003
INFO: Could not init RSB: -65539
INFO: BL31: Platform setup done
INFO: BL31: Initializing runtime services
INFO: BL31: cortex_a53: CPU workaround for 855873 was applied
INFO: BL31: cortex_a53: CPU workaround for 1530924 was applied
INFO: PSCI: Suspend is unavailable
INFO: BL31: Preparing for EL3 exit to normal world
INFO: Entry point address = 0x4a000000
INFO: SPSR = 0x3c9
INFO: Changed devicetree.

U-Boot 2021.10-orangepi (Apr 15 2023 - 14:55:25 +0800) Allwinner Technology

CPU: Allwinner H616 (SUN50I)
Model: OrangePi Zero2
I2C: ready
DRAM: 1 GiB
MMC: mmc@4020000: 0
Loading Environment from FAT… Unable to use mmc 0:1… In: serial@5000000
Out: serial@5000000
Err: serial@5000000
Net: phy interface7
Could not get PHY for ethernet@5020000: addr 1
No ethernet found.

Autoboot in 1 seconds, press to stop
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1…
Found U-Boot script /boot/boot.scr
3566 bytes read in 3 ms (1.1 MiB/s)

Executing script at 4fc00000

U-boot loaded from SD
Boot script loaded from mmc
158 bytes read in 3 ms (50.8 KiB/s)
38726 bytes read in 7 ms (5.3 MiB/s)
4203 bytes read in 8 ms (512.7 KiB/s)
Applying kernel provided DT fixup script (sun50i-h616-fixup.scr)

Executing script at 45000000

10524405 bytes read in 440 ms (22.8 MiB/s)
22398984 bytes read in 931 ms (22.9 MiB/s)
Moving Image from 0x40080000 to 0x40200000, end=417c0000

Loading init Ramdisk from Legacy Image at 4ff00000 …

Image Name: uInitrd
Image Type: AArch64 Linux RAMDisk Image (gzip compressed)
Data Size: 10524341 Bytes = 10 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum … OK

Flattened Device Tree blob at 4fa00000

Booting using the fdt blob at 0x4fa00000
Loading Ramdisk to 495f6000, end 49fff6b5 … OK
Loading Device Tree to 0000000049584000, end 00000000495f5fff … OK

Starting kernel …

Loading, please wait…
Starting version 247.3-7+deb11u1
. . .

Step 2 is to upgrade the microUSB card to bookworm (Debian 12)

see the following for how to upgrade:
How to upgrade Debian 11 to Debian 12 bookworm using CLI

19 sudo sed -i ‘s/bullseye/bookworm/g’ /etc/apt/sources.list
20 cat /etc/apt/sources.list
21 sudo apt update -y
22 sudo apt upgrade --without-new-pkgs -y
23 sudo apt full-upgrade -y
34 sudo reboot
39 sudo apt autoremove -y

orangepi@MangoPi:~$ cat /etc/apt/sources.list
deb Index of /debian/ | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror bookworm main contrib non-free
#deb-src Index of /debian/ | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror bookworm main contrib non-free

deb Index of /debian/ | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror bookworm-updates main contrib non-free
#deb-src Index of /debian/ | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror bookworm-updates main contrib non-free

deb Index of /debian/ | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror bookworm-backports main contrib non-free
#deb-src Index of /debian/ | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror bookworm-backports main contrib non-free

deb http://mirrors.tuna.tsinghua.edu.cn/debian-security bookworm-security main contrib non-free
#deb-src http://mirrors.tuna.tsinghua.edu.cn/debian-security bookworm-security main contrib non-free

This took hours and I messed up the documentation. I will see what I can find or I may rerun it. For now, I’ll just document the fallout. Please not that we have the correct version of Debian, but we do not (yet) report a correct kernel. At some point I also renamed the machine to MangoPi

orangepi@MangoPi:~$ hostnamectl
Static hostname: MangoPi
Icon name: computer
Machine ID: 72220208b82d41a89e94c2e17deeba01
Boot ID: e0840b6af37c4c66aac3705b09babe33
Operating System: Debian GNU/Linux 12 (bookworm)
Kernel: Linux 5.16.17-sun50iw9
Architecture: arm64

orangepi@MangoPi:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 12 (bookworm)
Release: 12
Codename: bookworm

orangepi@MangoPi:~$ uname -mrs
Linux 5.16.17-sun50iw9 aarch64

orangepi@MangoPi:~$ cat /etc/debian_version
12.4

… and the bloat continues!

orangepi@MangoPi:~$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 422M 0 422M 0% /dev
tmpfs 99M 908K 98M 1% /run
/dev/mmcblk1p1 29G 6.2G 23G 22% /
tmpfs 492M 0 492M 0% /dev/shm
tmpfs 5.0M 16K 5.0M 1% /run/lock
tmpfs 492M 8.0K 492M 1% /tmp
/dev/zram1 47M 29M 15M 66% /var/log
tmpfs 99M 48K 99M 1% /run/user/1000

are you using the default orangepi_zero2_defconfig provided with u-boot or have you made your own? Just started looking into the u-boot project as I’ve never heard of it before. looks neat.

So far everything is straight vanilla as shipped. I pulled a copy of both the standard OrangePi Zero 2W bookworm minimal image and the MangoPi’s working ‘/boot’ directory. All I have done with them so far is to tar them up and compare number of files. I am trying to document everything as I go.

I followed some instructions on how to build and apply a kernel, but unfortunately lost the link. It may have actually built a useable kernel since I saw the installation procedure update some stuff in U-Boot when I applied it, but I made a bad assumption due to a faulty console and assumed the result did not boot so I trashed it. I may have been wrong, and of course could not log it due to the faulty console. My next attempt, however, ran a lot quicker and failed spectacularly. I have built a new kernel with the original configuration and all defaults for any new features.

Just working on checkpointing the current status at this time. Sick of burning the same microSD over and over …

Step 2(B) minor correction to updated image

After building the image and booting I noticed that the service smartmontools was failing to start with an error due to no SMART enabled devices being on the system. I disabled the service as there likely never will be a SMART device attached. This probably shouldn’t be an error, but we DO want to boot clean …

bracka@MangoPi:~$ systemctl disable smartmontools

bracka@MangoPi:~$ systemctl status smartmontools.service
? smartmontools.service - Self Monitoring and Reporting Technology (SMART) Daem>
Loaded: loaded (/lib/systemd/system/smartmontools.service; disabled; prese>
Active: inactive (dead)
Docs: man:smartd(8)
man:smartd.conf(5)

The above steps get us about as far as we can get without starting to reverse engineer stuff and generating our own custom release. It would be great if somebody in charge of this product chimed in and at least gave us some sort of update regarding Debian Bookworm and this board, even if it is to say that there is no support.

Current Status of Kernel

An up to date image from an OrangePi Zero 2W shows the following:

orangepi@iroquois:~$ hostnamectl
Static hostname: iroquois
Icon name: computer
Machine ID: e1af5f93623b43d58c0567fea31978a8
Boot ID: 290602f979cc4bae924b4d59b7c7be3a
Operating System: Debian GNU/Linux 12 (bookworm)
Kernel: Linux 6.1.31-sun50iw9
Architecture: arm64

The same from a MangoPi shows:

orangepi@MangoPi:/$ hostnamectl
Static hostname: MangoPi
Icon name: computer
Machine ID: 72220208b82d41a89e94c2e17deeba01
Boot ID: 8d3a21d1f5f74d76805ae06d7de62dc6
Operating System: Debian GNU/Linux 12 (bookworm)
Kernel: Linux 5.16.17-sun50iw9
Architecture: arm64

This indicates that we need to build and update a revised kernel for bookworm. The rest of the packages seem to have been updated, but there is no sense performing a comparison until this is up to date. Of note is that I also attempted a full ARMbian build but this failed to boot. More on that later. I also pulled down the kernel sources and compiled them, but the resulting image also did not boot.

Current status of Boot Image (u-boot)

On the latest OrangePi build we see:the following at the start of boot on the console:

U-Boot SPL 2021.07-orangepi (Sep 07 2023 - 17:38:50 +0800)
DRAM: 2048 MiB
Trying to boot from MMC1
NOTICE: BL31: v2.9(debug):8e31faa0
NOTICE: BL31: Built : 19:54:29, Jul 3 2023
NOTICE: BL31: Detected Allwinner H616 SoC (1823)
NOTICE: BL31: Found U-Boot DTB at 0x4a082790, model: OrangePi Zero2 W
INFO: ARM GICv2 driver initialized
INFO: Configuring SPC Controller
INFO: PMIC: Probing AXP305 on RSB
ERROR: RSB: set run-time address: 0x10003
INFO: Could not init RSB: -65539
INFO: BL31: Platform setup done
INFO: BL31: Initializing runtime services
INFO: BL31: cortex_a53: CPU workaround for 855873 was applied
INFO: BL31: cortex_a53: CPU workaround for 1530924 was applied
INFO: PSCI: Suspend is unavailable
INFO: BL31: Preparing for EL3 exit to normal world
INFO: Entry point address = 0x4a000000
INFO: SPSR = 0x3c9
INFO: Changed devicetree.

U-Boot 2021.07-orangepi (Sep 07 2023 - 17:38:50 +0800) Allwinner Technology

CPU: Allwinner H616 (SUN50I)
Model: OrangePi Zero2 W
I2C: ready
DRAM: 2 GiB
MMC: mmc@4020000: 0
Loading Environment from FAT… Unable to use mmc 0:1… In: serial@5000000
Out: serial@5000000
Err: serial@5000000
Net: No ethernet found.
starting USB…
No working controllers found
Autoboot in 1 seconds, press to stop
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1…
Found U-Boot script /boot/boot.scr

When I look at the same output using the only available image for the MangoPi (updated), I see:

U-Boot SPL 2021.10-orangepi (Apr 15 2023 - 14:55:25 +0800)
pmic id is 0x4b
DRAM: 1024 MiB
Trying to boot from MMC1
NOTICE: BL31: v2.7(debug):ea7aee20
NOTICE: BL31: Built : 04:47:26, Oct 3 2022
NOTICE: BL31: Detected Allwinner H616 SoC (1823)
NOTICE: BL31: Found U-Boot DTB at 0x4a082610, model: OrangePi Zero2
INFO: ARM GICv2 driver initialized
INFO: Configuring SPC Controller
INFO: PMIC: Probing AXP305 on RSB
ERROR: RSB: set run-time address: 0x10003
INFO: Could not init RSB: -65539
INFO: BL31: Platform setup done
INFO: BL31: Initializing runtime services
INFO: BL31: cortex_a53: CPU workaround for 855873 was applied
INFO: BL31: cortex_a53: CPU workaround for 1530924 was applied
INFO: PSCI: Suspend is unavailable
INFO: BL31: Preparing for EL3 exit to normal world
INFO: Entry point address = 0x4a000000
INFO: SPSR = 0x3c9
INFO: Changed devicetree.

U-Boot 2021.10-orangepi (Apr 15 2023 - 14:55:25 +0800) Allwinner Technology

CPU: Allwinner H616 (SUN50I)
Model: OrangePi Zero2
I2C: ready
DRAM: 1 GiB
MMC: mmc@4020000: 0
Loading Environment from FAT… Unable to use mmc 0:1… In: serial@5000000
Out: serial@5000000
Err: serial@5000000
Net: phy interface7
Could not get PHY for ethernet@5020000: addr 1
No ethernet found.

Autoboot in 1 seconds, press to stop
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1…
Found U-Boot script /boot/boot.scr

If I attempt to boot the MangoPi from the OrangePi image I get a clear failure from u-boot that indicates that it refuses to recognize the memory configuration.

U-Boot SPL 2021.10-orangepi (Aug 09 2022 - 21:00:00 +0800)
DRAM:This DRAM setup is currently not supported.

resetting …

I get a similar result when I attempt the ARMbian image I built, but notice the updated build date:and version number. This happens on both the OrangePi and the MangoPi.

U-Boot SPL 2024.01-rc5-armbian (Jan 13 2024 - 14:12:33 +0000)
DRAM:This DRAM setup is currently not supported.

resetting …

Directory tree for each working boot

OrangePi

orangepi@iroquois:~$ sort -k6 OrangePi.list
drwxr-xr-x root/root 0 2024-01-17 06:27 boot/
-rw-r–r-- root/root 0 2023-09-07 07:17 boot/.next
lrwxrwxrwx root/root 0 2023-09-07 07:17 boot/Image → vmlinuz-6.1.31-sun50iw9
-rw-r–r-- root/root 3472604 2023-09-07 05:39 boot/System.map-6.1.31-sun50iw9
-rw-rw-r-- root/root 230456 2023-09-07 07:18 boot/boot.bmp
-rw-rw-r-- root/root 3564 2023-09-07 07:17 boot/boot.cmd
-rw-rw-r-- root/root 3636 2023-09-07 07:19 boot/boot.scr
-rw-r–r-- root/root 206693 2023-09-07 05:39 boot/config-6.1.31-sun50iw9
lrwxrwxrwx root/root 0 2023-09-07 07:17 boot/dtb → dtb-6.1.31-sun50iw9
drwxr-xr-x root/root 0 2023-09-07 07:17 boot/dtb-6.1.31-sun50iw9/
drwxr-xr-x root/root 0 2023-09-07 07:17 boot/dtb-6.1.31-sun50iw9/allwinner/
drwxr-xr-x root/root 0 2023-09-07 07:17 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/
-rw-r–r-- root/root 321 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-disable-leds.dtbo
-rw-r–r-- root/root 228 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-disable-uart0.dtbo
-rwxr-xr-x root/root 4203 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-fixup.scr
-rw-r–r-- root/root 222 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-gpu.dtbo
-rw-r–r-- root/root 339 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ir.dtbo
-rw-r–r-- root/root 614 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ph-i2c1.dtbo
-rw-r–r-- root/root 452 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ph-i2c2.dtbo
-rw-r–r-- root/root 452 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ph-i2c3.dtbo
-rw-r–r-- root/root 452 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ph-i2c4.dtbo
-rw-r–r-- root/root 222 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ph-pwm12.dtbo
-rw-r–r-- root/root 344 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ph-pwm34.dtbo
-rw-r–r-- root/root 462 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ph-uart2.dtbo
-rw-r–r-- root/root 462 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-ph-uart5.dtbo
-rw-r–r-- root/root 712 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-i2c0.dtbo
-rw-r–r-- root/root 344 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-i2c1.dtbo
-rw-r–r-- root/root 564 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-i2c2.dtbo
-rw-r–r-- root/root 439 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-pwm1.dtbo
-rw-r–r-- root/root 439 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-pwm2.dtbo
-rw-r–r-- root/root 439 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-pwm3.dtbo
-rw-r–r-- root/root 439 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-pwm4.dtbo
-rw-r–r-- root/root 462 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-uart2.dtbo
-rw-r–r-- root/root 462 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-uart3.dtbo
-rw-r–r-- root/root 462 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-pi-uart4.dtbo
-rw-r–r-- root/root 619 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-spi0-spidev.dtbo
-rw-r–r-- root/root 871 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-spi1-cs0-cs1-spidev.dtbo
-rw-r–r-- root/root 706 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-spi1-cs0-spidev.dtbo
-rw-r–r-- root/root 706 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-spi1-cs1-spidev.dtbo
-rw-r–r-- root/root 608 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-usb0-host.dtbo
-rw-r–r-- root/root 285 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/overlay/sun50i-h616-zero2w-disable-led.dtbo
-rw-r–r-- root/root 40638 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/sun50i-h616-orangepi-zero2.dtb
-rw-r–r-- root/root 40618 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/sun50i-h616-orangepi-zero2w.dtb
-rw-r–r-- root/root 39931 2023-09-07 05:39 boot/dtb-6.1.31-sun50iw9/allwinner/sun50i-h616-orangepi-zero3.dtb
-rw-r–r-- root/root 12055797 2024-01-15 23:43 boot/initrd.img-6.1.31-sun50iw9
-rwxrwxr-x root/root 1152056 2023-09-07 07:18 boot/logo.bmp
-rw-rw-r-- root/root 205 2024-01-17 06:27 boot/orangepiEnv.txt
-rw-rw-r-- root/root 1542 2023-09-07 07:18 boot/orangepi_first_run.txt.template
lrwxrwxrwx root/root 0 2024-01-15 23:43 boot/uInitrd → uInitrd-6.1.31-sun50iw9
-rw-r–r-- root/root 12055861 2024-01-15 23:43 boot/uInitrd-6.1.31-sun50iw9
-rw-r–r-- root/root 9367960 2023-09-07 05:39 boot/vmlinuz-6.1.31-sun50iw9

MangoPi

orangepi@iroquois:~$ sort -k6 MangoPi.list
drwxr-xr-x root/root 0 2024-01-15 10:58 boot/
-rw-r–r-- root/root 0 2023-04-15 03:01 boot/.next
lrwxrwxrwx root/root 0 2023-04-15 03:01 boot/Image → vmlinuz-5.16.17-sun50iw9
-rw-r–r-- root/root 4590398 2023-04-15 02:58 boot/System.map-5.16.17-sun50iw9
-rw-r–r-- root/root 230456 2023-04-15 03:02 boot/boot.bmp
-rw-r–r-- root/root 3494 2023-04-15 03:00 boot/boot.cmd
-rw-rw-r-- root/root 3566 2023-04-15 03:04 boot/boot.scr
-rw-r–r-- root/root 197886 2023-04-15 02:58 boot/config-5.16.17-sun50iw9
lrwxrwxrwx root/root 0 2023-04-15 03:01 boot/dtb → dtb-5.16.17-sun50iw9
drwxr-xr-x root/root 0 2023-04-15 03:01 boot/dtb-5.16.17-sun50iw9/
drwxr-xr-x root/root 0 2023-04-15 03:01 boot/dtb-5.16.17-sun50iw9/allwinner/
drwxr-xr-x root/root 0 2023-04-15 03:01 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/
-rw-r–r-- root/root 3998 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/README.sun50i-a64-overlays
-rw-r–r-- root/root 4737 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/README.sun50i-h5-overlays
-rw-r–r-- root/root 3821 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-fixup.scr
-rw-r–r-- root/root 794 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-i2c0.dtbo
-rw-r–r-- root/root 496 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-i2c1.dtbo
-rw-r–r-- root/root 2364 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-pine64-7inch-lcd.dtbo
-rw-r–r-- root/root 778 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-pps-gpio.dtbo
-rw-r–r-- root/root 1173 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-spi-add-cs1.dtbo
-rw-r–r-- root/root 668 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-spi-jedec-nor.dtbo
-rw-r–r-- root/root 792 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-spi-spidev.dtbo
-rw-r–r-- root/root 506 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-uart1.dtbo
-rw-r–r-- root/root 963 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-uart2.dtbo
-rw-r–r-- root/root 804 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-uart3.dtbo
-rw-r–r-- root/root 963 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-uart4.dtbo
-rw-r–r-- root/root 777 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-a64-w1-gpio.dtbo
-rw-r–r-- root/root 339 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-analog-codec.dtbo
-rw-r–r-- root/root 384 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-cir.dtbo
-rw-r–r-- root/root 477 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-cpu-clock-1.0GHz-1.1v.dtbo
-rw-r–r-- root/root 477 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-cpu-clock-1.2GHz-1.3v.dtbo
-rw-r–r-- root/root 897 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-cpu-clock-1.3GHz-1.3v.dtbo
-rw-r–r-- root/root 4191 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-fixup.scr
-rw-r–r-- root/root 1020 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-gpio-regulator-1.3v.dtbo
-rw-r–r-- root/root 374 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-i2c0.dtbo
-rw-r–r-- root/root 374 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-i2c1.dtbo
-rw-r–r-- root/root 374 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-i2c2.dtbo
-rw-r–r-- root/root 778 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-pps-gpio.dtbo
-rw-r–r-- root/root 862 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-pwm.dtbo
-rw-r–r-- root/root 1040 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-spdif-out.dtbo
-rw-r–r-- root/root 1177 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-spi-add-cs1.dtbo
-rw-r–r-- root/root 804 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-spi-jedec-nor.dtbo
-rw-r–r-- root/root 788 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-spi-spidev.dtbo
-rw-r–r-- root/root 502 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-uart1.dtbo
-rw-r–r-- root/root 794 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-uart2.dtbo
-rw-r–r-- root/root 798 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-uart3.dtbo
-rw-r–r-- root/root 504 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-usbhost0.dtbo
-rw-r–r-- root/root 504 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-usbhost1.dtbo
-rw-r–r-- root/root 504 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-usbhost2.dtbo
-rw-r–r-- root/root 504 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-usbhost3.dtbo
-rw-r–r-- root/root 777 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h5-w1-gpio.dtbo
-rw-r–r-- root/root 3844 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-fixup.scr
-rw-r–r-- root/root 374 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-i2c0.dtbo
-rw-r–r-- root/root 374 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-i2c1.dtbo
-rw-r–r-- root/root 374 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-i2c2.dtbo
-rw-r–r-- root/root 671 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-pwm.dtbo
-rw-r–r-- root/root 268 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-ruart.dtbo
-rw-r–r-- root/root 1177 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-spi-add-cs1.dtbo
-rw-r–r-- root/root 804 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-spi-jedec-nor.dtbo
-rw-r–r-- root/root 808 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-spi-spidev.dtbo
-rw-r–r-- root/root 523 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-spi-spidev1.dtbo
-rw-r–r-- root/root 502 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-uart1.dtbo
-rw-r–r-- root/root 798 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-uart2.dtbo
-rw-r–r-- root/root 798 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-uart3.dtbo
-rw-r–r-- root/root 773 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h6-w1-gpio.dtbo
-rw-r–r-- root/root 4203 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-fixup.scr
-rw-r–r-- root/root 540 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-i2c1.dtbo
-rw-r–r-- root/root 378 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-i2c2.dtbo
-rw-r–r-- root/root 378 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-i2c3.dtbo
-rw-r–r-- root/root 378 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-i2c4.dtbo
-rw-r–r-- root/root 222 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-pwm12.dtbo
-rw-r–r-- root/root 344 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-pwm34.dtbo
-rw-r–r-- root/root 808 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-spi-spidev.dtbo
-rw-r–r-- root/root 387 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-uart2.dtbo
-rw-r–r-- root/root 509 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/overlay/sun50i-h616-uart5.dtbo
-rw-r–r-- root/root 43112 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-a64-orangepi-win.dtb
-rw-r–r-- root/root 32160 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h5-orangepi-pc2.dtb
-rw-r–r-- root/root 32061 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h5-orangepi-prime.dtb
-rw-r–r-- root/root 31329 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h5-orangepi-zero-plus.dtb
-rw-r–r-- root/root 31254 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h5-orangepi-zero-plus2.dtb
-rw-r–r-- root/root 37593 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h6-orangepi-3-lts.dtb
-rw-r–r-- root/root 37998 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h6-orangepi-3.dtb
-rw-r–r-- root/root 37599 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h6-orangepi-lite2.dtb
-rw-r–r-- root/root 37125 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h6-orangepi-one-plus.dtb
-rw-r–r-- root/root 38568 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h616-orangepi-zero2-b.dtb
-rw-r–r-- root/root 38572 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h616-orangepi-zero2-lts.dtb
-rw-r–r-- root/root 38726 2023-04-15 02:58 boot/dtb-5.16.17-sun50iw9/allwinner/sun50i-h616-orangepi-zero2.dtb
-rw-r–r-- root/root 11926409 2024-01-15 03:47 boot/initrd.img-5.16.17-sun50iw9
-rw-r–r-- root/root 207 2024-01-15 10:58 boot/orangepiEnv.txt
-rw-r–r-- root/root 1542 2023-04-15 03:03 boot/orangepi_first_run.txt.template
lrwxrwxrwx root/root 0 2024-01-15 03:47 boot/uInitrd → uInitrd-5.16.17-sun50iw9
-rw-r–r-- root/root 11926473 2024-01-15 03:47 boot/uInitrd-5.16.17-sun50iw9
-rw-r–r-- root/root 22398984 2023-04-15 02:58 boot/vmlinuz-5.16.17-sun50iw9

This is where this thread is going to end. We are still running an old u-boot and kernel, but everything else seems to have updated. Verified s follows:

orangepi@MangoPi:/$ hostnamectl
Static hostname: MangoPi
Icon name: computer
Machine ID: 72220208b82d41a89e94c2e17deeba01
Boot ID: 8d3a21d1f5f74d76805ae06d7de62dc6
Operating System: Debian GNU/Linux 12 (bookworm)
Kernel: Linux 5.16.17-sun50iw9
Architecture: arm64

orangepi@MangoPi:/$ uname -mrs
Linux 5.16.17-sun50iw9 aarch64

orangepi@MangoPi:/$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 12 (bookworm)
Release: 12
Codename: bookworm

orangepi@MangoPi:/$ cat /etc/debian_version
12.4

Building a new u-boot and kernel points us at:
MQ-Quad H616 Mainline Kernel Compilation and Debugging Records (u-boot, kernel, buildroot)

Will open up new threads as the investigation continues, unless @Frontesque gets there first. This one is probably already too long.

Cheers, Tony

The link you mentioned is interesting and might be a strong lead. I’ll have to take some time to look into it, though it seems fairly detailed. sadly, load times are atrocious on that site for me (in the united states)

Hold off. It is full of typos and stuff that doesn’t work. I managed to build everything (can send you my document offline) but not impressed. I had to do the kernel build in a Raspberry Pi because the MangoPi wedges. I followed the instructions for u-boot and get dead air or:

mangopi@MangoPi:~/upgrade$ sunxi-tools/sunxi-fel uboot u-boot-sunxi-with-spl.bin
ERROR: Allwinner USB FEL device not found!

Happy to share my work & findings. I am also going to post here when I get around to it. There are a few more sites. I also have a few orangepis so I can compare results there as well. Stay tuned or if you want to speed things up let me know where to send stuff. I have a WD Cloud I could share, but WD messed up the management interface. Open to suggestions.

I only have 2 rpis and the mq-quad, though I do have an Ampere server that I can do ARM64 based builds on. I’m willing to create build scripts to automate the process if you want, and I don’t mind hosting anything required on my build site.
@bracka

Hi @Frontesque

I placed my document (in progress) up on my iDrive which should be accessible by:

It should contain a document that translates the Chinese document into English and works through it. I also put the final upgrade of the original distribution there. I only have limited space with Apple, so let me know when you’ve pulled it down. I will also leave a file in there with my direct email address.

Because this is getting long winded and seems like a good place to park the “normal” bookworm build, I opened up a new log (discussion) for building the u-boot stuff and will probably do a third for the kernel.

Tony

Files are uploaded to iCloud. Let me know when you have them so that I can free up the space.

MangoPi-bookworm.tar.gz
Contains all of the uploaded source files and results of running their scripts.

MangoPi-bookworm.dump.gz
Contains a dump of the filesystem (standalone) after all the updates

MangoPi-bookworm.img.gz
Contains a dd of a 8GB microSD of the system after the upgrades

backup.tar.gz contains a couple of scripts to dump a filesystem for file level restores.
sudo apt install -y dump (to use the the backup scripts to a thumb drive)

Directory of C:\iCloudDrive\MangoPi

2024-01-26 12:23 AM .
2024-01-26 12:23 AM …
2024-01-26 12:23 AM 783 backup.tar.gz
2024-01-25 11:40 PM 50 email-address.txt
2024-01-25 09:17 PM 356,488 MangoPi Technical Notes.docx
2024-01-21 05:15 AM 1,850,417,043 MangoPi-bookworm.dump.gz
2024-01-21 05:24 AM 2,791,648,486 MangoPi-bookworm.img.gz
2024-01-26 01:07 AM 4,432,468,139 MangoPi-bookworm.tar.gz
6 File(s) 9,074,890,989 bytes
2 Dir(s) 100,840,382,464 bytes free