diff options
| -rw-r--r-- | fs/fs-writeback.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c index 5887328b5a06..55f0d4e51b59 100644 --- a/fs/fs-writeback.c +++ b/fs/fs-writeback.c | |||
| @@ -49,15 +49,15 @@ struct wb_writeback_args { | |||
| 49 | * Work items for the bdi_writeback threads | 49 | * Work items for the bdi_writeback threads |
| 50 | */ | 50 | */ |
| 51 | struct bdi_work { | 51 | struct bdi_work { |
| 52 | struct list_head list; | 52 | struct list_head list; /* pending work list */ |
| 53 | struct rcu_head rcu_head; | 53 | struct rcu_head rcu_head; /* for RCU free/clear of work */ |
| 54 | 54 | ||
| 55 | unsigned long seen; | 55 | unsigned long seen; /* threads that have seen this work */ |
| 56 | atomic_t pending; | 56 | atomic_t pending; /* number of threads still to do work */ |
| 57 | 57 | ||
| 58 | struct wb_writeback_args args; | 58 | struct wb_writeback_args args; /* writeback arguments */ |
| 59 | 59 | ||
| 60 | unsigned long state; | 60 | unsigned long state; /* flag bits, see WS_* */ |
| 61 | }; | 61 | }; |
| 62 | 62 | ||
| 63 | enum { | 63 | enum { |
| @@ -758,7 +758,11 @@ static long wb_writeback(struct bdi_writeback *wb, | |||
| 758 | 758 | ||
| 759 | /* | 759 | /* |
| 760 | * Return the next bdi_work struct that hasn't been processed by this | 760 | * Return the next bdi_work struct that hasn't been processed by this |
| 761 | * wb thread yet | 761 | * wb thread yet. ->seen is initially set for each thread that exists |
| 762 | * for this device, when a thread first notices a piece of work it | ||
| 763 | * clears its bit. Depending on writeback type, the thread will notify | ||
| 764 | * completion on either receiving the work (WB_SYNC_NONE) or after | ||
| 765 | * it is done (WB_SYNC_ALL). | ||
| 762 | */ | 766 | */ |
| 763 | static struct bdi_work *get_next_work_item(struct backing_dev_info *bdi, | 767 | static struct bdi_work *get_next_work_item(struct backing_dev_info *bdi, |
| 764 | struct bdi_writeback *wb) | 768 | struct bdi_writeback *wb) |
