Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

crypto: amcc - fix incorrect kernel-doc comment syntax in files

The opening comment mark '/**' is used for highlighting the beginning of
kernel-doc comments.
There are certain files in drivers/crypto/amcc, which follow this syntax,
but the content inside does not comply with kernel-doc.
Such lines were probably not meant for kernel-doc parsing, but are parsed
due to the presence of kernel-doc like comment syntax(i.e, '/**'), which
causes unexpected warnings from kernel-doc.

E.g., presence of kernel-doc like comment in
drivers/crypto/amcc/crypto4xx_alg.c at header, and some other lines,
causes these warnings by kernel-doc:

"warning: expecting prototype for AMCC SoC PPC4xx Crypto Driver(). Prototype was for set_dynamic_sa_command_0() instead"
"warning: Function parameter or member 'dir' not described in 'set_dynamic_sa_command_0'"
etc..

Provide a simple fix by replacing such occurrences with general comment
format, i.e. '/*', to prevent kernel-doc from parsing it.

Signed-off-by: Aditya Srivastava <yashsri421@gmail.com>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

authored by

Aditya Srivastava and committed by
Herbert Xu
73f04d3d dbb153c0

+31 -31
+6 -6
drivers/crypto/amcc/crypto4xx_alg.c
··· 1 1 // SPDX-License-Identifier: GPL-2.0-or-later 2 - /** 2 + /* 3 3 * AMCC SoC PPC4xx Crypto Driver 4 4 * 5 5 * Copyright (c) 2008 Applied Micro Circuits Corporation. ··· 115 115 return crypto4xx_crypt(req, AES_IV_SIZE, true, true); 116 116 } 117 117 118 - /** 118 + /* 119 119 * AES Functions 120 120 */ 121 121 static int crypto4xx_setkey_aes(struct crypto_skcipher *cipher, ··· 374 374 return crypto_aead_setkey(ctx->sw_cipher.aead, key, keylen); 375 375 } 376 376 377 - /** 377 + /* 378 378 * AES-CCM Functions 379 379 */ 380 380 ··· 489 489 return crypto_aead_setauthsize(ctx->sw_cipher.aead, authsize); 490 490 } 491 491 492 - /** 492 + /* 493 493 * AES-GCM Functions 494 494 */ 495 495 ··· 617 617 return crypto4xx_crypt_aes_gcm(req, true); 618 618 } 619 619 620 - /** 620 + /* 621 621 * HASH SHA1 Functions 622 622 */ 623 623 static int crypto4xx_hash_alg_init(struct crypto_tfm *tfm, ··· 711 711 ctx->sa_len, 0, NULL); 712 712 } 713 713 714 - /** 714 + /* 715 715 * SHA1 Algorithm 716 716 */ 717 717 int crypto4xx_sha1_alg_init(struct crypto_tfm *tfm)
+9 -9
drivers/crypto/amcc/crypto4xx_core.c
··· 1 1 // SPDX-License-Identifier: GPL-2.0-or-later 2 - /** 2 + /* 3 3 * AMCC SoC PPC4xx Crypto Driver 4 4 * 5 5 * Copyright (c) 2008 Applied Micro Circuits Corporation. ··· 44 44 45 45 #define PPC4XX_SEC_VERSION_STR "0.5" 46 46 47 - /** 47 + /* 48 48 * PPC4xx Crypto Engine Initialization Routine 49 49 */ 50 50 static void crypto4xx_hw_init(struct crypto4xx_device *dev) ··· 159 159 ctx->sa_len = 0; 160 160 } 161 161 162 - /** 162 + /* 163 163 * alloc memory for the gather ring 164 164 * no need to alloc buf for the ring 165 165 * gdr_tail, gdr_head and gdr_count are initialized by this function ··· 268 268 return tail; 269 269 } 270 270 271 - /** 271 + /* 272 272 * alloc memory for the gather ring 273 273 * no need to alloc buf for the ring 274 274 * gdr_tail, gdr_head and gdr_count are initialized by this function ··· 346 346 return &dev->gdr[idx]; 347 347 } 348 348 349 - /** 349 + /* 350 350 * alloc memory for the scatter ring 351 351 * need to alloc buf for the ring 352 352 * sdr_tail, sdr_head and sdr_count are initialized by this function ··· 930 930 return is_busy ? -EBUSY : -EINPROGRESS; 931 931 } 932 932 933 - /** 933 + /* 934 934 * Algorithm Registration Functions 935 935 */ 936 936 static void crypto4xx_ctx_init(struct crypto4xx_alg *amcc_alg, ··· 1097 1097 } while (head != tail); 1098 1098 } 1099 1099 1100 - /** 1100 + /* 1101 1101 * Top Half of isr. 1102 1102 */ 1103 1103 static inline irqreturn_t crypto4xx_interrupt_handler(int irq, void *data, ··· 1186 1186 return 0; 1187 1187 } 1188 1188 1189 - /** 1189 + /* 1190 1190 * Supported Crypto Algorithms 1191 1191 */ 1192 1192 static struct crypto4xx_alg_common crypto4xx_alg[] = { ··· 1369 1369 } }, 1370 1370 }; 1371 1371 1372 - /** 1372 + /* 1373 1373 * Module Initialization Routine 1374 1374 */ 1375 1375 static int crypto4xx_probe(struct platform_device *ofdev)
+2 -2
drivers/crypto/amcc/crypto4xx_core.h
··· 1 1 /* SPDX-License-Identifier: GPL-2.0-or-later */ 2 - /** 2 + /* 3 3 * AMCC SoC PPC4xx Crypto Driver 4 4 * 5 5 * Copyright (c) 2008 Applied Micro Circuits Corporation. ··· 188 188 int crypto4xx_hash_update(struct ahash_request *req); 189 189 int crypto4xx_hash_init(struct ahash_request *req); 190 190 191 - /** 191 + /* 192 192 * Note: Only use this function to copy items that is word aligned. 193 193 */ 194 194 static inline void crypto4xx_memcpy_swab32(u32 *dst, const void *buf,
+4 -4
drivers/crypto/amcc/crypto4xx_reg_def.h
··· 1 1 /* SPDX-License-Identifier: GPL-2.0-or-later */ 2 - /** 2 + /* 3 3 * AMCC SoC PPC4xx Crypto Driver 4 4 * 5 5 * Copyright (c) 2008 Applied Micro Circuits Corporation. ··· 104 104 #define CRYPTO4XX_PRNG_LFSR_L 0x00070030 105 105 #define CRYPTO4XX_PRNG_LFSR_H 0x00070034 106 106 107 - /** 107 + /* 108 108 * Initialize CRYPTO ENGINE registers, and memory bases. 109 109 */ 110 110 #define PPC4XX_PDR_POLL 0x3ff ··· 123 123 #define PPC4XX_INT_TIMEOUT_CNT 0 124 124 #define PPC4XX_INT_TIMEOUT_CNT_REVB 0x3FF 125 125 #define PPC4XX_INT_CFG 1 126 - /** 126 + /* 127 127 * all follow define are ad hoc 128 128 */ 129 129 #define PPC4XX_RING_RETRY 100 ··· 131 131 #define PPC4XX_SDR_SIZE PPC4XX_NUM_SD 132 132 #define PPC4XX_GDR_SIZE PPC4XX_NUM_GD 133 133 134 - /** 134 + /* 135 135 * Generic Security Association (SA) with all possible fields. These will 136 136 * never likely used except for reference purpose. These structure format 137 137 * can be not changed as the hardware expects them to be layout as defined.
+9 -9
drivers/crypto/amcc/crypto4xx_sa.h
··· 1 1 /* SPDX-License-Identifier: GPL-2.0-or-later */ 2 - /** 2 + /* 3 3 * AMCC SoC PPC4xx Crypto Driver 4 4 * 5 5 * Copyright (c) 2008 Applied Micro Circuits Corporation. ··· 14 14 15 15 #define AES_IV_SIZE 16 16 16 17 - /** 17 + /* 18 18 * Contents of Dynamic Security Association (SA) with all possible fields 19 19 */ 20 20 union dynamic_sa_contents { ··· 122 122 #define SA_AES_KEY_LEN_256 4 123 123 124 124 #define SA_REV2 1 125 - /** 125 + /* 126 126 * The follow defines bits sa_command_1 127 127 * In Basic hash mode this bit define simple hash or hmac. 128 128 * In IPsec mode, this bit define muting control. ··· 172 172 union sa_command_1 sa_command_1; 173 173 } __attribute__((packed)); 174 174 175 - /** 175 + /* 176 176 * State Record for Security Association (SA) 177 177 */ 178 178 struct sa_state_record { ··· 184 184 }; 185 185 } __attribute__((packed)); 186 186 187 - /** 187 + /* 188 188 * Security Association (SA) for AES128 189 189 * 190 190 */ ··· 213 213 #define SA_AES192_LEN (sizeof(struct dynamic_sa_aes192)/4) 214 214 #define SA_AES192_CONTENTS 0x3e000062 215 215 216 - /** 216 + /* 217 217 * Security Association (SA) for AES256 218 218 */ 219 219 struct dynamic_sa_aes256 { ··· 228 228 #define SA_AES256_CONTENTS 0x3e000082 229 229 #define SA_AES_CONTENTS 0x3e000002 230 230 231 - /** 231 + /* 232 232 * Security Association (SA) for AES128 CCM 233 233 */ 234 234 struct dynamic_sa_aes128_ccm { ··· 242 242 #define SA_AES128_CCM_CONTENTS 0x3e000042 243 243 #define SA_AES_CCM_CONTENTS 0x3e000002 244 244 245 - /** 245 + /* 246 246 * Security Association (SA) for AES128_GCM 247 247 */ 248 248 struct dynamic_sa_aes128_gcm { ··· 258 258 #define SA_AES128_GCM_CONTENTS 0x3e000442 259 259 #define SA_AES_GCM_CONTENTS 0x3e000402 260 260 261 - /** 261 + /* 262 262 * Security Association (SA) for HASH160: HMAC-SHA1 263 263 */ 264 264 struct dynamic_sa_hash160 {
+1 -1
drivers/crypto/amcc/crypto4xx_trng.h
··· 1 1 /* SPDX-License-Identifier: GPL-2.0-or-later */ 2 - /** 2 + /* 3 3 * AMCC SoC PPC4xx Crypto Driver 4 4 * 5 5 * Copyright (c) 2008 Applied Micro Circuits Corporation.