]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - crypto/algapi.c
powerpc/xive: Fix offset for store EOI MMIOs
[karo-tx-linux.git] / crypto / algapi.c
index 6b52e8f0b95f1ab73082879696fde3b467d335b1..9eed4ef9c9712688a8ee3ee555c253a81a1ba5f7 100644 (file)
@@ -963,11 +963,11 @@ void crypto_inc(u8 *a, unsigned int size)
        u32 c;
 
        if (IS_ENABLED(CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS) ||
-           !((unsigned long)b & (__alignof__(*b) - 1)))
+           IS_ALIGNED((unsigned long)b, __alignof__(*b)))
                for (; size >= 4; size -= 4) {
                        c = be32_to_cpu(*--b) + 1;
                        *b = cpu_to_be32(c);
-                       if (c)
+                       if (likely(c))
                                return;
                }