@@ -155,8 +155,6 @@ static inline void fsverity_init_signature(void)
/* verify.c */
-void __init fsverity_init_workqueue(void);
-
int fsverity_read_merkle_tree_block(struct inode *inode,
const struct merkle_tree_params *params,
int level, u64 pos, unsigned long ra_bytes,
@@ -66,7 +66,6 @@ static int __init fsverity_init(void)
{
fsverity_check_hash_algs();
fsverity_init_info_cache();
- fsverity_init_workqueue();
fsverity_init_sysctl();
fsverity_init_signature();
fsverity_init_bpf();
@@ -10,8 +10,6 @@
#include <crypto/hash.h>
#include <linux/bio.h>
-static struct workqueue_struct *fsverity_read_workqueue;
-
/*
* Returns true if the hash @block with index @hblock_idx in the merkle tree
* for @inode has already been verified.
@@ -375,27 +373,10 @@ EXPORT_SYMBOL_GPL(fsverity_init_wq);
void fsverity_enqueue_verify_work(struct super_block *sb,
struct work_struct *work)
{
- queue_work(sb->s_verity_wq ?: fsverity_read_workqueue, work);
+ queue_work(sb->s_verity_wq, work);
}
EXPORT_SYMBOL_GPL(fsverity_enqueue_verify_work);
-void __init fsverity_init_workqueue(void)
-{
- /*
- * Use a high-priority workqueue to prioritize verification work, which
- * blocks reads from completing, over regular application tasks.
- *
- * For performance reasons, don't use an unbound workqueue. Using an
- * unbound workqueue for crypto operations causes excessive scheduler
- * latency on ARM64.
- */
- fsverity_read_workqueue = alloc_workqueue("fsverity_read_queue",
- WQ_HIGHPRI,
- num_online_cpus());
- if (!fsverity_read_workqueue)
- panic("failed to allocate fsverity_read_queue");
-}
-
/**
* fsverity_read_merkle_tree_block() - read Merkle tree block
* @inode: inode to which this Merkle tree block belongs