Commit 079a7174 authored by Gilad Ben-Yossef's avatar Gilad Ben-Yossef Committed by Greg Kroah-Hartman

staging: ccree: avoid constant comparison

Re-write predicate to avoid constant comparison.
Signed-off-by: default avatarGilad Ben-Yossef <gilad@benyossef.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 698592e2
...@@ -1572,7 +1572,7 @@ static int config_ccm_adata(struct aead_request *req) ...@@ -1572,7 +1572,7 @@ static int config_ccm_adata(struct aead_request *req)
/* taken from crypto/ccm.c */ /* taken from crypto/ccm.c */
/* 2 <= L <= 8, so 1 <= L' <= 7. */ /* 2 <= L <= 8, so 1 <= L' <= 7. */
if (2 > l || l > 8) { if (l < 2 || l > 8) {
SSI_LOG_ERR("illegal iv value %X\n", req->iv[0]); SSI_LOG_ERR("illegal iv value %X\n", req->iv[0]);
return -EINVAL; return -EINVAL;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment