The first candidate that catches my eye is the "Miami Zynq Lite" from Topic systems. This board has 512M of DDR memory (twice what I have) and uses NOR flash (my board uses NAND). My board has ethernet and this one does not. By no means an ideal match, but the Zynq chip is correct.
Another candidate is "bitmain_antminer_s9_defconfig", this specifies
CONFIG_ARCH_ZYNQ=y CONFIG_FPGA_ZYNQPL=y CONFIG_NAND_ZYNQ=y CONFIG_ZYNQ_GEM=y CONFIG_ZYNQ_SERIAL=ySo here we have NAND and the ethernet, so this looks like a better match. The ethernet is gigabit (mine only has a 100 Mbit PHY) and can have up to 1G of ram.
I did some searching looking for source for the zedboard U-boot and curiously one recommendation is to build U-boot for the zc702. Note however that the current zedboard uses an AC7Z020-CLG484 chip, not the XC7Z010-CLG400 that I have. The Zybo and MicroZed use the ZC7Z010-1CLG400C chip and would be better choices. There is a config file that lists these, "xilinx_zynq_virt_defconfig"
CONFIG_OF_LIST="zynq-zc702 zynq-zc706 zynq-zc770-xm010 zynq-zc770-xm011 zynq-zc770-xm011-x16 zynq-zc770-xm012 zynq-zc770-xm013 zynq-cc108 zynq-microzed zynq-minized zynq-picozed zynq-zed zynq-zturn zynq-zybo zynq-zybo-z7 zynq-dlc20-rev1.0"This is an interesting scheme I have never seen before. It would seem that this allows a bunch of common boards that are differentiated by their device tree files.
The Microzed has my xc7Z010 chip along with a network (10/100/1000), 1G of DRAM, 128M of QSPI flash, and a $200 price tab.
The Zybo is another $200 board, this time from Digilent.
The Zybo Z7-10 has my XC7Z010 chip, 1G of DRAM, gigabit ethernet, and 16M of QSPI flash.
None of these are a better match that the antminer S9, so I will build U-Boot for that.
# tjt -- added 1-31-2021 CROSS_COMPILE = arm-none-eabi-
make bitmain_antminer_s9_defconfig make V=1 >build.logThe build blows up with:
/usr/bin/ld: scripts/dtc/dtc-parser.tab.o:(.bss+0x10): multiple definition of `yylloc'; scripts/dtc/dtc-lexer.lex.o:(.bss+0x0): first defined here collect2: error: ld returned 1 exit status make[2]: *** [scripts/Makefile.host:106: scripts/dtc/dtc] Error 1 make[1]: *** [scripts/Makefile.build:432: scripts/dtc] Error 2 make: *** [Makefile:555: scripts] Error 2This is some kind of problem in script/dtc that perhaps I can sidestep for my purposes right now.
# tjt comments this out for now. #subdir-$(CONFIG_DTC) += dtcAnd we try again and get this error:
In file included from tools/aisimage.c:9: include/image.h:1101:12: fatal error: openssl/evp.h: No such file or directory 1101 | # includeThis looks like a missing dependency. I would need the libssl-dev package on some systems. I try openssl-devel on Fedora. Indeed, dnf install openssl-devel does the trick. Now it is busy for a while and ends with:| ^~~~~~~~~~~~~~~ compilation terminated.
/bin/sh: ./scripts/dtc/dtc: No such file or directory make[2]: *** [scripts/Makefile.lib:312: arch/arm/dts/bitmain-antminer-s9.dtb] Error 127 make[1]: *** [dts/Makefile:38: arch-dtbs] Error 2 make: *** [Makefile:1091: dts/dt.dtb] Error 2This is no doubt due to my commenting out the dtc business when I encountered the first error. However, when I look in the source tree, I see what I want, namely object files scattered around here and there. In particular, in the "drivers/fpga" directory, I find:
cd drivers/fpga ls -l *.o -rw-rw-r-- 1 tom tom 75612 Jan 31 14:52 built-in.o -rw-rw-r-- 1 tom tom 23616 Jan 31 14:52 fpga.o -rw-rw-r-- 1 tom tom 21524 Jan 31 14:52 xilinx.o -rw-rw-r-- 1 tom tom 34156 Jan 31 14:52 zynqpl.oWhich means I can restrict my attention to 3 files rather than puzzling over which of the 19 C source files in that directory are relevant. A mere 1000 lines of source code.
extern YYLTYPE yyloc;
This does not fix it, I now get even more errors:
/usr/bin/ld: scripts/dtc/dtc-parser.tab.o:(.bss+0x10): multiple definition of `yylloc'; scripts/dtc/dtc-lexer.lex.o:(.bss+0x0): first defined here /usr/bin/ld: scripts/dtc/dtc-parser.tab.o: in function `yyparse': dtc-parser.tab.c:(.text+0x5e3): undefined reference to `yyloc' /usr/bin/ld: dtc-parser.tab.c:(.text+0x616): undefined reference to `yyloc' /usr/bin/ld: dtc-parser.tab.c:(.text+0x61d): undefined reference to `yyloc' /usr/bin/ld: dtc-parser.tab.c:(.text+0x625): undefined reference to `yyloc' /usr/bin/ld: dtc-parser.tab.c:(.text+0x62c): undefined reference to `yyloc' /usr/bin/ld: scripts/dtc/dtc-parser.tab.o:dtc-parser.tab.c:(.text+0x6be): more undefined references to `yyloc' follow collect2: error: ld returned 1 exit status make[2]: *** [scripts/Makefile.host:106: scripts/dtc/dtc] Error 1 make[1]: *** [scripts/Makefile.build:432: scripts/dtc] Error 2This has something to do with a gcc setting -fno-common. The old setting used to allow multiple declarations of a common variable and viewed them as the same thing. Apparently the latest U-boot sources are fixed:
if the code you're referring to is U-Boot a fix went upstream and is in 2020.04
This isn't worth my time to sort out at this point ...
Tom's Computer Info / [email protected]