summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorAntony Pavlov <antonynpavlov@gmail.com>2021-10-28 04:28:14 +0300
committerSascha Hauer <s.hauer@pengutronix.de>2021-11-01 10:05:22 +0100
commit9458a8d10086282613673ca3dabeb76735bce306 (patch)
tree1211f68de94781a3db0466669d6172600923f4b9 /common
parent5081ebbc5d1a9d67f0ed37d73610161d371c62f7 (diff)
downloadbarebox-9458a8d10086282613673ca3dabeb76735bce306.tar.gz
barebox-9458a8d10086282613673ca3dabeb76735bce306.tar.xz
imd: reuse imd_is_crc32()
Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Link: https://lore.barebox.org/20211028012816.929611-3-antonynpavlov@gmail.com Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'common')
-rw-r--r--common/imd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/common/imd.c b/common/imd.c
index e1d5733c6b..0295d84d34 100644
--- a/common/imd.c
+++ b/common/imd.c
@@ -317,7 +317,7 @@ static int imd_calculate_crc32(void *input, const struct imd_header *imd_start,
length = ALIGN(length, 4);
length += sizeof(struct imd_header);
- if (imd_read_type(imd) == IMD_TYPE_CRC32) {
+ if (imd_is_crc32(imd_read_type(imd))) {
*imd_crc = (struct imd_header *)imd;
debug("Found crc token at %d\n", end_ofs);
break;