Re: Radxa Orion O6

From: FUKAUMI Naoki <naoki_at_radxa.com>
Date: Mon, 20 Jan 2025 21:22:50 UTC
Hi Andrew,

On 1/21/25 03:21, Andrew Turner wrote:
> Hello,
> 
>> On 19 Jan 2025, at 04:57, FUKAUMI Naoki <naoki@radxa.com> wrote:
>>
>> Hi,
>>
>> I'm trying to boot FreeBSD/arm64 on a Radxa Orion O6.
>>
>> UEFI has a "O/S Hardware Description Selection" menu where I can choose "Device Tree" or "ACPI". "ACPI" allows me to boot a mainline Linux kernel.
>>
>> With "ACPI" I can use the serial console with EFI loader, but the kernel output only shows up on the display after the kernel is loaded.
> 
> Without seeing the ACPI tables, especially the SPCR, it is difficult to know why it’s failing.

 From what I've seen so far, it seems there is no SPCR table, and I 
don't know how to display on the serial console in Linux.

>>
>> ----
>> Consoles: EFI console
>>     Reading loader env vars from /efi/freebsd/loader.env
>> Setting currdev to disk1p1:
>> FreeBSD/arm64 EFI loader, Revision 3.0
>> (Thu Jan 16 06:56:52 UTC 2025 root@releng3.nyi.freebsd.org)
>>
>>    Command line arguments: loader.efi
>>    Image base: 0x47ab5a000
>>    EFI version: 2.70
>>    EFI Firmware: EDK II (rev 1.00)
>>    Console: efi (0x1000)
>>    Load Path: \EFI\BOOT\BOOTAA64.EFI
>>    Load Device: VenHw(0D51905B-B77E-452A-A2C0-ECA0CC8D514A,00801D090000000000)/U
>> SB(0x1,0x0)/HD(1,GPT,009521E2-D3EE-11EF-81EA-0CC47AD8B808,0x22,0x10418)
>>    BootCurrent: 0003
>>    BootOrder: 0000 0001 0002 0003[*]
>>    BootInfo Path: VenHw(0D51905B-B77E-452A-A2C0-ECA0CC8D514A,00801D090000000000)
>> /USB(0x1,0x0)
>> Ignoring Boot0003: Only one DP found
>> Trying ESP: VenHw(0D51905B-B77E-452A-A2C0-ECA0CC8D514A,00801D090000000000)/USB(0
>> x1,0x0)/HD(1,GPT,009521E2-D3EE-11EF-81EA-0CC47AD8B808,0x22,0x10418)
>> Setting currdev to disk1p1:
>> Trying: VenHw(0D51905B-B77E-452A-A2C0-ECA0CC8D514A,00801D090000000000)/USB(0x1,0
>> x0)/HD(2,GPT,009521EB-D3EE-11EF-81EA-0CC47AD8B808,0x1043A,0x283540)
>> Setting currdev to disk1p2:
>> Loading /boot/defaults/loader.conf
>> Loading /boot/defaults/loader.conf
>> Loading /boot/device.hints
>> Loading /boot/loader.conf
>> Loading /boot/loader.conf.d/rtw8922a.conf
>> Loading /boot/loader.conf.d/rtw8851b.conf
>> Loading /boot/loader.conf.d/rtw8852c.conf
>> Loading /boot/loader.conf.d/rtw8703b.conf
>> Loading /boot/loader.conf.d/rtw8852b.conf
>> Loading /boot/loader.conf.d/rtw8723d.conf
>> Loading /boot/loader.conf.d/rtw8822c.conf
>> Loading /boot/loader.conf.d/rtw8821c.conf
>> Loading /boot/loader.conf.d/rtw8822b.conf
>> Loading /boot/loader.conf.d/rtw8852a.conf
>> Loading /boot/loader.conf.local
>> ?c/
>> -  ______               ____   _____ _____
>>   |  ____|             |  _ \ / ____|  __ \
>>   | |___ _ __ ___  ___ | |_) | (___ | |  | |
>>   |  ___| '__/ _ \/ _ \|  _ < \___ \| |  | |
>>   | |   | | |  __/  __/| |_) |____) | |__| |
>>   | |   | | |    |    ||     |      |      |
>>   |_|   |_|  \___|\___||____/|_____/|_____/
>>
>> /-------- Welcome to FreeBSD ----------\  ```                        `
>> |                                      | s` `.....---.......--.```   -/
>> |  1. Boot Installer [Enter]           | +o   .--`         /y:`      +.
>> |  2. Boot Single user                 |  yo`:.            :o      `+-
>> |  3. Escape to loader prompt          |   y/               -/`   -o/
>> |  4. Reboot                           |  .-                  ::/sy+:.
>> |  5. Cons: Serial                     |  /                     `--  /
>> |                                      | `:                          :`
>> |  Kernel:                             | `:                          :`
>> |  6. kernel (1 of 1)                  |  /                          /
>> |                                      |  .-                        -.
>> |  Options:                            |   --                      -.
>> |  7. Boot Options                     |    `:`                  `:`
>> |                                      |      .--             `--.
>> \--------------------------------------/         .---.....----.
>> Loading kernel...seconds. [Space] to pause
>> /boot/kernel/kernel text=0x318 text=0x99d0f8 text=0x2c9ca0 data=0x17f8e0 data=0x
>> 0+0x371000 0x8+0x16f1b8+0x8+0x19fc8a|
>> Loading configured modules...
>> can't find '/etc/hostid'
>> can't find '/boot/entropy'
>> Loading splash ok
>> No valid device tree blob found!
>> WARNING! Trying to fire up the kernel, but no device tree blob found!
>> EFI framebuffer information:
>> addr, size     0x84800000, 0x7e9000
>> dimensions     1920 x 1080
>> stride         1920
>> masks          0x00ff0000, 0x0000ff00, 0x000000ff, 0xff000000
>> ----
>>
>> Here is a screenshot on the display:
>> https://drive.google.com/file/d/1pa0Uv3FONpsyVyt3QfU_1CzRSYW2cita/view?usp=sharing
>>
>> Using the "Device Tree" I was able to use both the serial console and the display and boot the installer. Please see dmesg below.
>>
>> But all pcib are not configured.
> 
> It looks like the PCI driver doesn’t have memory resources assigned to it. If I remember correctly this should be described in the MCFG table, with a fallback to the value in _CBA. It’s possible something in this parsing is not picking up these so is failing.

In "Device Tree" mode, I guess we can't expect those.

Best regards,

--
FUKAUMI Naoki
Radxa Computer (Shenzhen) Co., Ltd.