X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=crypto%2Finternal.h;h=37aa652ce5ce6f89e4738ac07dd770b8df4a6ac9;hb=1b40efd772f4419fbc1a8940506424246985c333;hp=37515beafc8ce44ff501d15d617968248656b59f;hpb=c94c0d201f1c1a62184f4f220c1615347aafbee7;p=mv-sheeva.git diff --git a/crypto/internal.h b/crypto/internal.h index 37515beafc8..37aa652ce5c 100644 --- a/crypto/internal.h +++ b/crypto/internal.h @@ -17,6 +17,7 @@ #include #include #include +#include #include extern enum km_type crypto_km_types[]; @@ -38,7 +39,7 @@ static inline void crypto_kunmap(void *vaddr, int out) static inline void crypto_yield(struct crypto_tfm *tfm) { - if (!in_atomic()) + if (tfm->crt_flags & CRYPTO_TFM_REQ_MAY_SLEEP) cond_resched(); }