Merge branch 'for-4.8/upstream-fixes' into for-next
[deliverable/linux.git] / include / crypto / algapi.h
index 0483f652ac279db474d7fc51d03a20716138f325..8637cdfe382a4d8ff2542ac9ccab2170fc48546a 100644 (file)
@@ -442,8 +442,10 @@ static inline int crypto_memneq(const void *a, const void *b, size_t size)
 
 static inline void crypto_yield(u32 flags)
 {
+#if !defined(CONFIG_PREEMPT) || defined(CONFIG_PREEMPT_VOLUNTARY)
        if (flags & CRYPTO_TFM_REQ_MAY_SLEEP)
                cond_resched();
+#endif
 }
 
 #endif /* _CRYPTO_ALGAPI_H */
This page took 0.024205 seconds and 5 git commands to generate.