From: oliver@schinagl.nl Date: Fri, 25 Nov 2016 15:30:31 +0000 (+0100) Subject: tools: Allow crc8 to be used X-Git-Tag: v2017.03-rc2~10^2~12 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=1d3c5392396726915558e95e08947e44d994d9bb;p=u-boot tools: Allow crc8 to be used This patch enables crc8 to be used from within the tools directory using u-boot/crc.h. Signed-off-by: Olliver Schinagl Reviewed-by: Joe Hershberger Signed-off-by: Olliver Schinagl --- diff --git a/include/u-boot/crc.h b/include/u-boot/crc.h index 754ac729ce..6764d58bab 100644 --- a/include/u-boot/crc.h +++ b/include/u-boot/crc.h @@ -9,6 +9,9 @@ #ifndef _UBOOT_CRC_H #define _UBOOT_CRC_H +/* lib/crc8.c */ +unsigned int crc8(unsigned int crc_start, const unsigned char *vptr, int len); + /* lib/crc32.c */ uint32_t crc32 (uint32_t, const unsigned char *, uint); uint32_t crc32_wd (uint32_t, const unsigned char *, uint, uint); diff --git a/tools/Makefile b/tools/Makefile index f5ac6313e1..5e089c957e 100644 --- a/tools/Makefile +++ b/tools/Makefile @@ -196,6 +196,7 @@ fdtgrep-objs += $(LIBFDT_OBJS) fdtgrep.o # that won't build on some weird host compiler -- though there are lots of # exceptions for files that aren't complaint. HOSTCFLAGS_crc32.o := -pedantic +HOSTCFLAGS_crc8.o := -pedantic HOSTCFLAGS_md5.o := -pedantic HOSTCFLAGS_sha1.o := -pedantic HOSTCFLAGS_sha256.o := -pedantic