From 08c7dd1bd4b3a59c0d57b3ce4fe5ba1a90123685 Mon Sep 17 00:00:00 2001 From: Daniel Axtens Date: Wed, 15 Mar 2017 23:37:35 +1100 Subject: crypto: powerpc - Re-enable non-REFLECTed CRCs When CRC32c was included in the kernel, Anton ripped out the #ifdefs around reflected polynomials, because CRC32c is always reflected. However, not all CRCs use reflection so we'd like to make it optional. Restore the REFLECT parts from Anton's original CRC32 implementation (https://github.com/antonblanchard/crc32-vpmsum) That implementation is available under GPLv2+, so we're OK from a licensing point of view: https://github.com/antonblanchard/crc32-vpmsum/blob/master/LICENSE.TXT As CRC32c requires REFLECT, add that #define. Cc: Anton Blanchard Signed-off-by: Daniel Axtens Signed-off-by: Herbert Xu --- arch/powerpc/crypto/crc32c-vpmsum_asm.S | 1 + 1 file changed, 1 insertion(+) (limited to 'arch/powerpc/crypto/crc32c-vpmsum_asm.S') diff --git a/arch/powerpc/crypto/crc32c-vpmsum_asm.S b/arch/powerpc/crypto/crc32c-vpmsum_asm.S index c0d080caefc1..d2bea48051a0 100644 --- a/arch/powerpc/crypto/crc32c-vpmsum_asm.S +++ b/arch/powerpc/crypto/crc32c-vpmsum_asm.S @@ -842,4 +842,5 @@ .octa 0x00000000000000000000000105ec76f1 #define CRC_FUNCTION_NAME __crc32c_vpmsum +#define REFLECT #include "crc32-vpmsum_core.S" -- cgit v1.2.3-59-g8ed1b