diff options
Diffstat (limited to 'fs/bio-integrity.c')
-rw-r--r-- | fs/bio-integrity.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/fs/bio-integrity.c b/fs/bio-integrity.c index 4d0ff5ee27b8..9c5e6b2cd11a 100644 --- a/fs/bio-integrity.c +++ b/fs/bio-integrity.c | |||
@@ -761,6 +761,9 @@ int bioset_integrity_create(struct bio_set *bs, int pool_size) | |||
761 | { | 761 | { |
762 | unsigned int max_slab = vecs_to_idx(BIO_MAX_PAGES); | 762 | unsigned int max_slab = vecs_to_idx(BIO_MAX_PAGES); |
763 | 763 | ||
764 | if (bs->bio_integrity_pool) | ||
765 | return 0; | ||
766 | |||
764 | bs->bio_integrity_pool = | 767 | bs->bio_integrity_pool = |
765 | mempool_create_slab_pool(pool_size, bip_slab[max_slab].slab); | 768 | mempool_create_slab_pool(pool_size, bip_slab[max_slab].slab); |
766 | 769 | ||
@@ -782,7 +785,12 @@ void __init bio_integrity_init(void) | |||
782 | { | 785 | { |
783 | unsigned int i; | 786 | unsigned int i; |
784 | 787 | ||
785 | kintegrityd_wq = create_workqueue("kintegrityd"); | 788 | /* |
789 | * kintegrityd won't block much but may burn a lot of CPU cycles. | ||
790 | * Make it highpri CPU intensive wq with max concurrency of 1. | ||
791 | */ | ||
792 | kintegrityd_wq = alloc_workqueue("kintegrityd", WQ_MEM_RECLAIM | | ||
793 | WQ_HIGHPRI | WQ_CPU_INTENSIVE, 1); | ||
786 | if (!kintegrityd_wq) | 794 | if (!kintegrityd_wq) |
787 | panic("Failed to create kintegrityd\n"); | 795 | panic("Failed to create kintegrityd\n"); |
788 | 796 | ||