summaryrefslogtreecommitdiff
path: root/kexec/arch/arm/kexec-uImage-arm.c
diff options
context:
space:
mode:
Diffstat (limited to 'kexec/arch/arm/kexec-uImage-arm.c')
-rw-r--r--kexec/arch/arm/kexec-uImage-arm.c15
1 files changed, 2 insertions, 13 deletions
diff --git a/kexec/arch/arm/kexec-uImage-arm.c b/kexec/arch/arm/kexec-uImage-arm.c
index e881fd8..4875185 100644
--- a/kexec/arch/arm/kexec-uImage-arm.c
+++ b/kexec/arch/arm/kexec-uImage-arm.c
@@ -5,24 +5,13 @@
#include <string.h>
#include <sys/types.h>
#include <image.h>
+#include <kexec-uImage.h>
#include "../../kexec.h"
#include "kexec-arm.h"
int uImage_arm_probe(const char *buf, off_t len)
{
- struct image_header header;
-
- if ((uintmax_t)len < (uintmax_t)sizeof(header))
- return -1;
-
- memcpy(&header, buf, sizeof(header));
-
- if (cpu_to_be32(header.ih_magic) != IH_MAGIC)
- return -1;
-
- /* XXX: check CRC Checksum? */
-
- return 0;
+ return uImage_probe(buf, len, IH_ARCH_ARM);
}
int uImage_arm_load(int argc, char **argv, const char *buf, off_t len,