summaryrefslogtreecommitdiff
path: root/include/linux/iocontext.h
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2021-12-09 07:31:31 +0100
committerJens Axboe <axboe@kernel.dk>2021-12-16 10:59:02 -0700
commit5ef1630586317e92c9ebd7b4ce48f393b7ff790f (patch)
tree571bdd14cf7ccd96bb8a003f77c3f249658c09c7 /include/linux/iocontext.h
parent90b627f5426ce144cdd4ea585d1f7812359a1a6a (diff)
block: only build the icq tracking code when needed
Only bfq needs to code to track icq, so make it conditional. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jan Kara <jack@suse.cz> Link: https://lore.kernel.org/r/20211209063131.18537-12-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux/iocontext.h')
-rw-r--r--include/linux/iocontext.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/linux/iocontext.h b/include/linux/iocontext.h
index 648331f35fc6..14f7eaf1b443 100644
--- a/include/linux/iocontext.h
+++ b/include/linux/iocontext.h
@@ -100,16 +100,18 @@ struct io_context {
atomic_long_t refcount;
atomic_t active_ref;
+ unsigned short ioprio;
+
+#ifdef CONFIG_BLK_ICQ
/* all the fields below are protected by this lock */
spinlock_t lock;
- unsigned short ioprio;
-
struct radix_tree_root icq_tree;
struct io_cq __rcu *icq_hint;
struct hlist_head icq_list;
struct work_struct release_work;
+#endif /* CONFIG_BLK_ICQ */
};
struct task_struct;