summaryrefslogtreecommitdiff
path: root/include/fpga.h
diff options
context:
space:
mode:
authorMichal Simek <michal.simek@xilinx.com>2014-05-02 14:09:30 +0200
committerMichal Simek <michal.simek@xilinx.com>2014-05-20 15:23:46 +0200
commit7a78bd2679ce3287cfc44f69fd7bc554d0261cf6 (patch)
tree34a48a2e9594920abe2d4c68386869a7f9506744 /include/fpga.h
parent64e809afeaf1572c3246a5bca198a77d0498fd89 (diff)
fpga: Define bitstream type based on command selection
Clean up partial, full and compressed bitstream handling. U-Boot supports full bitstream loading and partial based on detection which is not 100% correct. Extending fpga_load/fpga_loadbitstream() with one more argument which stores bitstream type. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Diffstat (limited to 'include/fpga.h')
-rw-r--r--include/fpga.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/include/fpga.h b/include/fpga.h
index 15e603a169d..a55e49f9589 100644
--- a/include/fpga.h
+++ b/include/fpga.h
@@ -36,12 +36,18 @@ typedef struct { /* typedef fpga_desc */
} fpga_desc; /* end, typedef fpga_desc */
+typedef enum {
+ BIT_FULL = 0,
+} bitstream_type;
+
/* root function definitions */
extern void fpga_init(void);
extern int fpga_add(fpga_type devtype, void *desc);
extern int fpga_count(void);
-extern int fpga_load(int devnum, const void *buf, size_t bsize);
-extern int fpga_loadbitstream(int devnum, char *fpgadata, size_t size);
+extern int fpga_load(int devnum, const void *buf, size_t bsize,
+ bitstream_type bstype);
+extern int fpga_loadbitstream(int devnum, char *fpgadata, size_t size,
+ bitstream_type bstype);
extern int fpga_dump(int devnum, const void *buf, size_t bsize);
extern int fpga_info(int devnum);
extern const fpga_desc *const fpga_validate(int devnum, const void *buf,