X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=crypto%2Finternal.h;h=37aa652ce5ce6f89e4738ac07dd770b8df4a6ac9;hb=49e31cbac5be2202f351626fd4fb33ad4d4819b8;hp=37515beafc8ce44ff501d15d617968248656b59f;hpb=8066eff0a1a0703ad901dbe5646a47dbfc089ef2;p=linux-2.6 diff --git a/crypto/internal.h b/crypto/internal.h index 37515beafc..37aa652ce5 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(); }