diff options
author | Anton Vorontsov <cbouatmailru@gmail.com> | 2012-01-04 00:09:35 -0500 |
---|---|---|
committer | Anton Vorontsov <cbouatmailru@gmail.com> | 2012-01-04 00:09:35 -0500 |
commit | 251f39fe42dae863bd24e30864e6b66076ba076d (patch) | |
tree | c804944bc17f3836d19cc8b5bc611dd1fb0ea915 /include/linux/backing-dev.h | |
parent | 9b8872273af6983b246252a6508fa7cf34c69d6e (diff) | |
parent | 35b4c01e29bdd9632dabf9784ed3486333f00427 (diff) |
Merge branch 'power-supply-scope' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen
Diffstat (limited to 'include/linux/backing-dev.h')
-rw-r--r-- | include/linux/backing-dev.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/include/linux/backing-dev.h b/include/linux/backing-dev.h index 3b2f9cb82986..b1038bd686ac 100644 --- a/include/linux/backing-dev.h +++ b/include/linux/backing-dev.h | |||
@@ -40,6 +40,7 @@ typedef int (congested_fn)(void *, int); | |||
40 | enum bdi_stat_item { | 40 | enum bdi_stat_item { |
41 | BDI_RECLAIMABLE, | 41 | BDI_RECLAIMABLE, |
42 | BDI_WRITEBACK, | 42 | BDI_WRITEBACK, |
43 | BDI_DIRTIED, | ||
43 | BDI_WRITTEN, | 44 | BDI_WRITTEN, |
44 | NR_BDI_STAT_ITEMS | 45 | NR_BDI_STAT_ITEMS |
45 | }; | 46 | }; |
@@ -74,10 +75,20 @@ struct backing_dev_info { | |||
74 | struct percpu_counter bdi_stat[NR_BDI_STAT_ITEMS]; | 75 | struct percpu_counter bdi_stat[NR_BDI_STAT_ITEMS]; |
75 | 76 | ||
76 | unsigned long bw_time_stamp; /* last time write bw is updated */ | 77 | unsigned long bw_time_stamp; /* last time write bw is updated */ |
78 | unsigned long dirtied_stamp; | ||
77 | unsigned long written_stamp; /* pages written at bw_time_stamp */ | 79 | unsigned long written_stamp; /* pages written at bw_time_stamp */ |
78 | unsigned long write_bandwidth; /* the estimated write bandwidth */ | 80 | unsigned long write_bandwidth; /* the estimated write bandwidth */ |
79 | unsigned long avg_write_bandwidth; /* further smoothed write bw */ | 81 | unsigned long avg_write_bandwidth; /* further smoothed write bw */ |
80 | 82 | ||
83 | /* | ||
84 | * The base dirty throttle rate, re-calculated on every 200ms. | ||
85 | * All the bdi tasks' dirty rate will be curbed under it. | ||
86 | * @dirty_ratelimit tracks the estimated @balanced_dirty_ratelimit | ||
87 | * in small steps and is much more smooth/stable than the latter. | ||
88 | */ | ||
89 | unsigned long dirty_ratelimit; | ||
90 | unsigned long balanced_dirty_ratelimit; | ||
91 | |||
81 | struct prop_local_percpu completions; | 92 | struct prop_local_percpu completions; |
82 | int dirty_exceeded; | 93 | int dirty_exceeded; |
83 | 94 | ||
@@ -107,7 +118,8 @@ int bdi_register(struct backing_dev_info *bdi, struct device *parent, | |||
107 | int bdi_register_dev(struct backing_dev_info *bdi, dev_t dev); | 118 | int bdi_register_dev(struct backing_dev_info *bdi, dev_t dev); |
108 | void bdi_unregister(struct backing_dev_info *bdi); | 119 | void bdi_unregister(struct backing_dev_info *bdi); |
109 | int bdi_setup_and_register(struct backing_dev_info *, char *, unsigned int); | 120 | int bdi_setup_and_register(struct backing_dev_info *, char *, unsigned int); |
110 | void bdi_start_writeback(struct backing_dev_info *bdi, long nr_pages); | 121 | void bdi_start_writeback(struct backing_dev_info *bdi, long nr_pages, |
122 | enum wb_reason reason); | ||
111 | void bdi_start_background_writeback(struct backing_dev_info *bdi); | 123 | void bdi_start_background_writeback(struct backing_dev_info *bdi); |
112 | int bdi_writeback_thread(void *data); | 124 | int bdi_writeback_thread(void *data); |
113 | int bdi_has_dirty_io(struct backing_dev_info *bdi); | 125 | int bdi_has_dirty_io(struct backing_dev_info *bdi); |