aboutsummaryrefslogtreecommitdiffstats
path: root/fs/fs-writeback.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/fs-writeback.c')
-rw-r--r--fs/fs-writeback.c16
1 files changed, 5 insertions, 11 deletions
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c
index 73c3992b2bb4..517f211a3bd4 100644
--- a/fs/fs-writeback.c
+++ b/fs/fs-writeback.c
@@ -47,17 +47,6 @@ struct wb_writeback_work {
47 struct completion *done; /* set if the caller waits */ 47 struct completion *done; /* set if the caller waits */
48}; 48};
49 49
50const char *wb_reason_name[] = {
51 [WB_REASON_BACKGROUND] = "background",
52 [WB_REASON_TRY_TO_FREE_PAGES] = "try_to_free_pages",
53 [WB_REASON_SYNC] = "sync",
54 [WB_REASON_PERIODIC] = "periodic",
55 [WB_REASON_LAPTOP_TIMER] = "laptop_timer",
56 [WB_REASON_FREE_MORE_MEM] = "free_more_memory",
57 [WB_REASON_FS_FREE_SPACE] = "fs_free_space",
58 [WB_REASON_FORKER_THREAD] = "forker_thread"
59};
60
61/* 50/*
62 * Include the creation of the trace points after defining the 51 * Include the creation of the trace points after defining the
63 * wb_writeback_work structure so that the definition remains local to this 52 * wb_writeback_work structure so that the definition remains local to this
@@ -156,6 +145,7 @@ __bdi_start_writeback(struct backing_dev_info *bdi, long nr_pages,
156 * bdi_start_writeback - start writeback 145 * bdi_start_writeback - start writeback
157 * @bdi: the backing device to write from 146 * @bdi: the backing device to write from
158 * @nr_pages: the number of pages to write 147 * @nr_pages: the number of pages to write
148 * @reason: reason why some writeback work was initiated
159 * 149 *
160 * Description: 150 * Description:
161 * This does WB_SYNC_NONE opportunistic writeback. The IO is only 151 * This does WB_SYNC_NONE opportunistic writeback. The IO is only
@@ -1223,6 +1213,7 @@ static void wait_sb_inodes(struct super_block *sb)
1223 * writeback_inodes_sb_nr - writeback dirty inodes from given super_block 1213 * writeback_inodes_sb_nr - writeback dirty inodes from given super_block
1224 * @sb: the superblock 1214 * @sb: the superblock
1225 * @nr: the number of pages to write 1215 * @nr: the number of pages to write
1216 * @reason: reason why some writeback work initiated
1226 * 1217 *
1227 * Start writeback on some inodes on this super_block. No guarantees are made 1218 * Start writeback on some inodes on this super_block. No guarantees are made
1228 * on how many (if any) will be written, and this function does not wait 1219 * on how many (if any) will be written, and this function does not wait
@@ -1251,6 +1242,7 @@ EXPORT_SYMBOL(writeback_inodes_sb_nr);
1251/** 1242/**
1252 * writeback_inodes_sb - writeback dirty inodes from given super_block 1243 * writeback_inodes_sb - writeback dirty inodes from given super_block
1253 * @sb: the superblock 1244 * @sb: the superblock
1245 * @reason: reason why some writeback work was initiated
1254 * 1246 *
1255 * Start writeback on some inodes on this super_block. No guarantees are made 1247 * Start writeback on some inodes on this super_block. No guarantees are made
1256 * on how many (if any) will be written, and this function does not wait 1248 * on how many (if any) will be written, and this function does not wait
@@ -1265,6 +1257,7 @@ EXPORT_SYMBOL(writeback_inodes_sb);
1265/** 1257/**
1266 * writeback_inodes_sb_if_idle - start writeback if none underway 1258 * writeback_inodes_sb_if_idle - start writeback if none underway
1267 * @sb: the superblock 1259 * @sb: the superblock
1260 * @reason: reason why some writeback work was initiated
1268 * 1261 *
1269 * Invoke writeback_inodes_sb if no writeback is currently underway. 1262 * Invoke writeback_inodes_sb if no writeback is currently underway.
1270 * Returns 1 if writeback was started, 0 if not. 1263 * Returns 1 if writeback was started, 0 if not.
@@ -1285,6 +1278,7 @@ EXPORT_SYMBOL(writeback_inodes_sb_if_idle);
1285 * writeback_inodes_sb_if_idle - start writeback if none underway 1278 * writeback_inodes_sb_if_idle - start writeback if none underway
1286 * @sb: the superblock 1279 * @sb: the superblock
1287 * @nr: the number of pages to write 1280 * @nr: the number of pages to write
1281 * @reason: reason why some writeback work was initiated
1288 * 1282 *
1289 * Invoke writeback_inodes_sb if no writeback is currently underway. 1283 * Invoke writeback_inodes_sb if no writeback is currently underway.
1290 * Returns 1 if writeback was started, 0 if not. 1284 * Returns 1 if writeback was started, 0 if not.