X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=tools%2Fsocfpgaimage.c;h=7f83b50761f08c1771c431a60791060a41fe993b;hb=6915dcf35987d654b491524f151e56b91e0d0ec9;hp=652ae45f812db9b29d6b31dc7dce81840358b068;hpb=a93648d197df48fa46dd55f925ff70468bd81c71;p=u-boot diff --git a/tools/socfpgaimage.c b/tools/socfpgaimage.c index 652ae45f81..7f83b50761 100644 --- a/tools/socfpgaimage.c +++ b/tools/socfpgaimage.c @@ -1,8 +1,7 @@ +// SPDX-License-Identifier: GPL-2.0+ /* * Copyright (C) 2014 Charles Manning * - * SPDX-License-Identifier: GPL-2.0+ - * * Reference doc http://www.altera.com.cn/literature/hb/cyclone-v/cv_5400A.pdf * Note this doc is not entirely accurate. Of particular interest to us is the * "header" length field being in U32s and not bytes. @@ -33,6 +32,8 @@ #include "pbl_crc32.h" #include "imagetool.h" +#include "mkimage.h" + #include #define HEADER_OFFSET 0x40 @@ -133,12 +134,12 @@ static int verify_buffer(const uint8_t *buf) len = verify_header(buf + HEADER_OFFSET); if (len < 0) { - fprintf(stderr, "Invalid header\n"); + debug("Invalid header\n"); return -1; } if (len < HEADER_OFFSET || len > PADDED_SIZE) { - fprintf(stderr, "Invalid header length (%i)\n", len); + debug("Invalid header length (%i)\n", len); return -1; }