crypto: caam/qi - use print_hex_dump_debug function to print debug messages
authorIuliana Prodan <iuliana.prodan@nxp.com>
Tue, 20 Aug 2019 11:26:39 +0000 (14:26 +0300)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 30 Aug 2019 08:05:28 +0000 (18:05 +1000)
Use print_hex_dump_debug function to print debug messages, instead of
print_hex_dump inside #ifdef DEBUG.

Fixes: 6e005503199b ("crypto: caam - print debug messages at debug level")
Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/caam/caamalg_qi.c

index 932643c88a5d423361f1b08d0bb4002a93339ade..8e3449670d2f0517a0a9ae1ca2e6b0eb3a59db80 100644 (file)
@@ -234,11 +234,10 @@ static int aead_setkey(struct crypto_aead *aead, const u8 *key,
        dma_sync_single_for_device(jrdev->parent, ctx->key_dma,
                                   ctx->adata.keylen_pad + keys.enckeylen,
                                   ctx->dir);
-#ifdef DEBUG
-       print_hex_dump(KERN_ERR, "ctx.key@" __stringify(__LINE__)": ",
-                      DUMP_PREFIX_ADDRESS, 16, 4, ctx->key,
-                      ctx->adata.keylen_pad + keys.enckeylen, 1);
-#endif
+
+       print_hex_dump_debug("ctx.key@" __stringify(__LINE__)": ",
+                            DUMP_PREFIX_ADDRESS, 16, 4, ctx->key,
+                            ctx->adata.keylen_pad + keys.enckeylen, 1);
 
 skip_split_key:
        ctx->cdata.keylen = keys.enckeylen;