aboutsummaryrefslogtreecommitdiffstats
path: root/crypto
diff options
context:
space:
mode:
Diffstat (limited to 'crypto')
-rw-r--r--crypto/cipher.c2
-rw-r--r--crypto/digest.c2
-rw-r--r--crypto/internal.h4
3 files changed, 4 insertions, 4 deletions
diff --git a/crypto/cipher.c b/crypto/cipher.c
index aebc4a2adc80..f573c59ed9dc 100644
--- a/crypto/cipher.c
+++ b/crypto/cipher.c
@@ -145,7 +145,7 @@ static int crypt(const struct cipher_desc *desc,
145 if (!nbytes) 145 if (!nbytes)
146 break; 146 break;
147 147
148 crypto_yield(tfm); 148 crypto_yield(tfm->crt_flags);
149 } 149 }
150 150
151 if (buffer) 151 if (buffer)
diff --git a/crypto/digest.c b/crypto/digest.c
index 19e75563776b..96244a528844 100644
--- a/crypto/digest.c
+++ b/crypto/digest.c
@@ -55,7 +55,7 @@ static void update(struct crypto_tfm *tfm,
55 tfm->__crt_alg->cra_digest.dia_update(tfm, p, 55 tfm->__crt_alg->cra_digest.dia_update(tfm, p,
56 bytes_from_page); 56 bytes_from_page);
57 crypto_kunmap(src, 0); 57 crypto_kunmap(src, 0);
58 crypto_yield(tfm); 58 crypto_yield(tfm->crt_flags);
59 offset = 0; 59 offset = 0;
60 pg++; 60 pg++;
61 l -= bytes_from_page; 61 l -= bytes_from_page;
diff --git a/crypto/internal.h b/crypto/internal.h
index b110b979b988..7dc04efb55c6 100644
--- a/crypto/internal.h
+++ b/crypto/internal.h
@@ -67,9 +67,9 @@ static inline void crypto_kunmap(void *vaddr, int out)
67 kunmap_atomic(vaddr, crypto_kmap_type(out)); 67 kunmap_atomic(vaddr, crypto_kmap_type(out));
68} 68}
69 69
70static inline void crypto_yield(struct crypto_tfm *tfm) 70static inline void crypto_yield(u32 flags)
71{ 71{
72 if (tfm->crt_flags & CRYPTO_TFM_REQ_MAY_SLEEP) 72 if (flags & CRYPTO_TFM_REQ_MAY_SLEEP)
73 cond_resched(); 73 cond_resched();
74} 74}
75 75