page-writeback.c (f6ef943813ac3085ece7252ea101d663581219f6) | page-writeback.c (ed5b43f15a8e86e3ae939b98bc161ee973ecedf2) |
---|---|
1/* 2 * mm/page-writeback.c. 3 * 4 * Copyright (C) 2002, Linus Torvalds. 5 * 6 * Contains functions related to writing back dirty pages at the 7 * address_space level. 8 * --- 74 unchanged lines hidden (view full) --- 83int dirty_expire_interval = 30 * HZ; 84 85/* 86 * Flag that makes the machine dump writes/reads and block dirtyings. 87 */ 88int block_dump; 89 90/* | 1/* 2 * mm/page-writeback.c. 3 * 4 * Copyright (C) 2002, Linus Torvalds. 5 * 6 * Contains functions related to writing back dirty pages at the 7 * address_space level. 8 * --- 74 unchanged lines hidden (view full) --- 83int dirty_expire_interval = 30 * HZ; 84 85/* 86 * Flag that makes the machine dump writes/reads and block dirtyings. 87 */ 88int block_dump; 89 90/* |
91 * Flag that puts the machine in "laptop mode". | 91 * Flag that puts the machine in "laptop mode". Doubles as a timeout in jiffies: 92 * a full sync is triggered after this time elapses without any disk activity. |
92 */ 93int laptop_mode; 94 95EXPORT_SYMBOL(laptop_mode); 96 97/* End of sysctl-exported parameters */ 98 99 --- 363 unchanged lines hidden (view full) --- 463 464/* 465 * We've spun up the disk and we're in laptop mode: schedule writeback 466 * of all dirty data a few seconds from now. If the flush is already scheduled 467 * then push it back - the user is still using the disk. 468 */ 469void laptop_io_completion(void) 470{ | 93 */ 94int laptop_mode; 95 96EXPORT_SYMBOL(laptop_mode); 97 98/* End of sysctl-exported parameters */ 99 100 --- 363 unchanged lines hidden (view full) --- 464 465/* 466 * We've spun up the disk and we're in laptop mode: schedule writeback 467 * of all dirty data a few seconds from now. If the flush is already scheduled 468 * then push it back - the user is still using the disk. 469 */ 470void laptop_io_completion(void) 471{ |
471 mod_timer(&laptop_mode_wb_timer, jiffies + laptop_mode * HZ); | 472 mod_timer(&laptop_mode_wb_timer, jiffies + laptop_mode); |
472} 473 474/* 475 * We're in laptop mode and we've just synced. The sync's writes will have 476 * caused another writeback to be scheduled by laptop_io_completion. 477 * Nothing needs to be written back anymore, so we unschedule the writeback. 478 */ 479void laptop_sync_completion(void) --- 345 unchanged lines hidden --- | 473} 474 475/* 476 * We're in laptop mode and we've just synced. The sync's writes will have 477 * caused another writeback to be scheduled by laptop_io_completion. 478 * Nothing needs to be written back anymore, so we unschedule the writeback. 479 */ 480void laptop_sync_completion(void) --- 345 unchanged lines hidden --- |