• David Gibson's avatar
    [POWERPC] Fix bogus BUG_ON() in in hugetlb_get_unmapped_area() · 6aa3e1e9
    David Gibson authored
    The powerpc specific version of hugetlb_get_unmapped_area() makes some
    unwarranted assumptions about what checks have been made to its
    parameters by its callers.  This will lead to a BUG_ON() if a 32-bit
    process attempts to make a hugepage mapping which extends above
    TASK_SIZE (4GB).
    
    I'm not sure if these assumptions came about because they were valid
    with earlier versions of the get_unmapped_area() path, or if it was
    always broken.  Nonetheless this patch fixes the logic, and removes
    the crash.
    Signed-off-by: default avatarDavid Gibson <david@gibson.dropbear.id.au>
    Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
    6aa3e1e9
hugetlbpage.c 26.8 KB