source: trunk/target/linux/coldfire/patches/043-workaround-for-zero-page-used-on-ColdFire-platform.patch @ 31546

Last change on this file since 31546 was 31546, checked in by kaloz, 5 years ago

[coldfire]: switch to 2.6.38

File size: 1.0 KB
  • mm/memory.c

    From fa27f3e27863e3f4376864b144dc7506de124cf6 Mon Sep 17 00:00:00 2001
    From: Jason Jin <Jason.jin@freescale.com>
    Date: Thu, 4 Aug 2011 09:59:54 +0800
    Subject: [PATCH 43/52] workaround for zero page used on ColdFire platform.
    
    There is some issue for Coldfire platform to use the
    zero page for read when there is memory fault. This is
    a workaround for this, try to make kernel to use normal
    memory instead.
    
    Signed-off-by: Jason Jin <Jason.jin@freescale.com>
    ---
     mm/memory.c |    2 ++
     1 files changed, 2 insertions(+), 0 deletions(-)
    
    a b static int do_anonymous_page(struct mm_s 
    29372937        if (check_stack_guard_page(vma, address) < 0) 
    29382938                return VM_FAULT_SIGBUS; 
    29392939 
     2940#ifndef CONFIG_COLDFIRE 
    29402941        /* Use the zero-page for reads */ 
    29412942        if (!(flags & FAULT_FLAG_WRITE)) { 
    29422943                entry = pte_mkspecial(pfn_pte(my_zero_pfn(address), 
    static int do_anonymous_page(struct mm_s 
    29462947                        goto unlock; 
    29472948                goto setpte; 
    29482949        } 
     2950#endif 
    29492951 
    29502952        /* Allocate our own private page. */ 
    29512953        if (unlikely(anon_vma_prepare(vma))) 
Note: See TracBrowser for help on using the repository browser.