From: Andrew Morton <[email-masked]>

Cc: Andrea Arcangeli <[email-masked]>
Signed-off-by: Andrew Morton <[email-masked]>
---

 kernel/fork.c       |    4 ++++
 mm/page-writeback.c |    7 ++++---
 2 files changed, 8 insertions(+), 3 deletions(-)

diff -puN kernel/fork.c~per-task-predictive-write-throttling-1-tweaks kernel/fork.c
--- devel/kernel/fork.c~per-task-predictive-write-throttling-1-tweaks	2005-09-14 21:13:53.000000000 -0700
+++ devel-akpm/kernel/fork.c	2005-09-14 21:13:53.000000000 -0700
@@ -962,6 +962,10 @@ static task_t *copy_process(unsigned lon
 	p->syscw = 0;		/* I/O counter: write syscalls */
 	acct_clear_integrals(p);
 
+	p->balance_dirty_state.future_dirty = 0;
+	p->balance_dirty_state.last_sync = 0;
+	p->balance_dirty_state.rate_limit = 0;
+
  	p->it_virt_expires = cputime_zero;
 	p->it_prof_expires = cputime_zero;
  	p->it_sched_expires = 0;
diff -puN mm/page-writeback.c~per-task-predictive-write-throttling-1-tweaks mm/page-writeback.c
--- devel/mm/page-writeback.c~per-task-predictive-write-throttling-1-tweaks	2005-09-14 21:13:53.000000000 -0700
+++ devel-akpm/mm/page-writeback.c	2005-09-14 21:13:53.000000000 -0700
@@ -262,8 +262,9 @@ static void balance_dirty_pages(struct a
 		pdflush_operation(background_writeout, 0);
 }
 
-static int task_balance_dirty_pages(struct address_space *mapping) {
-	struct balance_dirty_state * state;
+static int task_balance_dirty_pages(struct address_space *mapping)
+{
+	struct balance_dirty_state *state;
 	int need_balance_dirty;
 	unsigned long future_dirty;
 	int rate_limit;
@@ -298,7 +299,7 @@ static int task_balance_dirty_pages(stru
 	if (need_balance_dirty)
 		balance_dirty_pages(mapping, future_dirty);
 
- out:
+out:
 	return need_balance_dirty;
 }
 
_