diff options
author | Krzysztof Kozlowski <krzk@kernel.org> | 2018-07-17 18:05:37 +0200 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2018-07-27 19:04:33 +0800 |
commit | e37f2f93afe594682702439ca34eb8130598cdf2 (patch) | |
tree | 7a732e598720bc519788034b13c1cfcb2fa44361 /lib/gen_crc32table.c | |
parent | 1fb2e3f276ddafee81073d884f599cd2574c31e2 (diff) | |
download | linux-stable-e37f2f93afe594682702439ca34eb8130598cdf2.tar.gz linux-stable-e37f2f93afe594682702439ca34eb8130598cdf2.tar.bz2 linux-stable-e37f2f93afe594682702439ca34eb8130598cdf2.zip |
lib/crc: Use consistent naming for CRC-32 polynomials
Header was defining CRCPOLY_LE/BE and CRC32C_POLY_LE but in fact all of
them are CRC-32 polynomials so use consistent naming.
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'lib/gen_crc32table.c')
-rw-r--r-- | lib/gen_crc32table.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/gen_crc32table.c b/lib/gen_crc32table.c index 34c3bc826f45..f755b997b967 100644 --- a/lib/gen_crc32table.c +++ b/lib/gen_crc32table.c @@ -58,7 +58,7 @@ static void crc32init_le_generic(const uint32_t polynomial, static void crc32init_le(void) { - crc32init_le_generic(CRCPOLY_LE, crc32table_le); + crc32init_le_generic(CRC32_POLY_LE, crc32table_le); } static void crc32cinit_le(void) @@ -77,7 +77,7 @@ static void crc32init_be(void) crc32table_be[0][0] = 0; for (i = 1; i < BE_TABLE_SIZE; i <<= 1) { - crc = (crc << 1) ^ ((crc & 0x80000000) ? CRCPOLY_BE : 0); + crc = (crc << 1) ^ ((crc & 0x80000000) ? CRC32_POLY_BE : 0); for (j = 0; j < i; j++) crc32table_be[0][i + j] = crc ^ crc32table_be[0][j]; } |