1 // SPDX-License-Identifier: GPL-2.0+
2 /*
3 * Image code used by host tools (and not boards)
4 *
5 * (C) Copyright 2008 Semihalf
6 *
7 * (C) Copyright 2000-2006
8 * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
9 */
10
11 #include <time.h>
12
memmove_wd(void * to,void * from,size_t len,ulong chunksz)13 void memmove_wd(void *to, void *from, size_t len, ulong chunksz)
14 {
15 memmove(to, from, len);
16 }
17
genimg_print_size(uint32_t size)18 void genimg_print_size(uint32_t size)
19 {
20 printf("%d Bytes = %.2f KiB = %.2f MiB\n", size, (double)size / 1.024e3,
21 (double)size / 1.048576e6);
22 }
23
genimg_print_time(time_t timestamp)24 void genimg_print_time(time_t timestamp)
25 {
26 printf("%s", ctime(×tamp));
27 }
28