1 /* SPDX-License-Identifier: GPL-2.0+ */
14 * Verify the format of FIT header pointed to by ptr
16 * @ptr: image header to be verified
17 * @image_size: size of while image
18 * @params: mkimage parameters
19 * @return 0 if OK, -1 on error
21 int fit_verify_header(unsigned char *ptr
, int image_size
,
22 struct image_tool_params
*params
);
24 int fit_check_image_types(uint8_t type
);
27 * Map an FDT into memory, optionally increasing its size
29 * @cmdname: Tool name (for displaying with error messages)
30 * @fname: Filename containing FDT
31 * @size_inc: Amount to increase size by (0 = leave it alone)
32 * @blobp: Returns pointer to FDT blob
33 * @sbuf: File status information is stored here
34 * @delete_on_error: true to delete the file if we get an error
35 * @read_only: true to open in read-only mode
36 * @return 0 if OK, -1 on error.
38 int mmap_fdt(const char *cmdname
, const char *fname
, size_t size_inc
,
39 void **blobp
, struct stat
*sbuf
, bool delete_on_error
,
42 #endif /* _FIT_COMMON_H_ */