Commit 129f8758 authored by Linus Torvalds's avatar Linus Torvalds

Import 2.3.23

parent df72ed19
......@@ -106,26 +106,21 @@ void invalidate_inode_pages(struct inode * inode)
while (curr != head) {
page = list_entry(curr, struct page, list);
curr = curr->next;
get_page(page);
if (TryLockPage(page)) {
spin_unlock(&pagecache_lock);
wait_on_page(page);
page_cache_release(page);
goto repeat;
}
if (page_count(page) != 2)
printk("hm, busy page invalidated? (not necessarily a bug)\n");
/* We cannot invalidate a locked page */
if (PageLocked(page))
continue;
lru_cache_del(page);
remove_page_from_inode_queue(page);
remove_page_from_hash_queue(page);
page->inode = NULL;
UnlockPage(page);
page_cache_release(page);
page_cache_release(page);
}
spin_unlock(&pagecache_lock);
}
/*
* Truncate the page cache at a set offset, removing the pages
* that are beyond that offset (and zeroing out partial pages).
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment