lkml.org 
[lkml]   [2019]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
SubjectRe: [PATCH -next] crypto: atmel - remove set but not used variable 'alg_name'
Date
On 24/04/2019 at 09:53, Yue Haibing wrote:
> From: YueHaibing <yuehaibing@huawei.com>
>
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> drivers/crypto/atmel-tdes.c: In function 'atmel_tdes_setkey':
> drivers/crypto/atmel-tdes.c:803:14: warning: variable 'alg_name' set but not used [-Wunused-but-set-variable]
>
> It is not used any more since
> commit 52ea3cd2917b ("crypto: atmel - Forbid 2-key 3DES in FIPS mode")
>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>

Looks good to me:
Reviewed-by: Nicolas Ferre <nicolas.ferre@microchip.com>

> ---
> drivers/crypto/atmel-tdes.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/crypto/atmel-tdes.c b/drivers/crypto/atmel-tdes.c
> index 12492d9..fa76620 100644
> --- a/drivers/crypto/atmel-tdes.c
> +++ b/drivers/crypto/atmel-tdes.c
> @@ -800,12 +800,9 @@ static int atmel_tdes_setkey(struct crypto_ablkcipher *tfm, const u8 *key,
> unsigned int keylen)
> {
> struct atmel_tdes_ctx *ctx = crypto_ablkcipher_ctx(tfm);
> - const char *alg_name;
> u32 flags;
> int err;
>
> - alg_name = crypto_tfm_alg_name(crypto_ablkcipher_tfm(tfm));
> -
> flags = crypto_ablkcipher_get_flags(tfm);
> err = __des3_verify_key(&flags, key);
> if (unlikely(err)) {
>


--
Nicolas Ferre
\
 
 \ /
  Last update: 2019-04-24 10:56    [W:0.055 / U:67.380 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site