···
filesToInstall = ["u-boot.bin"];
501
-
rkbin = fetchFromGitHub {
502
-
owner = "ayufan-rock64";
504
-
rev = "f79a708978232a2b6b06c2e4173c5314559e0d3a";
505
-
sha256 = "0h7xm4ck3p3380c6bqm5ixrkxwcx6z5vysqdwvfa7gcqx5d6x5zz";
500
+
ubootRock64 = buildUBoot {
defconfig = "rock64-rk3328_defconfig";
510
-
platforms = [ "aarch64-linux" ];
511
-
license = lib.licenses.unfreeRedistributableFirmware;
502
+
extraMeta.platforms = [ "aarch64-linux" ];
BL31="${armTrustedFirmwareRK3328}/bl31.elf";
514
-
filesToInstall = [ "u-boot.itb" "idbloader.img"];
515
-
# Derive MAC address from cpuid
516
-
# Submitted upstream: https://patchwork.ozlabs.org/patch/1203686/
518
-
CONFIG_MISC_INIT_R=y
520
-
# Close to being blob free, but the U-Boot TPL causes random memory
523
-
./tools/mkimage -n rk3328 -T rksd -d ${rkbin}/rk33/rk3328_ddr_786MHz_v1.13.bin idbloader.img
524
-
cat spl/u-boot-spl.bin >> idbloader.img
504
+
filesToInstall = [ "u-boot.itb" "idbloader.img" "u-boot-rockchip.bin" ];
507
+
# A special build with much lower memory frequency (666 vs 1600 MT/s) which
508
+
# makes ROCK64 V2 boards stable. This is necessary because the DDR3 routing
509
+
# on that revision is marginal and not uncoditionally stable at the specified
510
+
# frequency. If your ROCK64 is unstable you can try this u-boot variant to
511
+
# see if it works better for you. The only disadvantage is lowered memory
513
+
ubootRock64v2 = buildUBoot {
515
+
substituteInPlace arch/arm/dts/rk3328-rock64-u-boot.dtsi \
516
+
--replace rk3328-sdram-lpddr3-1600.dtsi rk3328-sdram-lpddr3-666.dtsi
518
+
defconfig = "rock64-rk3328_defconfig";
519
+
extraMeta.platforms = [ "aarch64-linux" ];
520
+
BL31="${armTrustedFirmwareRK3328}/bl31.elf";
521
+
filesToInstall = [ "u-boot.itb" "idbloader.img" "u-boot-rockchip.bin" ];
ubootRockPro64 = buildUBoot {