diff options
author | Atsushi Nemoto <atsushi.nemoto@sord.co.jp> | 2018-09-21 09:19:13 +0900 |
---|---|---|
committer | Marek Vasut <marex@denx.de> | 2018-10-03 12:56:50 +0200 |
commit | 0ca8fd37ae86726747d5dd96f915967eceb64691 (patch) | |
tree | b2c6c24553c85a2af20c444ae620889a772d31e5 /tools/socfpgaimage.c | |
parent | 86d56a5da5b2d50879c1ea955c8e1eed5d27fa7d (diff) |
tools: socfpga: fix sfp_verify_header
Fix sfp_verify_header to return correct version number.
This fixes "Not a sane SOCFPGA preloader" error message with v1 header.
Signed-off-by: Atsushi Nemoto <atsushi.nemoto@sord.co.jp>
Diffstat (limited to 'tools/socfpgaimage.c')
-rw-r--r-- | tools/socfpgaimage.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/socfpgaimage.c b/tools/socfpgaimage.c index 390c9bb402..72d8b96f54 100644 --- a/tools/socfpgaimage.c +++ b/tools/socfpgaimage.c @@ -191,6 +191,7 @@ static int sfp_verify_header(const uint8_t *buf, uint8_t *ver) if (hdr_csum != sfp_csum) return -EINVAL; + *ver = header_v0.version; return img_len; } |