lkml.org 
[lkml]   [2004]   [Nov]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    SubjectRe: 2.6.10-rc1-mm3

    * Andi Kleen <ak@suse.de> wrote:

    > > The solution is to clip both 'first' and 'last' to PML4_SIZE boundary.
    > > Since when we calculate 'first' we add at least +PML4_SIZE to the value,
    > > it is safe to clip 'first'. It is obviously safe to clip 'last'.
    >
    > It's a bit tricky because on 3level architectures it clips on PGDs,
    > not PML4s, otherwise it would never free any pagetables. But the
    > if()s check that correctly.

    indeed ... But in the do_munmap() case we dont even clip to PGD
    boundary. So shouldnt we at least do the patch below?

    Ingo

    --- linux/mm/mmap.c.orig
    +++ linux/mm/mmap.c
    @@ -1545,7 +1545,7 @@ no_mmaps:
    }
    if (pml4_index(last) > start_pml4_index ||
    pgd_index(last) > start_pgd_index) {
    - clear_page_range(tlb, first & PML4_MASK, last & PML4_MASK);
    + clear_page_range(tlb, first & PGDIR_MASK, last & PGDIR_MASK);
    flush_tlb_pgtables(mm, first & PML4_MASK, last & PML4_MASK);
    }
    }
    -
    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/
    \
     
     \ /
      Last update: 2005-03-22 14:07    [W:0.094 / U:0.232 seconds]
    ©2003-2014 Jasper Spaans. Advertise on this site