crypto: hisilicon/hpre - add 'default' for switch statement

Return error immediately if it goto 'default' path.

Signed-off-by: Hui Tang <tanghui20@huawei.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
Hui Tang 2021-05-12 14:27:11 +08:00 committed by Herbert Xu
parent 0c176d8d7d
commit 302e909cb2
1 changed files with 2 additions and 2 deletions

View File

@ -623,10 +623,10 @@ static int hpre_is_dh_params_length_valid(unsigned int key_sz)
case _HPRE_DH_GRP15:
case _HPRE_DH_GRP16:
return 0;
}
default:
return -EINVAL;
}
}
static int hpre_dh_set_params(struct hpre_ctx *ctx, struct dh *params)
{