Fixing 2 small issues pointed by Tony Luck.
* removing redundant BUG_ON in __ia64_sync_icache_dcache().
* check pte_present() first.
Signed-off-by: KAMEZAWA Hiroyuki <[email protected]>
---
arch/ia64/mm/init.c | 2 --
include/asm-ia64/pgtable.h | 4 ++--
2 files changed, 2 insertions(+), 4 deletions(-)
Index: linux-2.6.23-rc2-mm2/include/asm-ia64/pgtable.h
===================================================================
--- linux-2.6.23-rc2-mm2.orig/include/asm-ia64/pgtable.h
+++ linux-2.6.23-rc2-mm2/include/asm-ia64/pgtable.h
@@ -327,8 +327,8 @@ ia64_phys_addr_valid (unsigned long addr
extern void __ia64_sync_icache_dcache(pte_t pteval);
static inline void set_pte(pte_t *ptep, pte_t pteval)
{
- if (pte_exec(pteval) && // flush only new executable page.
- pte_present(pteval) && // swap out ?
+ if (pte_present(pteval) &&// swap out ?
+ pte_exec(pteval) && // flush only new executable page.
pte_user(pteval) && // ignore kernel page
(!pte_present(*ptep) ||// do_no_page or swap in, migration,
pte_pfn(*ptep) != pte_pfn(pteval))) // do_wp_page(), page copy
Index: linux-2.6.23-rc2-mm2/arch/ia64/mm/init.c
===================================================================
--- linux-2.6.23-rc2-mm2.orig/arch/ia64/mm/init.c
+++ linux-2.6.23-rc2-mm2/arch/ia64/mm/init.c
@@ -60,8 +60,6 @@ __ia64_sync_icache_dcache (pte_t pte)
struct page *page;
unsigned long order;
- BUG_ON(!pte_exec(pte));
-
page = pte_page(pte);
addr = (unsigned long) page_address(page);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]