1
0
Fork 0

crypto: talitos - use IS_ENABLED() in has_ftr_sec1()

This patch rewrites has_ftr_sec1() using IS_ENABLED()
instead of #ifdefs

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
alistair/sunxi64-5.4-dsi
Christophe Leroy 2019-05-21 13:34:21 +00:00 committed by Herbert Xu
parent fbb8d46e16
commit 89b32dfe00
1 changed files with 5 additions and 7 deletions

View File

@ -164,13 +164,11 @@ struct talitos_private {
*/
static inline bool has_ftr_sec1(struct talitos_private *priv)
{
#if defined(CONFIG_CRYPTO_DEV_TALITOS1) && defined(CONFIG_CRYPTO_DEV_TALITOS2)
return priv->features & TALITOS_FTR_SEC1 ? true : false;
#elif defined(CONFIG_CRYPTO_DEV_TALITOS1)
return true;
#else
return false;
#endif
if (IS_ENABLED(CONFIG_CRYPTO_DEV_TALITOS1) &&
IS_ENABLED(CONFIG_CRYPTO_DEV_TALITOS2))
return priv->features & TALITOS_FTR_SEC1;
return IS_ENABLED(CONFIG_CRYPTO_DEV_TALITOS1);
}
/*