The information on this page is migrating to the FreeBSD wiki at http://wiki.freebsd.org/FreeBSD/arm/Zedboard.
Download: freebsd-zedboard-102013.img.gz. It's about 120MB.
These are md5 sums for the image:
MD5 (freebsd-zedboard-102013.img) = bc5c0bb8760b553b89a37c1a98bc5d82 MD5 (freebsd-zedboard-102013.img.gz) = cbed15703f196955297b3af99b91f767Uncompress and copy the image to the SD card. On my machine, the SD card shows up as /dev/da0. Be sure that is the same on your machine before cut and pasting this.
# gunzip freebsd-zedboard-102013.img.gz # dd if=freebsd-zedboard-102013.img of=/dev/da0 bs=32768
Power down the Zedboard. Insert the SD card in the SD slot and be sure the Zedboard's configuration mode jumpers are set for booting from SD card before powering up. (If you've already been booting the Linux image from the SD card shipped with the Zedboard, this shouldn't need to change.)
The USB-UART connected to connect J14 acts as the FreeBSD console (device uart1). This is the same console as the stock Linux image. The Zedboard should automatically boot U-boot and then the FreeBSD kernel. This version of U-boot I built from slightly modified sources provided by Xilinx. I modified the default environment a bit and enabled the U-boot API which I think I'll need for booting with ubldr at some point. (XXX: I should provide diffs.)
The FreeBSD kernel has drivers for the UARTs, SDIO, Gig Ethernet, and a USB host driver for the USB OTG connected at J13. There is also a GPIO driver which allows reading of switches and buttons and controlling the LEDs.
Note: I've enabled setting the date via ntp. If you are not in North America, you might want to modify the ntp hosts setting (ntpdate_hosts) in /etc/rc.conf.
Note2: This image incorporates some bug-fixes to the gig ethernet driver that haven't made it to -CURRENT. This is the patch I used: patch.txt
Please send any feedback to me via E-mail
A couple things are not in the FreeBSD source. One is the changes I made to Xilinx' u-boot to support ubldr. I describe that below.
The other is a small utility that displays the FreeBSD logo on the Zedboard's OLED display. The source for that is here.
I also have a Perforce project branch at freebsd.org: //depot/user/skibo/skibo_zynq.
Here's how I create the SD image from the source.
make TARGET_ARCH=armv6 KERNCONF=ZEDBOARD MALLOC_PRODUCTION=y WITH_GCC=y WITH_GNUCXX=y buildworld buildkernel
dd if=/dev/zero of=SDCARD.img count=1048576 mdconfig -f SDCARD.img -u 0 gpart create -s MBR md0 gpart add -s64m -t \!14 md0 gpart set -a active -i 1 md0 newfs_msdos -F 16 /dev/md0s1 gpart add -t freebsd md0 gpart create -s BSD md0s2 gpart add -t freebsd-ufs md0s2 newfs /dev/md0s2a tunefs -n enable /dev/md0s2a
mkdir /mnt/boot /mnt/armroot mount -t msdosfs /dev/md0s1 /mnt/boot mount /dev/md0s2a /mnt/armroot
make TARGET_ARCH=armv6 KERNCONF=ZEDBOARD DESTDIR=/mnt/armroot installworld distribution installkernelDownload and extract these files: extrafiles.tgz. (MD5 (extrafiles.tgz) = d0f1042efec86d06caa2b04cc88774d9)
Copy these files to the boot partition:
cp BOOT.BIN ubldr /mnt/boot cp zedboard.dtb /mnt/boot/board.dtb
mkdir /mnt/armroot/mnt/boot cp rc.conf fstab /mnt/armroot/etc
This fun program displays FreeBSD on the OLED display on boot-up:
mkdir /mnt/armroot/usr/local/bin /mnt/armroot/usr/local/etc /mnt/armroot/usr/local/etc/rc.d cp oled_logo /mnt/armroot/usr/local/bin cp oleddisp /mnt/armroot/usr/local/etc/rc.d
umount /mnt/boot umount /mnt/armroot mdconfig -d -u 0
dd if=SDCARD.img of=/dev/da0 bs=32768
The official repository for Xilinx port of u-boot to Zynq is on github at here.
I created a new configuration very close to zynq_zed but with the necessary API additions to allow ubldr to work with it. To recompile u-boot add this file, zynq_freebsd.h, to directory include/configs and add a couple lines for zynq_freebsd and microzed_freebsd to boards.cfg:
zynq_afx_qspi arm armv7 zynq xilinx zynq zynq_afx:AFX_QSPI zynq_afx_nand arm armv7 zynq xilinx zynq zynq_afx:AFX_NAND zynq_zc70x arm armv7 zynq xilinx zynq +zynq_freebsd arm armv7 zynq xilinx zynq +microzed_freebsd arm armv7 zynq xilinx zynq zynq_freebsd:SDRAM_1G zynq_zed arm armv7 zynq xilinx zynq omap5_uevm arm armv7 omap5_uevm ti omap5 dra7xx_evm arm armv7 dra7xx ti omap5