Signed-off-by: Christoph Lameter --- mm/vmscan.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) Index: linux-2.6/mm/vmscan.c =================================================================== --- linux-2.6.orig/mm/vmscan.c 2007-08-14 07:34:55.000000000 -0700 +++ linux-2.6/mm/vmscan.c 2007-08-14 08:21:58.000000000 -0700 @@ -381,10 +381,12 @@ static pageout_t pageout(struct page *pa */ int remove_mapping(struct address_space *mapping, struct page *page) { + unsigned long flags; + BUG_ON(!PageLocked(page)); BUG_ON(mapping != page_mapping(page)); - write_lock_irq(&mapping->tree_lock); + write_lock_irqsave(&mapping->tree_lock, flags); /* * The non racy check for a busy page. * @@ -419,19 +421,19 @@ int remove_mapping(struct address_space if (PageSwapCache(page)) { swp_entry_t swap = { .val = page_private(page) }; __delete_from_swap_cache(page); - write_unlock_irq(&mapping->tree_lock); + write_unlock_irqrestore(&mapping->tree_lock, flags); swap_free(swap); __put_page(page); /* The pagecache ref */ return 1; } __remove_from_page_cache(page); - write_unlock_irq(&mapping->tree_lock); + write_unlock_irqrestore(&mapping->tree_lock, flags); __put_page(page); return 1; cannot_free: - write_unlock_irq(&mapping->tree_lock); + write_unlock_irqrestore(&mapping->tree_lock, flags); return 0; } -- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/