mnt-reform: uboot remove x86 dependency

This commit is contained in:
Jakob Leifhelm 2025-11-08 10:53:01 +01:00
parent 9fbdc8cbdb
commit 20baaa0d68
No known key found for this signature in database
GPG key ID: 6817AA0238100822
3 changed files with 10 additions and 23 deletions

View file

@ -3,23 +3,9 @@
uboot,
fetchFromGitHub,
}:
# script from https://source.mnt.re/reform/reform-rk3588-uboot/-/blob/b530d65f4a878c0329a594fa248ba8da59d2e05f/build.sh
# script from https://source.mnt.re/reform/reform-rk3588-uboot/-/blob/28289e36cd1cb90b302780e83b014250c880c4ec/build.sh
runCommand "mnt-reform-firmware-rk3855${uboot.variant}" { } ''
mkdir $out
cp -r ${uboot} u-boot
cp -r ${uboot.rkbin} rkbin
chmod -R +rw u-boot
chmod -R +rw rkbin
cd u-boot
mkdir spl
mv u-boot-spl.bin spl
../rkbin/tools/boot_merger rock5b-rk3588.ini
cd ..
# rkbin stuff
cd rkbin
./tools/boot_merger RKBOOT/RK3588MINIALL.ini
# concatenate
cd ..
cp u-boot/idbloader.img $out/mnt-reform2-rk3588${uboot.variant}-flash.bin
dd if=u-boot/u-boot.itb of=$out/mnt-reform2-rk3588${uboot.variant}-flash.bin seek=16320
cp ${uboot}/idbloader.img $out/rk3588-mnt-reform2${uboot.variant}-flash.bin
dd if=${uboot}/u-boot.itb of=$out/rk3588-mnt-reform${uboot.variant}-flash.bin seek=16320
''

View file

@ -215,7 +215,7 @@
eval $(partx $img -o START,SECTORS --nr 1 --pairs)
dd conv=notrunc if=${content} of=$img seek=$START count=$SECTORS
dd conv=notrunc if=${firmware}/mnt-reform2-rk3588-dsi-flash.bin of=$img seek=64
dd conv=notrunc if=${firmware}/rk3588-mnt-reform2-dsi-flash.bin of=$img seek=64
if test -n "$compressImage"; then
zstd -T$NIX_BUILD_CORES --rm $img

View file

@ -10,14 +10,14 @@ let
domain = "source.mnt.re";
owner = "reform";
repo = "reform-rk3588-uboot";
rev = "55bca0174e7bb449e96028d64ad8348f5af35977";
hash = "sha256-A3u1afGK65cGOwENQtu8Hh+fLsSDNxc3rEebkd3QOic=";
rev = "28289e36cd1cb90b302780e83b014250c880c4ec";
hash = "sha256-fWGyC+rlfL0NYYRFLvdF7EiO3s9GfFkfhAbTEM5ECAM=";
};
rkbin = fetchFromGitHub {
owner = "rockchip-linux";
repo = "rkbin";
rev = "f43a462e7a1429a9d407ae52b4745033034a6cf9";
hash = "sha256-geESfZP8ynpUz/i/thpaimYo3kzqkBX95gQhMBzNbmk=";
rev = "272136301989d493000425935bd4ead0ef04d06b";
hash = "sha256-qXnuZyFNc6gYTkAtPg1t9WHwj8OiTxOLvsHUuvolK/w=";
};
in
buildUBoot rec {
@ -32,6 +32,7 @@ buildUBoot rec {
patches = [
"${mntPatches}/0001-ini-ddrbin-bump.patch"
"${mntPatches}/0002-add-target-init-mnt-reform-series.patch"
"${mntPatches}/0003-scripts-dtc-pylibfdt-libfdt-i_shipped-Use-SWIG_AppendOutp.patch"
];
prePatch = ''
cp ${mntPatches}/*.dts arch/arm/dts/
@ -45,7 +46,7 @@ buildUBoot rec {
"spl/u-boot-spl.bin"
];
variant = "-dsi";
defconfig = "mnt-reform2-rk3588${variant}_defconfig";
defconfig = "rk3588-mnt-reform2${variant}_defconfig";
extraMakeFlags = [
"BL31=${armTrustedFirmwareRK3588}/bl31.elf"
"ROCKCHIP_TPL=${rkbin}/bin/rk35/rk3588_ddr_lp4_2112MHz_lp5_2400MHz_v1.18.bin"