diff options
Diffstat (limited to 'include/linux/backing-dev.h')
-rw-r--r-- | include/linux/backing-dev.h | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/include/linux/backing-dev.h b/include/linux/backing-dev.h index e9aec0d099df..7628219e5386 100644 --- a/include/linux/backing-dev.h +++ b/include/linux/backing-dev.h | |||
@@ -45,22 +45,21 @@ enum bdi_stat_item { | |||
45 | #define BDI_STAT_BATCH (8*(1+ilog2(nr_cpu_ids))) | 45 | #define BDI_STAT_BATCH (8*(1+ilog2(nr_cpu_ids))) |
46 | 46 | ||
47 | struct bdi_writeback { | 47 | struct bdi_writeback { |
48 | struct list_head list; /* hangs off the bdi */ | 48 | struct backing_dev_info *bdi; /* our parent bdi */ |
49 | |||
50 | struct backing_dev_info *bdi; /* our parent bdi */ | ||
51 | unsigned int nr; | 49 | unsigned int nr; |
52 | 50 | ||
53 | unsigned long last_old_flush; /* last old data flush */ | 51 | unsigned long last_old_flush; /* last old data flush */ |
52 | unsigned long last_active; /* last time bdi thread was active */ | ||
54 | 53 | ||
55 | struct task_struct *task; /* writeback task */ | 54 | struct task_struct *task; /* writeback thread */ |
56 | struct list_head b_dirty; /* dirty inodes */ | 55 | struct timer_list wakeup_timer; /* used for delayed bdi thread wakeup */ |
57 | struct list_head b_io; /* parked for writeback */ | 56 | struct list_head b_dirty; /* dirty inodes */ |
58 | struct list_head b_more_io; /* parked for more writeback */ | 57 | struct list_head b_io; /* parked for writeback */ |
58 | struct list_head b_more_io; /* parked for more writeback */ | ||
59 | }; | 59 | }; |
60 | 60 | ||
61 | struct backing_dev_info { | 61 | struct backing_dev_info { |
62 | struct list_head bdi_list; | 62 | struct list_head bdi_list; |
63 | struct rcu_head rcu_head; | ||
64 | unsigned long ra_pages; /* max readahead in PAGE_CACHE_SIZE units */ | 63 | unsigned long ra_pages; /* max readahead in PAGE_CACHE_SIZE units */ |
65 | unsigned long state; /* Always use atomic bitops on this */ | 64 | unsigned long state; /* Always use atomic bitops on this */ |
66 | unsigned int capabilities; /* Device capabilities */ | 65 | unsigned int capabilities; /* Device capabilities */ |
@@ -80,8 +79,7 @@ struct backing_dev_info { | |||
80 | unsigned int max_ratio, max_prop_frac; | 79 | unsigned int max_ratio, max_prop_frac; |
81 | 80 | ||
82 | struct bdi_writeback wb; /* default writeback info for this bdi */ | 81 | struct bdi_writeback wb; /* default writeback info for this bdi */ |
83 | spinlock_t wb_lock; /* protects update side of wb_list */ | 82 | spinlock_t wb_lock; /* protects work_list */ |
84 | struct list_head wb_list; /* the flusher threads hanging off this bdi */ | ||
85 | 83 | ||
86 | struct list_head work_list; | 84 | struct list_head work_list; |
87 | 85 | ||
@@ -105,9 +103,10 @@ void bdi_unregister(struct backing_dev_info *bdi); | |||
105 | int bdi_setup_and_register(struct backing_dev_info *, char *, unsigned int); | 103 | int bdi_setup_and_register(struct backing_dev_info *, char *, unsigned int); |
106 | void bdi_start_writeback(struct backing_dev_info *bdi, long nr_pages); | 104 | void bdi_start_writeback(struct backing_dev_info *bdi, long nr_pages); |
107 | void bdi_start_background_writeback(struct backing_dev_info *bdi); | 105 | void bdi_start_background_writeback(struct backing_dev_info *bdi); |
108 | int bdi_writeback_task(struct bdi_writeback *wb); | 106 | int bdi_writeback_thread(void *data); |
109 | int bdi_has_dirty_io(struct backing_dev_info *bdi); | 107 | int bdi_has_dirty_io(struct backing_dev_info *bdi); |
110 | void bdi_arm_supers_timer(void); | 108 | void bdi_arm_supers_timer(void); |
109 | void bdi_wakeup_thread_delayed(struct backing_dev_info *bdi); | ||
111 | 110 | ||
112 | extern spinlock_t bdi_lock; | 111 | extern spinlock_t bdi_lock; |
113 | extern struct list_head bdi_list; | 112 | extern struct list_head bdi_list; |