Index: linux-2.6.20/include/linux/cpuset.h =================================================================== --- linux-2.6.20.orig/include/linux/cpuset.h 2007-02-14 14:11:39.000000000 -0800 +++ linux-2.6.20/include/linux/cpuset.h 2007-02-14 14:15:23.000000000 -0800 @@ -79,10 +79,11 @@ * We need macros since struct address_space is not defined yet */ #if MAX_NUMNODES <= BITS_PER_LONG -#define cpuset_update_dirty_nodes(__mapping, __node) \ +#define cpuset_update_dirty_nodes(__mapping, __page) \ do { \ - if (!node_isset((__node, (__mapping)->dirty_nodes))) \ - node_set((__node), (__mapping)->dirty_inodes); \ + int node = page_to_nid(__page); \ + if (!node_isset(node, (__mapping)->dirty_nodes)) \ + node_set(node, (__mapping)->dirty_nodes); \ } while (0) #define cpuset_clear_dirty_nodes(__mapping) \ Index: linux-2.6.20/mm/page-writeback.c =================================================================== --- linux-2.6.20.orig/mm/page-writeback.c 2007-02-14 13:48:35.000000000 -0800 +++ linux-2.6.20/mm/page-writeback.c 2007-02-14 14:11:21.000000000 -0800 @@ -169,8 +169,7 @@ int unmapped_ratio; long background; long dirty; - unsigned long dirtyable_memory = determine_dirtyable_memory(); - unsigned long highmem_dirtyable = 0; + unsigned long dirtyable_memory; unsigned long nr_mapped; struct task_struct *tsk; int is_subset = 0; @@ -190,7 +189,7 @@ */ is_subset = 1; memset(dl, 0, sizeof(struct dirty_limits)); - available_memory = 0; + dirtyable_memory = 0; nr_mapped = 0; for_each_node_mask(node, *nodes) { if (!node_online(node))