aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2010-07-06 02:59:53 -0400
committerJens Axboe <jaxboe@fusionio.com>2010-07-06 02:59:53 -0400
commit83ba7b071f30f7c01f72518ad72d5cd203c27502 (patch)
tree4737320dcce72cfff4d87d835e4f78428eca7ef5 /include/linux
parentedadfb10ba35da7253541e4155aa92eff758ebe6 (diff)
writeback: simplify the write back thread queue
First remove items from work_list as soon as we start working on them. This means we don't have to track any pending or visited state and can get rid of all the RCU magic freeing the work items - we can simply free them once the operation has finished. Second use a real completion for tracking synchronous requests - if the caller sets the completion pointer we complete it, otherwise use it as a boolean indicator that we can free the work item directly. Third unify struct wb_writeback_args and struct bdi_work into a single data structure, wb_writeback_work. Previous we set all parameters into a struct wb_writeback_args, copied it into struct bdi_work, copied it again on the stack to use it there. Instead of just allocate one structure dynamically or on the stack and use it all the way through the stack. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/backing-dev.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/include/linux/backing-dev.h b/include/linux/backing-dev.h
index 9ae2889096b6..e9aec0d099df 100644
--- a/include/linux/backing-dev.h
+++ b/include/linux/backing-dev.h
@@ -82,8 +82,6 @@ struct backing_dev_info {
82 struct bdi_writeback wb; /* default writeback info for this bdi */ 82 struct bdi_writeback wb; /* default writeback info for this bdi */
83 spinlock_t wb_lock; /* protects update side of wb_list */ 83 spinlock_t wb_lock; /* protects update side of wb_list */
84 struct list_head wb_list; /* the flusher threads hanging off this bdi */ 84 struct list_head wb_list; /* the flusher threads hanging off this bdi */
85 unsigned long wb_mask; /* bitmask of registered tasks */
86 unsigned int wb_cnt; /* number of registered tasks */
87 85
88 struct list_head work_list; 86 struct list_head work_list;
89 87