Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mtd: afs: break out v1 footer magic to a define

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>

authored by

Linus Walleij and committed by
Brian Norris
9498440f 8cf98018

+3 -1
+3 -1
drivers/mtd/afs.c
··· 34 34 #include <linux/mtd/map.h> 35 35 #include <linux/mtd/partitions.h> 36 36 37 + #define AFSV1_FOOTER_MAGIC 0xA0FFFF9F 38 + 37 39 struct footer_v1 { 38 40 u32 image_info_base; /* Address of first word of ImageFooter */ 39 41 u32 image_start; /* Start of area reserved by this footer */ ··· 92 90 /* 93 91 * Does it contain the magic number? 94 92 */ 95 - if (fs.signature != 0xa0ffff9f) 93 + if (fs.signature != AFSV1_FOOTER_MAGIC) 96 94 ret = 0; 97 95 98 96 /*