Merge tag 'threads-v5.6' of git://git.kernel.org/pub/scm/linux/kernel/git/brauner...
[linux-2.6-microblaze.git] / crypto / crc32_generic.c
index 9e97912..0e103fb 100644 (file)
@@ -60,10 +60,8 @@ static int crc32_setkey(struct crypto_shash *hash, const u8 *key,
 {
        u32 *mctx = crypto_shash_ctx(hash);
 
-       if (keylen != sizeof(u32)) {
-               crypto_shash_set_flags(hash, CRYPTO_TFM_RES_BAD_KEY_LEN);
+       if (keylen != sizeof(u32))
                return -EINVAL;
-       }
        *mctx = get_unaligned_le32(key);
        return 0;
 }