summaryrefslogtreecommitdiffstats
path: root/recipes-bsp/reference-design
diff options
context:
space:
mode:
authorJason Wu <jason.wu.misc@gmail.com>2016-04-09 00:09:30 +1000
committerNathan Rossi <nathan@nathanrossi.com>2016-05-03 21:50:58 +1000
commit5066fef048366ced30a346e2dca67b009f0d32be (patch)
treed4dc4274b8a59d5c8b2edc4e93b79538213e0085 /recipes-bsp/reference-design
parent2cc62e42b062a6eef2664088b1b1bf4eac99074d (diff)
downloadmeta-xilinx-5066fef048366ced30a346e2dca67b009f0d32be.tar.gz
conf/machine: Add zybo-linux-bd-zynq7 machine support
* base on Zybo linux_bd reference design * Add device tree with required nodes * hdf is fetch from Digilent github Signed-off-by: Jason Wu <jason.wu.misc@gmail.com> Signed-off-by: Nathan Rossi <nathan@nathanrossi.com>
Diffstat (limited to 'recipes-bsp/reference-design')
-rw-r--r--recipes-bsp/reference-design/zybo-linux-bd.bb68
1 files changed, 68 insertions, 0 deletions
diff --git a/recipes-bsp/reference-design/zybo-linux-bd.bb b/recipes-bsp/reference-design/zybo-linux-bd.bb
new file mode 100644
index 00000000..9224d2d1
--- /dev/null
+++ b/recipes-bsp/reference-design/zybo-linux-bd.bb
@@ -0,0 +1,68 @@
1SUMMARY = "The reference design for zybo-linux-bd"
2DESCRIPTION = "Contains the Reference Design Files and hardware software \
3hand-off file. The HDF provides bitstream and Xilinx ps7_init_gpl.c/h \
4platform headers."
5SECTION = "bsp"
6DEPENDS += "unzip"
7
8LICENSE = "Proprietary"
9LIC_FILES_CHKSUM = "file://Projects/${HW_BD}/readme.txt;md5=e1cb7639bf00b6e730ff3a7f13714951"
10
11COMPATIBLE_MACHINE = "zybo-linux-bd-zynq7"
12
13HW_BD = "linux_bd"
14
15SRC_URI = "git://github.com/Digilent/ZYBO.git;protocol=https;nobranch=1"
16SRCREV = "63ca49fe027da49f3b0ac636bd404fd31fbbd945"
17
18PV = "+git${SRCPV}"
19
20S = "${WORKDIR}/git"
21
22HDF = "/Projects/${HW_BD}/hw_handoff/${HW_BD}_wrapper.hdf"
23
24S ?= "${WORKDIR}/${MACHINE}"
25
26PROVIDES = "virtual/bitstream virtual/zynq7-platform-init"
27
28PLATFORM_INIT ?= "ps7_init_gpl.c \
29 ps7_init_gpl.h"
30
31FILES_${PN}-platform-init += " \
32 ${PLATFORM_INIT_DIR}/ps7_init_gpl.c \
33 ${PLATFORM_INIT_DIR}/ps7_init_gpl.h \
34 "
35
36FILES_${PN}-bitstream += " \
37 download.bit \
38 "
39
40PACKAGES = "${PN}-platform-init ${PN}-bitstream"
41
42BITSTREAM ?= "bitstream-${PV}-${PR}.bit"
43
44PACKAGE_ARCH = "${MACHINE_ARCH}"
45
46inherit zynq7-platform-paths
47
48do_install() {
49 fn=$(unzip -l ${S}/${HDF} | awk '{print $NF}' | grep ".bit$")
50 unzip -o ${S}/${HDF} ${fn} -d ${D}
51 [ "${fn}" == "download.bit" ] || mv ${D}/${fn} ${D}/download.bit
52
53 install -d ${D}${PLATFORM_INIT_DIR}
54 for fn in ${PLATFORM_INIT}; do
55 unzip -o ${S}/${HDF} ${fn} -d ${D}${PLATFORM_INIT_DIR}
56 done
57}
58
59do_deploy () {
60 if [ -e ${D}/download.bit ]; then
61 install -d ${DEPLOY_DIR_IMAGE}
62 install -m 0644 ${D}/download.bit ${DEPLOY_DIR_IMAGE}/${BITSTREAM}
63 ln -sf ${BITSTREAM} ${DEPLOY_DIR_IMAGE}/download.bit
64 # for u-boot 2016.3 with spl load bitstream patch
65 ln -sf ${BITSTREAM} ${DEPLOY_DIR_IMAGE}/bitstream
66 fi
67}
68addtask deploy before do_build after do_install \ No newline at end of file