Break out the magic number to a #defined constant.
Cc: Ryan Harkin <ryan.harkin@linaro.org>
Cc: Liviu Dudau <liviu.dudau@arm.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
#include <linux/mtd/map.h>
#include <linux/mtd/partitions.h>
+#define AFSV1_FOOTER_MAGIC 0xA0FFFF9F
+
struct footer_v1 {
u32 image_info_base; /* Address of first word of ImageFooter */
u32 image_start; /* Start of area reserved by this footer */
/*
* Does it contain the magic number?
*/
- if (fs.signature != 0xa0ffff9f)
+ if (fs.signature != AFSV1_FOOTER_MAGIC)
ret = 0;
/*