diff options
author | Fengguang Wu <fengguang.wu@intel.com> | 2013-12-09 20:08:19 +0800 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2013-12-09 20:08:19 +0800 |
commit | d1dd206c2abf678889445e63ecc949e9274f5806 (patch) | |
tree | f4e13b84d6acfaa6b9a859ce8922249c653aadd0 /drivers/crypto/ccp/ccp-crypto-aes.c | |
parent | f7b2b5dd6a62a47e871627c71ed01aa3482154d9 (diff) | |
download | linux-stable-d1dd206c2abf678889445e63ecc949e9274f5806.tar.gz linux-stable-d1dd206c2abf678889445e63ecc949e9274f5806.tar.bz2 linux-stable-d1dd206c2abf678889445e63ecc949e9274f5806.zip |
crytpo: ccp - fix coccinelle warnings
drivers/crypto/ccp/ccp-crypto-aes.c:344:1-7: Replace memcpy with struct assignment
drivers/crypto/ccp/ccp-crypto-sha.c:398:1-7: Replace memcpy with struct assignment
drivers/crypto/ccp/ccp-dev.c:578:2-3: Unneeded semicolon
/c/kernel-tests/src/cocci/drivers/crypto/ccp/ccp-dev.c:565:2-3: Unneeded semicolon
Generated by: coccinelle/misc/memcpy-assign.cocci
CC: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/ccp/ccp-crypto-aes.c')
-rw-r--r-- | drivers/crypto/ccp/ccp-crypto-aes.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/crypto/ccp/ccp-crypto-aes.c b/drivers/crypto/ccp/ccp-crypto-aes.c index f302a5b7473b..c0befdb2240b 100644 --- a/drivers/crypto/ccp/ccp-crypto-aes.c +++ b/drivers/crypto/ccp/ccp-crypto-aes.c @@ -341,7 +341,7 @@ static int ccp_register_aes_alg(struct list_head *head, /* Copy the defaults and override as necessary */ alg = &ccp_alg->alg; - memcpy(alg, def->alg_defaults, sizeof(*alg)); + *alg = *def->alg_defaults; snprintf(alg->cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name); snprintf(alg->cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s", def->driver_name); |