2021-02-04 11:13:09

by Lee Jones

[permalink] [raw]
Subject: [PATCH 00/20] Rid W=1 warnings in Crypto

This set is part of a larger effort attempting to clean-up W=1
kernel builds, which are currently overwhelmingly riddled with
niggly little warnings.

This is set 1 of 2 sets required to fully clean Crypto.

Lee Jones (20):
crypto: hisilicon: sec_drv: Supply missing description for
'sec_queue_empty()'s 'queue' param
crypto: bcm: util: Repair a couple of documentation formatting issues
crypto: chelsio: chcr_core: File headers are not good candidates for
kernel-doc
crypto: ux500: hash: hash_core: Fix worthy kernel-doc headers and
remove others
crypto: bcm: spu: Fix formatting and misspelling issues
crypto: keembay: ocs-hcu: Fix incorrectly named functions/structs
crypto: bcm: spu2: Fix a whole host of kernel-doc misdemeanours
crypto: ux500: cryp: Demote some conformant non-kernel headers fix
another
crypto: ux500: cryp_irq: File headers are not good kernel-doc
candidates
crypto: chelsio: chcr_algo: Fix a couple of kernel-doc issues caused
by doc-rot
crypto: ux500: cryp_core: Fix formatting issue and add description for
'session_id'
crypto: atmel-ecc: Struct headers need to start with keyword 'struct'
crypto: bcm: cipher: Provide description for 'req' and fix formatting
issues
crypto: caam: caampkc: Provide the name of the function
crypto: caam: caamalg_qi2: Supply a couple of 'fallback' related
descriptions
crypto: vmx: Source headers are not good kernel-doc candidates
crypto: nx: nx-aes-cbc: Headers comments should not be kernel-doc
crypto: nx: nx_debugfs: Header comments should not be kernel-doc
crypto: nx: Demote header comment and add description for 'nbytes'
crypto: cavium: nitrox_isr: Demote non-compliant kernel-doc headers

drivers/crypto/atmel-ecc.c | 2 +-
drivers/crypto/bcm/cipher.c | 7 ++--
drivers/crypto/bcm/spu.c | 16 ++++-----
drivers/crypto/bcm/spu2.c | 43 +++++++++++++----------
drivers/crypto/bcm/util.c | 4 +--
drivers/crypto/caam/caamalg_qi2.c | 2 ++
drivers/crypto/caam/caampkc.c | 3 +-
drivers/crypto/cavium/nitrox/nitrox_isr.c | 4 +--
drivers/crypto/chelsio/chcr_algo.c | 8 ++---
drivers/crypto/chelsio/chcr_core.c | 2 +-
drivers/crypto/hisilicon/sec/sec_drv.c | 1 +
drivers/crypto/keembay/ocs-hcu.c | 6 ++--
drivers/crypto/nx/nx-aes-cbc.c | 2 +-
drivers/crypto/nx/nx.c | 5 +--
drivers/crypto/nx/nx_debugfs.c | 2 +-
drivers/crypto/ux500/cryp/cryp.c | 5 +--
drivers/crypto/ux500/cryp/cryp_core.c | 5 +--
drivers/crypto/ux500/cryp/cryp_irq.c | 2 +-
drivers/crypto/ux500/hash/hash_core.c | 15 +++-----
drivers/crypto/vmx/vmx.c | 2 +-
20 files changed, 71 insertions(+), 65 deletions(-)

Cc: Alexandre Belloni <[email protected]>
Cc: Andreas Westin <[email protected]>
Cc: Atul Gupta <[email protected]>
Cc: Aymen Sghaier <[email protected]>
Cc: Ayush Sawal <[email protected]>
Cc: Benjamin Herrenschmidt <[email protected]>
Cc: Berne Hebark <[email protected]>
Cc: "Breno Leitão" <[email protected]>
Cc: Daniele Alessandrelli <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Declan Murphy <[email protected]>
Cc: "Gustavo A. R. Silva" <[email protected]>
Cc: Harsh Jain <[email protected]>
Cc: Henrique Cerri <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "Horia Geantă" <[email protected]>
Cc: Jitendra Lulla <[email protected]>
Cc: Joakim Bech <[email protected]>
Cc: Jonas Linde <[email protected]>
Cc: Jonathan Cameron <[email protected]>
Cc: Kent Yoder <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: Ludovic Desroches <[email protected]>
Cc: Manoj Malviya <[email protected]>
Cc: Michael Ellerman <[email protected]>
Cc: M R Gowda <[email protected]>
Cc: Nayna Jain <[email protected]>
Cc: Nicolas Ferre <[email protected]>
Cc: Niklas Hernaeus <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Paulo Flabiano Smorigo <[email protected]>
Cc: Rob Rice <[email protected]>
Cc: Rohit Maheshwari <[email protected]>
Cc: Shujuan Chen <[email protected]>
Cc: Takashi Iwai <[email protected]>
Cc: Tudor Ambarus <[email protected]>
Cc: Vinay Kumar Yadav <[email protected]>
Cc: Zaibo Xu <[email protected]>
--
2.25.1


2021-02-04 11:14:19

by Lee Jones

[permalink] [raw]
Subject: [PATCH 03/20] crypto: chelsio: chcr_core: File headers are not good candidates for kernel-doc

Fixes the following W=1 kernel build warning(s):

drivers/crypto/chelsio/chcr_core.c:2: warning: wrong kernel-doc identifier on line:

Cc: Ayush Sawal <[email protected]>
Cc: Vinay Kumar Yadav <[email protected]>
Cc: Rohit Maheshwari <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Manoj Malviya <[email protected]>
Cc: Atul Gupta <[email protected]>
Cc: Jitendra Lulla <[email protected]>
Cc: M R Gowda <[email protected]>
Cc: Harsh Jain <[email protected]>
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/chelsio/chcr_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/chelsio/chcr_core.c b/drivers/crypto/chelsio/chcr_core.c
index f91f9d762a45e..f03ef4a23f96d 100644
--- a/drivers/crypto/chelsio/chcr_core.c
+++ b/drivers/crypto/chelsio/chcr_core.c
@@ -1,4 +1,4 @@
-/**
+/*
* This file is part of the Chelsio T4/T5/T6 Ethernet driver for Linux.
*
* Copyright (C) 2011-2016 Chelsio Communications. All rights reserved.
--
2.25.1

2021-02-04 11:14:44

by Lee Jones

[permalink] [raw]
Subject: [PATCH 05/20] crypto: bcm: spu: Fix formatting and misspelling issues

Fixes the following W=1 kernel build warning(s):

drivers/crypto/bcm/spu.c:464: warning: Excess function parameter 'Return' description in 'spum_gcm_ccm_pad_len'
drivers/crypto/bcm/spu.c:524: warning: Function parameter or member 'iv_len' not described in 'spum_aead_ivlen'
drivers/crypto/bcm/spu.c:524: warning: expecting prototype for spu_aead_ivlen(). Prototype was for spum_aead_ivlen() instead
drivers/crypto/bcm/spu.c:556: warning: Function parameter or member 'alg_digest_size' not described in 'spum_digest_size'
drivers/crypto/bcm/spu.c:556: warning: Function parameter or member 'alg' not described in 'spum_digest_size'
drivers/crypto/bcm/spu.c:556: warning: Function parameter or member 'htype' not described in 'spum_digest_size'
drivers/crypto/bcm/spu.c:583: warning: bad line:
drivers/crypto/bcm/spu.c:927: warning: Function parameter or member 'is_inbound' not described in 'spum_cipher_req_finish'
drivers/crypto/bcm/spu.c:927: warning: Excess function parameter 'isInbound' description in 'spum_cipher_req_finish'

Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/bcm/spu.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/drivers/crypto/bcm/spu.c b/drivers/crypto/bcm/spu.c
index 007abf92cc05b..6283e8c6d51d3 100644
--- a/drivers/crypto/bcm/spu.c
+++ b/drivers/crypto/bcm/spu.c
@@ -457,7 +457,7 @@ u16 spum_hash_pad_len(enum hash_alg hash_alg, enum hash_mode hash_mode,
* @cipher_mode: Algo type
* @data_size: Length of plaintext (bytes)
*
- * @Return: Length of padding, in bytes
+ * Return: Length of padding, in bytes
*/
u32 spum_gcm_ccm_pad_len(enum spu_cipher_mode cipher_mode,
unsigned int data_size)
@@ -510,10 +510,10 @@ u32 spum_assoc_resp_len(enum spu_cipher_mode cipher_mode,
}

/**
- * spu_aead_ivlen() - Calculate the length of the AEAD IV to be included
+ * spum_aead_ivlen() - Calculate the length of the AEAD IV to be included
* in a SPU request after the AAD and before the payload.
* @cipher_mode: cipher mode
- * @iv_ctr_len: initialization vector length in bytes
+ * @iv_len: initialization vector length in bytes
*
* In Linux ~4.2 and later, the assoc_data sg includes the IV. So no need
* to include the IV as a separate field in the SPU request msg.
@@ -543,9 +543,9 @@ enum hash_type spum_hash_type(u32 src_sent)
/**
* spum_digest_size() - Determine the size of a hash digest to expect the SPU to
* return.
- * alg_digest_size: Number of bytes in the final digest for the given algo
- * alg: The hash algorithm
- * htype: Type of hash operation (init, update, full, etc)
+ * @alg_digest_size: Number of bytes in the final digest for the given algo
+ * @alg: The hash algorithm
+ * @htype: Type of hash operation (init, update, full, etc)
*
* When doing incremental hashing for an algorithm with a truncated hash
* (e.g., SHA224), the SPU returns the full digest so that it can be fed back as
@@ -580,7 +580,7 @@ u32 spum_digest_size(u32 alg_digest_size, enum hash_alg alg,
* @aead_parms: Parameters related to AEAD operation
* @data_size: Length of data to be encrypted or authenticated. If AEAD, does
* not include length of AAD.
-
+ *
* Return: the length of the SPU header in bytes. 0 if an error occurs.
*/
u32 spum_create_request(u8 *spu_hdr,
@@ -911,7 +911,7 @@ u16 spum_cipher_req_init(u8 *spu_hdr, struct spu_cipher_parms *cipher_parms)
* setkey() time in spu_cipher_req_init().
* @spu_hdr: Start of the request message header (MH field)
* @spu_req_hdr_len: Length in bytes of the SPU request header
- * @isInbound: 0 encrypt, 1 decrypt
+ * @is_inbound: 0 encrypt, 1 decrypt
* @cipher_parms: Parameters describing cipher operation to be performed
* @data_size: Length of the data in the BD field
*
--
2.25.1

2021-02-04 11:15:30

by Lee Jones

[permalink] [raw]
Subject: [PATCH 08/20] crypto: ux500: cryp: Demote some conformant non-kernel headers fix another

Fixes the following W=1 kernel build warning(s):

drivers/crypto/ux500/cryp/cryp.c:19: warning: Incorrect use of kernel-doc format: * cryp_wait_until_done - wait until the device logic is not busy
drivers/crypto/ux500/cryp/cryp.c:22: warning: Function parameter or member 'device_data' not described in 'cryp_wait_until_done'
drivers/crypto/ux500/cryp/cryp.c:22: warning: expecting prototype for ST(). Prototype was for cryp_wait_until_done() instead
drivers/crypto/ux500/cryp/cryp.c:292: warning: Function parameter or member 'cryp_mode' not described in 'cryp_save_device_context'

Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: "Gustavo A. R. Silva" <[email protected]>
Cc: Shujuan Chen <[email protected]>
Cc: Jonas Linde <[email protected]>
Cc: Niklas Hernaeus <[email protected]>
Cc: Joakim Bech <[email protected]>
Cc: Berne Hebark <[email protected]>
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/ux500/cryp/cryp.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/crypto/ux500/cryp/cryp.c b/drivers/crypto/ux500/cryp/cryp.c
index 9866c2a5e9a70..759d0d9786fd1 100644
--- a/drivers/crypto/ux500/cryp/cryp.c
+++ b/drivers/crypto/ux500/cryp/cryp.c
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
* Copyright (C) ST-Ericsson SA 2010
* Author: Shujuan Chen <[email protected]> for ST-Ericsson.
* Author: Jonas Linde <[email protected]> for ST-Ericsson.
@@ -15,7 +15,7 @@
#include "cryp_p.h"
#include "cryp.h"

-/**
+/*
* cryp_wait_until_done - wait until the device logic is not busy
*/
void cryp_wait_until_done(struct cryp_device_data *device_data)
@@ -285,6 +285,7 @@ int cryp_configure_init_vector(struct cryp_device_data *device_data,
* other device context parameter
* @device_data: Pointer to the device data struct for base address.
* @ctx: Crypto device context
+ * @cryp_mode: Mode: Polling, Interrupt or DMA
*/
void cryp_save_device_context(struct cryp_device_data *device_data,
struct cryp_device_context *ctx,
--
2.25.1

2021-02-04 11:15:43

by Lee Jones

[permalink] [raw]
Subject: [PATCH 09/20] crypto: ux500: cryp_irq: File headers are not good kernel-doc candidates

Fixes the following W=1 kernel build warning(s):

drivers/crypto/ux500/cryp/cryp_irq.c:21: warning: Function parameter or member 'device_data' not described in 'cryp_enable_irq_src'
drivers/crypto/ux500/cryp/cryp_irq.c:21: warning: Function parameter or member 'irq_src' not described in 'cryp_enable_irq_src'
drivers/crypto/ux500/cryp/cryp_irq.c:21: warning: expecting prototype for ST(). Prototype was for cryp_enable_irq_src() instead

Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Shujuan Chen <[email protected]>
Cc: Jonas Linde <[email protected]>
Cc: Joakim Bech <[email protected]>
Cc: Berne Hebark <[email protected]>
Cc: Niklas Hernaeus <[email protected]>
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/ux500/cryp/cryp_irq.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/ux500/cryp/cryp_irq.c b/drivers/crypto/ux500/cryp/cryp_irq.c
index 7ebde69e8c76b..6d2f07bec98a7 100644
--- a/drivers/crypto/ux500/cryp/cryp_irq.c
+++ b/drivers/crypto/ux500/cryp/cryp_irq.c
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
* Copyright (C) ST-Ericsson SA 2010
* Author: Shujuan Chen <[email protected]> for ST-Ericsson.
* Author: Jonas Linde <[email protected]> for ST-Ericsson.
--
2.25.1

2021-02-04 11:16:46

by Lee Jones

[permalink] [raw]
Subject: [PATCH 18/20] crypto: nx: nx_debugfs: Header comments should not be kernel-doc

Fixes the following W=1 kernel build warning(s):

drivers/crypto/nx/nx_debugfs.c:34: warning: Function parameter or member 'drv' not described in 'nx_debugfs_init'
drivers/crypto/nx/nx_debugfs.c:34: warning: expecting prototype for Nest Accelerators driver(). Prototype was for nx_debugfs_init() instead

Cc: "Breno Leitão" <[email protected]>
Cc: Nayna Jain <[email protected]>
Cc: Paulo Flabiano Smorigo <[email protected]>
Cc: Michael Ellerman <[email protected]>
Cc: Benjamin Herrenschmidt <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Kent Yoder <[email protected]>
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/nx/nx_debugfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/nx/nx_debugfs.c b/drivers/crypto/nx/nx_debugfs.c
index 1975bcbee9974..ee7cd88bb10a7 100644
--- a/drivers/crypto/nx/nx_debugfs.c
+++ b/drivers/crypto/nx/nx_debugfs.c
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
* debugfs routines supporting the Power 7+ Nest Accelerators driver
*
* Copyright (C) 2011-2012 International Business Machines Inc.
--
2.25.1

2021-02-04 11:17:17

by Lee Jones

[permalink] [raw]
Subject: [PATCH 10/20] crypto: chelsio: chcr_algo: Fix a couple of kernel-doc issues caused by doc-rot

Fixes the following W=1 kernel build warning(s):

drivers/crypto/chelsio/chcr_algo.c:806: warning: Function parameter or member 'wrparam' not described in 'create_cipher_wr'
drivers/crypto/chelsio/chcr_algo.c:806: warning: Excess function parameter 'req' description in 'create_cipher_wr'
drivers/crypto/chelsio/chcr_algo.c:806: warning: Excess function parameter 'ctx' description in 'create_cipher_wr'
drivers/crypto/chelsio/chcr_algo.c:806: warning: Excess function parameter 'qid' description in 'create_cipher_wr'
drivers/crypto/chelsio/chcr_algo.c:806: warning: Excess function parameter 'op_type' description in 'create_cipher_wr'
drivers/crypto/chelsio/chcr_algo.c:1566: warning: Function parameter or member 'req' not described in 'create_hash_wr'
drivers/crypto/chelsio/chcr_algo.c:1566: warning: Function parameter or member 'param' not described in 'create_hash_wr'

Cc: Ayush Sawal <[email protected]>
Cc: Vinay Kumar Yadav <[email protected]>
Cc: Rohit Maheshwari <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Manoj Malviya <[email protected]>
Cc: Atul Gupta <[email protected]>
Cc: Jitendra Lulla <[email protected]>
Cc: M R Gowda <[email protected]>
Cc: Harsh Jain <[email protected]>
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/chelsio/chcr_algo.c | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/drivers/crypto/chelsio/chcr_algo.c b/drivers/crypto/chelsio/chcr_algo.c
index f5a336634daa6..f77d3fd962bf8 100644
--- a/drivers/crypto/chelsio/chcr_algo.c
+++ b/drivers/crypto/chelsio/chcr_algo.c
@@ -797,10 +797,7 @@ static inline void create_wreq(struct chcr_context *ctx,

/**
* create_cipher_wr - form the WR for cipher operations
- * @req: cipher req.
- * @ctx: crypto driver context of the request.
- * @qid: ingress qid where response of this WR should be received.
- * @op_type: encryption or decryption
+ * @wrparam: Container for create_cipher_wr()'s parameters
*/
static struct sk_buff *create_cipher_wr(struct cipher_wr_param *wrparam)
{
@@ -1559,7 +1556,8 @@ static inline void chcr_free_shash(struct crypto_shash *base_hash)

/**
* create_hash_wr - Create hash work request
- * @req - Cipher req base
+ * @req: Cipher req base
+ * @param: Container for create_hash_wr()'s parameters
*/
static struct sk_buff *create_hash_wr(struct ahash_request *req,
struct hash_wr_param *param)
--
2.25.1

2021-02-04 11:18:16

by Lee Jones

[permalink] [raw]
Subject: [PATCH 19/20] crypto: nx: Demote header comment and add description for 'nbytes'

Fixes the following W=1 kernel build warning(s):

drivers/crypto/nx/nx.c:31: warning: Incorrect use of kernel-doc format: * nx_hcall_sync - make an H_COP_OP hcall for the passed in op structure
drivers/crypto/nx/nx.c:43: warning: Function parameter or member 'nx_ctx' not described in 'nx_hcall_sync'
drivers/crypto/nx/nx.c:43: warning: Function parameter or member 'op' not described in 'nx_hcall_sync'
drivers/crypto/nx/nx.c:43: warning: Function parameter or member 'may_sleep' not described in 'nx_hcall_sync'
drivers/crypto/nx/nx.c:43: warning: expecting prototype for Nest Accelerators driver(). Prototype was for nx_hcall_sync() instead
drivers/crypto/nx/nx.c:209: warning: Function parameter or member 'nbytes' not described in 'trim_sg_list'

Cc: "Breno Leitão" <[email protected]>
Cc: Nayna Jain <[email protected]>
Cc: Paulo Flabiano Smorigo <[email protected]>
Cc: Michael Ellerman <[email protected]>
Cc: Benjamin Herrenschmidt <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Kent Yoder <[email protected]>
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/nx/nx.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/crypto/nx/nx.c b/drivers/crypto/nx/nx.c
index 0d2dc5be7f192..010be6793c9fc 100644
--- a/drivers/crypto/nx/nx.c
+++ b/drivers/crypto/nx/nx.c
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
* Routines supporting the Power 7+ Nest Accelerators driver
*
* Copyright (C) 2011-2012 International Business Machines Inc.
@@ -200,7 +200,8 @@ struct nx_sg *nx_walk_and_build(struct nx_sg *nx_dst,
* @sg: sg list head
* @end: sg lisg end
* @delta: is the amount we need to crop in order to bound the list.
- *
+ * @nbytes: length of data in the scatterlists or data length - whichever
+ * is greater.
*/
static long int trim_sg_list(struct nx_sg *sg,
struct nx_sg *end,
--
2.25.1

2021-02-04 11:18:20

by Lee Jones

[permalink] [raw]
Subject: [PATCH 20/20] crypto: cavium: nitrox_isr: Demote non-compliant kernel-doc headers

Fixes the following W=1 kernel build warning(s):

drivers/crypto/cavium/nitrox/nitrox_isr.c:17: warning: expecting prototype for One vector for each type of ring(). Prototype was for NR_RING_VECTORS() instead
drivers/crypto/cavium/nitrox/nitrox_isr.c:224: warning: Function parameter or member 'irq' not described in 'nps_core_int_isr'
drivers/crypto/cavium/nitrox/nitrox_isr.c:224: warning: Function parameter or member 'data' not described in 'nps_core_int_isr'

Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/cavium/nitrox/nitrox_isr.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/crypto/cavium/nitrox/nitrox_isr.c b/drivers/crypto/cavium/nitrox/nitrox_isr.c
index 99b053094f5af..c288c4b51783d 100644
--- a/drivers/crypto/cavium/nitrox/nitrox_isr.c
+++ b/drivers/crypto/cavium/nitrox/nitrox_isr.c
@@ -10,7 +10,7 @@
#include "nitrox_isr.h"
#include "nitrox_mbx.h"

-/**
+/*
* One vector for each type of ring
* - NPS packet ring, AQMQ ring and ZQMQ ring
*/
@@ -216,7 +216,7 @@ static void nps_core_int_tasklet(unsigned long data)
}
}

-/**
+/*
* nps_core_int_isr - interrupt handler for NITROX errors and
* mailbox communication
*/
--
2.25.1

2021-02-04 11:19:07

by Lee Jones

[permalink] [raw]
Subject: [PATCH 15/20] crypto: caam: caamalg_qi2: Supply a couple of 'fallback' related descriptions

Fixes the following W=1 kernel build warning(s):

drivers/crypto/caam/caamalg_qi2.c:87: warning: Function parameter or member 'xts_key_fallback' not described in 'caam_ctx'
drivers/crypto/caam/caamalg_qi2.c:87: warning: Function parameter or member 'fallback' not described in 'caam_ctx'

Cc: "Horia Geantă" <[email protected]>
Cc: Aymen Sghaier <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/caam/caamalg_qi2.c | 2 ++
1 file changed, 2 insertions(+)

diff --git a/drivers/crypto/caam/caamalg_qi2.c b/drivers/crypto/caam/caamalg_qi2.c
index a780e627838ae..22e45c5bf2023 100644
--- a/drivers/crypto/caam/caamalg_qi2.c
+++ b/drivers/crypto/caam/caamalg_qi2.c
@@ -71,6 +71,8 @@ struct caam_skcipher_alg {
* @adata: authentication algorithm details
* @cdata: encryption algorithm details
* @authsize: authentication tag (a.k.a. ICV / MAC) size
+ * @xts_key_fallback: whether to set the fallback key
+ * @fallback: the fallback key
*/
struct caam_ctx {
struct caam_flc flc[NUM_OP];
--
2.25.1

2021-02-04 11:19:30

by Lee Jones

[permalink] [raw]
Subject: [PATCH 17/20] crypto: nx: nx-aes-cbc: Headers comments should not be kernel-doc

Fixes the following W=1 kernel build warning(s):

drivers/crypto/nx/nx-aes-cbc.c:24: warning: Function parameter or member 'tfm' not described in 'cbc_aes_nx_set_key'
drivers/crypto/nx/nx-aes-cbc.c:24: warning: Function parameter or member 'in_key' not described in 'cbc_aes_nx_set_key'
drivers/crypto/nx/nx-aes-cbc.c:24: warning: Function parameter or member 'key_len' not described in 'cbc_aes_nx_set_key'
drivers/crypto/nx/nx-aes-cbc.c:24: warning: expecting prototype for Nest Accelerators driver(). Prototype was for cbc_aes_nx_set_key() instead

Cc: "Breno Leitão" <[email protected]>
Cc: Nayna Jain <[email protected]>
Cc: Paulo Flabiano Smorigo <[email protected]>
Cc: Michael Ellerman <[email protected]>
Cc: Benjamin Herrenschmidt <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Kent Yoder <[email protected]>
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/nx/nx-aes-cbc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/nx/nx-aes-cbc.c b/drivers/crypto/nx/nx-aes-cbc.c
index 92e921eceed75..d6314ea9ae896 100644
--- a/drivers/crypto/nx/nx-aes-cbc.c
+++ b/drivers/crypto/nx/nx-aes-cbc.c
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
* AES CBC routines supporting the Power 7+ Nest Accelerators driver
*
* Copyright (C) 2011-2012 International Business Machines Inc.
--
2.25.1

2021-02-04 11:20:08

by Lee Jones

[permalink] [raw]
Subject: [PATCH 13/20] crypto: bcm: cipher: Provide description for 'req' and fix formatting issues

Fixes the following W=1 kernel build warning(s):

drivers/crypto/bcm/cipher.c:1048: warning: Function parameter or member 'req' not described in 'spu_aead_rx_sg_create'
drivers/crypto/bcm/cipher.c:2966: warning: Function parameter or member 'cipher' not described in 'rfc4543_gcm_esp_setkey'
drivers/crypto/bcm/cipher.c:2966: warning: Function parameter or member 'key' not described in 'rfc4543_gcm_esp_setkey'
drivers/crypto/bcm/cipher.c:2966: warning: Function parameter or member 'keylen' not described in 'rfc4543_gcm_esp_setkey'

Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Rob Rice <[email protected]>
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/bcm/cipher.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/crypto/bcm/cipher.c b/drivers/crypto/bcm/cipher.c
index 851b149f71701..053315e260c22 100644
--- a/drivers/crypto/bcm/cipher.c
+++ b/drivers/crypto/bcm/cipher.c
@@ -1019,6 +1019,7 @@ static void handle_ahash_resp(struct iproc_reqctx_s *rctx)
* a SPU response message for an AEAD request. Includes buffers to catch SPU
* message headers and the response data.
* @mssg: mailbox message containing the receive sg
+ * @req: Crypto API request
* @rctx: crypto request context
* @rx_frag_num: number of scatterlist elements required to hold the
* SPU response message
@@ -2952,9 +2953,9 @@ static int aead_gcm_esp_setkey(struct crypto_aead *cipher,

/**
* rfc4543_gcm_esp_setkey() - setkey operation for RFC4543 variant of GCM/GMAC.
- * cipher: AEAD structure
- * key: Key followed by 4 bytes of salt
- * keylen: Length of key plus salt, in bytes
+ * @cipher: AEAD structure
+ * @key: Key followed by 4 bytes of salt
+ * @keylen: Length of key plus salt, in bytes
*
* Extracts salt from key and stores it to be prepended to IV on each request.
* Digest is always 16 bytes
--
2.25.1

2021-02-04 11:21:24

by Lee Jones

[permalink] [raw]
Subject: [PATCH 16/20] crypto: vmx: Source headers are not good kernel-doc candidates

Fixes the following W=1 kernel build warning(s):

drivers/crypto/vmx/vmx.c:23: warning: expecting prototype for Routines supporting VMX instructions on the Power 8(). Prototype was for p8_init() instead

Cc: "Breno Leitão" <[email protected]>
Cc: Nayna Jain <[email protected]>
Cc: Paulo Flabiano Smorigo <[email protected]>
Cc: Michael Ellerman <[email protected]>
Cc: Benjamin Herrenschmidt <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Henrique Cerri <[email protected]>
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/vmx/vmx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/vmx/vmx.c b/drivers/crypto/vmx/vmx.c
index a40d08e75fc0b..7eb713cc87c8c 100644
--- a/drivers/crypto/vmx/vmx.c
+++ b/drivers/crypto/vmx/vmx.c
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
* Routines supporting VMX instructions on the Power 8
*
* Copyright (C) 2015 International Business Machines Inc.
--
2.25.1

2021-02-04 11:21:33

by Lee Jones

[permalink] [raw]
Subject: [PATCH 12/20] crypto: atmel-ecc: Struct headers need to start with keyword 'struct'

Fixes the following W=1 kernel build warning(s):

drivers/crypto/atmel-ecc.c:41: warning: cannot understand function prototype: 'struct atmel_ecdh_ctx '

Cc: Tudor Ambarus <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: Nicolas Ferre <[email protected]>
Cc: Alexandre Belloni <[email protected]>
Cc: Ludovic Desroches <[email protected]>
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Lee Jones <[email protected]>
---
drivers/crypto/atmel-ecc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/atmel-ecc.c b/drivers/crypto/atmel-ecc.c
index 9bd8e5167be34..66a31e5739f4c 100644
--- a/drivers/crypto/atmel-ecc.c
+++ b/drivers/crypto/atmel-ecc.c
@@ -26,7 +26,7 @@
static struct atmel_ecc_driver_data driver_data;

/**
- * atmel_ecdh_ctx - transformation context
+ * struct atmel_ecdh_ctx - transformation context
* @client : pointer to i2c client device
* @fallback : used for unsupported curves or when user wants to use its own
* private key.
--
2.25.1

2021-02-04 15:53:15

by Tudor Ambarus

[permalink] [raw]
Subject: Re: [PATCH 12/20] crypto: atmel-ecc: Struct headers need to start with keyword 'struct'

On 2/4/21 1:09 PM, Lee Jones wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
>
> Fixes the following W=1 kernel build warning(s):
>
> drivers/crypto/atmel-ecc.c:41: warning: cannot understand function prototype: 'struct atmel_ecdh_ctx '
>
> Cc: Tudor Ambarus <[email protected]>
> Cc: Herbert Xu <[email protected]>
> Cc: "David S. Miller" <[email protected]>
> Cc: Nicolas Ferre <[email protected]>
> Cc: Alexandre Belloni <[email protected]>
> Cc: Ludovic Desroches <[email protected]>
> Cc: [email protected]
> Cc: [email protected]
> Signed-off-by: Lee Jones <[email protected]>

Reviewed-by: Tudor Ambarus <[email protected]>

> ---
> drivers/crypto/atmel-ecc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/crypto/atmel-ecc.c b/drivers/crypto/atmel-ecc.c
> index 9bd8e5167be34..66a31e5739f4c 100644
> --- a/drivers/crypto/atmel-ecc.c
> +++ b/drivers/crypto/atmel-ecc.c
> @@ -26,7 +26,7 @@
> static struct atmel_ecc_driver_data driver_data;
>
> /**
> - * atmel_ecdh_ctx - transformation context
> + * struct atmel_ecdh_ctx - transformation context
> * @client : pointer to i2c client device
> * @fallback : used for unsupported curves or when user wants to use its own
> * private key.
> --
> 2.25.1
>

2021-02-08 19:52:38

by Horia Geanta

[permalink] [raw]
Subject: Re: [PATCH 15/20] crypto: caam: caamalg_qi2: Supply a couple of 'fallback' related descriptions

On 2/4/2021 1:10 PM, Lee Jones wrote:
> Fixes the following W=1 kernel build warning(s):
>
> drivers/crypto/caam/caamalg_qi2.c:87: warning: Function parameter or member 'xts_key_fallback' not described in 'caam_ctx'
> drivers/crypto/caam/caamalg_qi2.c:87: warning: Function parameter or member 'fallback' not described in 'caam_ctx'
>
> Cc: "Horia Geantă" <[email protected]>
> Cc: Aymen Sghaier <[email protected]>
> Cc: Herbert Xu <[email protected]>
> Cc: "David S. Miller" <[email protected]>
> Cc: [email protected]
> Signed-off-by: Lee Jones <[email protected]>
> ---
> drivers/crypto/caam/caamalg_qi2.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/crypto/caam/caamalg_qi2.c b/drivers/crypto/caam/caamalg_qi2.c
> index a780e627838ae..22e45c5bf2023 100644
> --- a/drivers/crypto/caam/caamalg_qi2.c
> +++ b/drivers/crypto/caam/caamalg_qi2.c
> @@ -71,6 +71,8 @@ struct caam_skcipher_alg {
> * @adata: authentication algorithm details
> * @cdata: encryption algorithm details
> * @authsize: authentication tag (a.k.a. ICV / MAC) size
> + * @xts_key_fallback: whether to set the fallback key
true if fallback tfm needs to be used due to unsupported xts key lengths.

> + * @fallback: the fallback key
xts fallback tfm

Horia

2021-02-10 08:38:14

by Herbert Xu

[permalink] [raw]
Subject: Re: [PATCH 00/20] Rid W=1 warnings in Crypto

On Thu, Feb 04, 2021 at 11:09:40AM +0000, Lee Jones wrote:
> This set is part of a larger effort attempting to clean-up W=1
> kernel builds, which are currently overwhelmingly riddled with
> niggly little warnings.
>
> This is set 1 of 2 sets required to fully clean Crypto.
>
> Lee Jones (20):
> crypto: hisilicon: sec_drv: Supply missing description for
> 'sec_queue_empty()'s 'queue' param
> crypto: bcm: util: Repair a couple of documentation formatting issues
> crypto: chelsio: chcr_core: File headers are not good candidates for
> kernel-doc
> crypto: ux500: hash: hash_core: Fix worthy kernel-doc headers and
> remove others
> crypto: bcm: spu: Fix formatting and misspelling issues
> crypto: keembay: ocs-hcu: Fix incorrectly named functions/structs
> crypto: bcm: spu2: Fix a whole host of kernel-doc misdemeanours
> crypto: ux500: cryp: Demote some conformant non-kernel headers fix
> another
> crypto: ux500: cryp_irq: File headers are not good kernel-doc
> candidates
> crypto: chelsio: chcr_algo: Fix a couple of kernel-doc issues caused
> by doc-rot
> crypto: ux500: cryp_core: Fix formatting issue and add description for
> 'session_id'
> crypto: atmel-ecc: Struct headers need to start with keyword 'struct'
> crypto: bcm: cipher: Provide description for 'req' and fix formatting
> issues
> crypto: caam: caampkc: Provide the name of the function
> crypto: caam: caamalg_qi2: Supply a couple of 'fallback' related
> descriptions
> crypto: vmx: Source headers are not good kernel-doc candidates
> crypto: nx: nx-aes-cbc: Headers comments should not be kernel-doc
> crypto: nx: nx_debugfs: Header comments should not be kernel-doc
> crypto: nx: Demote header comment and add description for 'nbytes'
> crypto: cavium: nitrox_isr: Demote non-compliant kernel-doc headers

Thanks for doing this. But please don't split the patches at the
file level. Instead split them at the driver level. For example,
all of your bcm changes should be one patch.
--
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt