Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Radxa Zero 3W/E - edge - switch to mainline uboot 2024.10 #7411

Merged
merged 2 commits into from
Nov 3, 2024

Conversation

mr-toolcraft
Copy link
Contributor

Description

Use latest mainline u-boot tag instead of fork.
Needs to be tested by somebody with 3W model on hand as well.

GitHub issue reference:
Jira reference number [AR-9999]

How Has This Been Tested?

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules

@Kwiboo
Copy link
Contributor

Kwiboo commented Oct 28, 2024

Great, all/most of my U-Boot rk3xxx work has been merged upstream and is included in v2024.10.

You can possible also change/merge post_family_config__radxa-zero3_use_vendor_uboot to also use v2024.10, that old radxa rk35xx-2024.01 branch seem to be based on my obsolete rk35xx-2024.01-branch.

Copy link
Collaborator

@ColorfulRhino ColorfulRhino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice to slowly but surely see most boards use the latest mainline U-Boot!

You can very likely remove BOOTFS_TYPE (it's ext4 by default), like most other rk35xx boards.

Also agree with Kwiboo's statements, can be done like here to replace the ...branch_vendor and ...branch_edge functions:

# Mainline U-Boot
function post_family_config__nanopi_r6s_use_mainline_uboot() {
display_alert "$BOARD" "Using mainline U-Boot for $BOARD / $BRANCH" "info"
declare -g BOOTDELAY=1 # Wait for UART interrupt to enter UMS/RockUSB mode etc
declare -g BOOTSOURCE="https://github.com/u-boot/u-boot.git" # We ❤️ Mainline U-Boot
declare -g BOOTBRANCH="tag:v2024.10"
declare -g BOOTPATCHDIR="v2024.10"
# Don't set BOOTDIR, allow shared U-Boot source directory for disk space efficiency
declare -g UBOOT_TARGET_MAP="BL31=${RKBIN_DIR}/${BL31_BLOB} ROCKCHIP_TPL=${RKBIN_DIR}/${DDR_BLOB};;u-boot-rockchip.bin"
# Disable stuff from rockchip64_common; we're using binman here which does all the work already
unset uboot_custom_postprocess write_uboot_platform write_uboot_platform_mtd
# Just use the binman-provided u-boot-rockchip.bin, which is ready-to-go
function write_uboot_platform() {
dd "if=$1/u-boot-rockchip.bin" "of=$2" bs=32k seek=1 conv=notrunc status=none
}
}

BOOTDELAY is not needed.

config/boards/radxa-zero3.csc Outdated Show resolved Hide resolved
@mr-toolcraft
Copy link
Contributor Author

mr-toolcraft commented Oct 30, 2024

BOOTDELAY is not needed.

But it doesn't hurt either ;)

Personally I'd go step by step changing edge uboot and then a bit later adapt other branches too.

@Kwiboo
Copy link
Contributor

Kwiboo commented Oct 30, 2024

Personally I'd go step by step changing edge uboot and then a bit later adapt other branches too.

I only wanted to make aware that both vendor and edge is using a mainline based U-Boot and a switch for both may be easy, I am not an Armbian user/developer so I do not know. The vendor-version is an older mainline based version (v2024.01) that contains bugs that has been fixed in newer versions (v2024.07+).

However, the vendor-version use a single device tree / fdtfile for both 3E/3W and mainline Linux/U-Boot use two different device trees where U-Boot automatically detect and set correct fdtfile.

Copy link
Member

@igorpecovnik igorpecovnik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was reported on Discord that 3W also works.

@igorpecovnik igorpecovnik added Ready to merge Reviewed, tested and ready for merge 11 Milestone: Fourth quarter release labels Nov 3, 2024
@igorpecovnik igorpecovnik merged commit 5dd1cd6 into armbian:main Nov 3, 2024
8 of 10 checks passed
@defencedog
Copy link
Collaborator

Personally I'd go step by step changing edge uboot and then a bit later adapt other branches too.

I only wanted to make aware that both vendor and edge is using a mainline based U-Boot and a switch for both may be easy, I am not an Armbian user/developer so I do not know. The vendor-version is an older mainline based version (v2024.01) that contains bugs that has been fixed in newer versions (v2024.07+).

However, the vendor-version use a single device tree / fdtfile for both 3E/3W and mainline Linux/U-Boot use two different device trees where U-Boot automatically detect and set correct fdtfile.

@Kwiboo can you please share links to 3E fdt file

@Kwiboo
Copy link
Contributor

Kwiboo commented Nov 3, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
11 Milestone: Fourth quarter release Ready to merge Reviewed, tested and ready for merge
Development

Successfully merging this pull request may close these issues.

5 participants