summaryrefslogtreecommitdiff
path: root/common/bootm.c
diff options
context:
space:
mode:
authorMichal Simek <michal.simek@xilinx.com>2016-05-17 14:03:50 +0200
committerMichal Simek <michal.simek@xilinx.com>2016-05-24 13:17:59 +0200
commit62afc601883e788f3f22291202d5b2a23c1a8b06 (patch)
treec5d12c83cb1f46ed08de698494885de63f2f329a /common/bootm.c
parentb733c278d7adc48c71bd06faf359db3d9e385185 (diff)
image: Add boot_get_fpga() to load fpga with bootm
Add function boot_get_fpga() which find and load bitstream to programmable logic if fpga entry is present. Function is supported on Xilinx devices for full and partial bitstreams in BIN and BIT format. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Remove additional blankline in image.h
Diffstat (limited to 'common/bootm.c')
-rw-r--r--common/bootm.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/common/bootm.c b/common/bootm.c
index c965326db4..49414142dc 100644
--- a/common/bootm.c
+++ b/common/bootm.c
@@ -246,6 +246,16 @@ int bootm_find_images(int flag, int argc, char * const argv[])
#endif
#if IMAGE_ENABLE_FIT
+#if defined(CONFIG_FPGA) && defined(CONFIG_FPGA_XILINX)
+ /* find bitstreams */
+ ret = boot_get_fpga(argc, argv, &images, IH_ARCH_DEFAULT,
+ NULL, NULL);
+ if (ret) {
+ printf("FPGA image is corrupted or invalid\n");
+ return 1;
+ }
+#endif
+
/* find all of the loadables */
ret = boot_get_loadable(argc, argv, &images, IH_ARCH_DEFAULT,
NULL, NULL);