Skip to contentSkip to conversation

swap: fix "add per-partition lock for swapfile" for nommu

PATCH In review Arnd Bergmann 2 participants 2 messages Jan 25, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 swap: fix "add per-partition lock for swapfile" for nommu

The patch "swap: add per-partition lock for swapfile" made the nr_swap_pages variable unaccessible but forgot to change the mm/nommu.c file that uses it. This does the trivial conversion to let us build nommu kernels again

mm/nommu.c +1 -1
index b7fdaa7..bf74898 100644
@@ -1906,7 +1906,7 @@ int __vm_enough_memory(struct mm_struct *mm, long pages, int cap_sys_admin)
 		 */
 		free -= global_page_state(NR_SHMEM);
 
-		free += nr_swap_pages;
+		free += get_nr_swap_pages();
 
 		/*
 		 * Any slabs which are created with the

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>

Reviewed-by on v1 1/1
#1 lore raw
Quoted 6 lines · Arnd Bergmann

The patch "swap: add per-partition lock for swapfile" made the nr_swap_pages variable unaccessible but forgot to change the mm/nommu.c file that uses it. This does the trivial conversion to let us build nommu kernels again

Signature · 7 lines
All rights reversed

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected].  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>