Commit c583dc59 authored by David Mosberger's avatar David Mosberger Committed by Linus Torvalds

[PATCH] pass "page" pointer to clear_user_page()/copy_user_page()

Hi Linus,

Are you willing to change the interfaces of clear_user_page() and
copy_user_page() so that they can receive the relevant page pointer as
a separate argument?  I need this on ia64 to implement the lazy-cache
flushing scheme.

I believe PPC would also benefit from this.

	--david
parent 9d64273c
......@@ -30,8 +30,8 @@
#endif
#define clear_user_page(page, vaddr) clear_page(page)
#define copy_user_page(to, from, vaddr) copy_page(to, from)
#define clear_user_page(page, vaddr, pg) clear_page(page)
#define copy_user_page(to, from, vaddr, pg) copy_page(to, from)
/*
* These are used to make use of C type-checking..
......
......@@ -77,7 +77,7 @@ static inline void *kmap(struct page *page) { return page_address(page); }
static inline void clear_user_highpage(struct page *page, unsigned long vaddr)
{
void *addr = kmap_atomic(page, KM_USER0);
clear_user_page(addr, vaddr);
clear_user_page(addr, vaddr, page);
kunmap_atomic(addr, KM_USER0);
}
......@@ -111,7 +111,7 @@ static inline void copy_user_highpage(struct page *to, struct page *from, unsign
vfrom = kmap_atomic(from, KM_USER0);
vto = kmap_atomic(to, KM_USER1);
copy_user_page(vto, vfrom, vaddr);
copy_user_page(vto, vfrom, vaddr, to);
kunmap_atomic(vfrom, KM_USER0);
kunmap_atomic(vto, KM_USER1);
}
......
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