Hi, I have managed to get output from the board using UART7 GPIO pins! My USB-UART adapter is not reliable at 1.5M baud, therefore I had to reduce the baudrate. However while I get output from the board, my inputs are silently ignored, eg. I can't type anything in the U-boot console. I suspect the &uart7m0_xfer is the issue but I can be wrong.
I have selected UART7, because UART1 is used by bluetooth, UART2 is not available on the GPIO pins (i found some RX/TX/GND marked testpads on the board, that might be that) and all other UARTs are muxed except UART7, so it seems to be a good alternative. My soldering skills are non-existent. The pinout ( https://file.geniatech.com/download/xpi/XPI-3566-ZERO_Specification_V1.4_EN.pdf )shows the following: PIN 36: UART7_RX_M2/ GPIO4_A3_d PIN 37: UART7_TX_M2/ GPIO4_A2_d Therefore I have tried to add &uart7m2_xfer { bootph-all; }; to rk356x-u-boot.dtsi but it didn't made any difference. I probably miss some tiny details somewhere, but I can't seem to find it. I would greatly appreciate any help. Thank You! My current patchset: --- a/arch/arm/dts/rk3568-generic.dts +++ b/arch/arm/dts/rk3568-generic.dts - stdout-path = "serial2:1500000n8"; + stdout-path = "serial7:112500n8"; (....) -&uart2 { +&uart7 { status = "okay"; --- a/arch/arm/dts/rk356x-u-boot.dtsi +++ b/arch/arm/dts/rk356x-u-boot.dtsi @@ -161,12 +161,12 @@ u-boot,spl-sfc-no-dma; }; -&uart2 { +&uart7 { bootph-all; clock-frequency = <24000000>; }; -&uart2m0_xfer { +&uart7m2_xfer { bootph-all; }; --- a/configs/generic-rk3568_defconfig +++ b/configs/generic-rk3568_defconfig @@ -9,7 +9,8 @@ CONFIG_ROCKCHIP_SPI_IMAGE=y -CONFIG_DEBUG_UART_BASE=0xFE660000 +CONFIG_DEBUG_UART_BASE=0xfe6b0000 -CONFIG_BAUDRATE=1500000 +CONFIG_BAUDRATE=112500 I get the following output: U-Boot SPL 2025.04-rc2-g9b35357b95e3-dirty (Feb 15 2025 - 18:46:05 +0000) Trying to boot from MMC1 ## Checking hash(es) for config config-1 ... OK ## Checking hash(es) for Image atf-1 ... sha256+ OK ## Checking hash(es) for Image u-boot ... sha256+ OK ## Checking hash(es) for Image fdt-1 ... sha256+ OK ## Checking hash(es) for Image atf-2 ... sha256+ OK ## Checking hash(es) for Image atf-3 ... sha256+ OK ## Checking hash(es) for Image atf-4 ... sha256+ OK ## Checking hash(es) for Image atf-5 ... sha256+ OK ## Checking hash(es) for Image atf-6 ... sha256+ OK INFO: Preloader serial: 7 NOTICE: BL31: v2.3():v2.3-645-g8cea6ab0b:cl, fwver: v1.44 NOTICE: BL31: Built : 16:36:43, Sep 19 2023 INFO: GICv3 without legacy support detected. INFO: ARM GICv3 driver initialized in EL3 INFO: pmu v1 is valid 220114 INFO: l3 cache partition cfg-0 INFO: dfs DDR fsp_param[0].freq_mhz= 920MHz INFO: dfs DDR fsp_param[1].freq_mhz= 324MHz INFO: dfs DDR fsp_param[2].freq_mhz= 528MHz INFO: dfs DDR fsp_param[3].freq_mhz= 780MHz INFO: Using opteed sec cpu_context! INFO: boot cpu mask: 0 INFO: BL31: Initializing runtime services WARNING: No OPTEE provided by BL2 boot loader, Booting device without OPTEE initialization. SMC`s destined for OPTEE will return SMC_UNK ERROR: Error initializing runtime service opteed_fast INFO: BL31: Preparing for EL3 exit to normal world INFO: Entry point address = 0xa00000 INFO: SPSR = 0x3c9 U-Boot 2025.04-rc2-g9b35357b95e3-dirty (Feb 15 2025 - 18:46:05 +0000) Model: Generic RK3566/RK3568 SoC: RK3566 DRAM: 2 GiB Core: 249 devices, 23 uclasses, devicetree: separate MMC: mmc@fe2b0000: 1, mmc@fe310000: 0 Loading Environment from nowhere... OK In: serial@fe6b0000 Out: serial@fe6b0000 Err: serial@fe6b0000 Hit any key to stop autoboot: 0 Scanning for bootflows in all bootdevs Seq Method State Uclass Part Name Filename --- ----------- ------ -------- ---- ------------------------ ---------------- Scanning global bootmeth 'efi_mgr': Card did not respond to voltage select! : -110 Cannot persist EFI variables without system partition Missing RNG device for EFI_RNG_PROTOCOL 0 efi_mgr ready (none) 0 <NULL> ** Booting bootflow '<NULL>' with efi_mgr Loading Boot0000 'mmc 0' failed EFI boot manager: Cannot load any image Boot failed (err=-14) Scanning bootdev '[email protected]': Card did not respond to voltage select! : -110 Scanning bootdev '[email protected]': Unknown uclass 'nvme' in label Unknown uclass 'scsi' in label Unknown uclass 'pxe' in label Unknown uclass 'dhcp' in label No more bootdevs --- ----------- ------ -------- ---- ------------------------ ---------------- (1 bootflow, 1 valid) => On Mon, 8 Apr 2024 21:31:28 +0200 Jonas Karlman <[email protected]> wrote: > Hi Z, > > On 2024-04-08 09:40, Mizsei Zoltán wrote: > > Hi, > > > > I'm trying to get a mainline U-Boot running on the Geniatech XPI-3566-ZERO > > RK3566 based SBC [1], but all my attempts have failed so far. > > > > The SBC doesn't have any SD-Card slot, please keep this in mind! > > > > I can build U-Boot, but when I write the resulting binary to the eMMC using > > rkdeveloptool, the boot stops and I see no output on the UART pins using > > 1500000 baud transfer rate. > > > > My steps were the following: > > > > - git clone https://github.com/u-boot/u-boot > > - cd u-boot > > - CROSS_COMPILE=aarch64-linux-gnu- ARCH=arm64 make rk3568_defconfig > > There is no rk3568_defconfig target but generic-rk3568_defconfig may work > better. > > > - ROCKCHIP_TPL='rkbin/bin/rk35/rk3566_ddr_1056MHz_v1.21.bin' > > BL31='rkbin/bin/rk35/rk3568_bl31_v1.44.elf' > > CROSS_COMPILE=aarch64-linux-gnu- make > > - rkdeveloptool db MiniLoaderAll.bin > > - rkdeveloptool wl 64 u-boot-rockchip.bin > > > > After that I can no longer communicate with the board via UART and it no > > longer boots. > > After looking at the specification for this board it looks like GPIO pin 8 > and 10 is connected to uart1 and not uart2 that is typically used for debug > uart on rockchip devices. > > > > > I've built uboot countless times, I've followed all sorts of guides, I've > > tried modifying FDT and transplanting the DTS from the official SDK, I have > > tried vanilla defconfigs and tried to modify them aswell, I think I've > > tried everything, but no matter what I do I just can't get it working. > > The vendored U-Boot works ok, but I plant to run OpenBSD, for which an > > upstream U-Boot would be better situated (according to the OBSD mailing > > list). > > > > Please give me some hints because I'm running out of ideas. I've spent > > countless hours trying to get this to work but haven't succeeded. > > You can try changing stdout-path to "serial1:1500000n8" and enable the uart1 > node in generic-rk3568.dts. > Also change to CONFIG_DEBUG_UART_BASE=0xFE650000, and also use rkbin > tools/ddrbin_tool and change to use uart1 on ddr bin. > > After that you should probably start seeing something on uart and that may > help you get a little bit further. > > Regards, > Jonas > > > > > Thank You very much! > > > > Best Regards, > > > > --Z-- > > > > [1] https://www.geniatech.com/product/xpi-3566-zero/ > -- MIZSEI Zoltán <[email protected]>

