aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/crypto_wq.c
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2011-01-03 23:38:44 -0500
committerHerbert Xu <herbert@gondor.apana.org.au>2011-01-04 07:34:08 -0500
commitc73b7d02da9bfb4fadafc118a24ee868708839b6 (patch)
tree8f3a33015c5f81443c34afd528882fe2f77ebe31 /crypto/crypto_wq.c
parent41f2977d40798ce45f4da7a1291039ffbe9e1dbc (diff)
crypto: mark crypto workqueues CPU_INTENSIVE
kcrypto_wq and pcrypt->wq's are used to run ciphers and may consume considerable amount of CPU cycles. Mark both as CPU_INTENSIVE so that they don't block other work items. As the workqueues are primarily used to burn CPU cycles, concurrency levels shouldn't matter much and are left at 1. A higher value may be beneficial and needs investigation. Signed-off-by: Tejun Heo <tj@kernel.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'crypto/crypto_wq.c')
-rw-r--r--crypto/crypto_wq.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/crypto/crypto_wq.c b/crypto/crypto_wq.c
index fdcf6248f152..b980ee1af459 100644
--- a/crypto/crypto_wq.c
+++ b/crypto/crypto_wq.c
@@ -20,7 +20,8 @@ EXPORT_SYMBOL_GPL(kcrypto_wq);
20 20
21static int __init crypto_wq_init(void) 21static int __init crypto_wq_init(void)
22{ 22{
23 kcrypto_wq = create_workqueue("crypto"); 23 kcrypto_wq = alloc_workqueue("crypto",
24 WQ_MEM_RECLAIM | WQ_CPU_INTENSIVE, 1);
24 if (unlikely(!kcrypto_wq)) 25 if (unlikely(!kcrypto_wq))
25 return -ENOMEM; 26 return -ENOMEM;
26 return 0; 27 return 0;