#include <mmc.h>
#include <fat.h>
#include <version.h>
+#include <image.h>
DECLARE_GLOBAL_DATA_PTR;
if (err == 0)
goto end;
+ if (image_get_magic(header) != IH_MAGIC)
+ return -1;
+
spl_parse_image_header(header);
/* convert size to sectors - round up */