diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2015-10-15 09:08:46 -0400 |
---|---|---|
committer | Brian Norris <computersforpeace@gmail.com> | 2015-11-10 20:56:06 -0500 |
commit | 9498440fff21649cabe529f1d9d4e3bc668fc125 (patch) | |
tree | fe619137b1978e0d0f8e876c69be34df1772c357 /drivers/mtd/afs.c | |
parent | 8cf980185d2bf672a5c1d03935f1f165836bb4b0 (diff) |
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>
Diffstat (limited to 'drivers/mtd/afs.c')
-rw-r--r-- | drivers/mtd/afs.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/mtd/afs.c b/drivers/mtd/afs.c index 9af00528586f..d09280ae12bd 100644 --- a/drivers/mtd/afs.c +++ b/drivers/mtd/afs.c | |||
@@ -34,6 +34,8 @@ | |||
34 | #include <linux/mtd/map.h> | 34 | #include <linux/mtd/map.h> |
35 | #include <linux/mtd/partitions.h> | 35 | #include <linux/mtd/partitions.h> |
36 | 36 | ||
37 | #define AFSV1_FOOTER_MAGIC 0xA0FFFF9F | ||
38 | |||
37 | struct footer_v1 { | 39 | struct footer_v1 { |
38 | u32 image_info_base; /* Address of first word of ImageFooter */ | 40 | u32 image_info_base; /* Address of first word of ImageFooter */ |
39 | u32 image_start; /* Start of area reserved by this footer */ | 41 | u32 image_start; /* Start of area reserved by this footer */ |
@@ -90,7 +92,7 @@ afs_read_footer_v1(struct mtd_info *mtd, u_int *img_start, u_int *iis_start, | |||
90 | /* | 92 | /* |
91 | * Does it contain the magic number? | 93 | * Does it contain the magic number? |
92 | */ | 94 | */ |
93 | if (fs.signature != 0xa0ffff9f) | 95 | if (fs.signature != AFSV1_FOOTER_MAGIC) |
94 | ret = 0; | 96 | ret = 0; |
95 | 97 | ||
96 | /* | 98 | /* |