• Hugh Dickins's avatar
    [PATCH] freepgt: remove MM_VM_SIZE(mm) · ee39b37b
    Hugh Dickins authored
    There's only one usage of MM_VM_SIZE(mm) left, and it's a troublesome macro
    because mm doesn't contain the (32-bit emulation?) info needed.  But it too is
    only needed because we ignore the end from the vma list.
    
    We could make flush_pgtables return that end, or unmap_vmas.  Choose the
    latter, since it's a natural fit with unmap_mapping_range_vma needing to know
    its restart addr.  This does make more than minimal change, but if unmap_vmas
    had returned the end before, this is how we'd have done it, rather than
    storing the break_addr in zap_details.
    
    unmap_vmas used to return count of vmas scanned, but that's just debug which
    hasn't been useful in a while; and if we want the map_count 0 on exit check
    back, it can easily come from the final remove_vm_struct loop.
    Signed-off-by: default avatarHugh Dickins <hugh@veritas.com>
    Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
    ee39b37b
mmap.c 52.4 KB