mm: huge_memory: don't force huge page alignment on 32 bit
commit
efa7df3e3bb5 ("mm: align larger anonymous mappings on THP
boundaries") caused two issues [1] [2] reported on 32 bit system or compat
userspace.
It doesn't make too much sense to force huge page alignment on 32 bit
system due to the constrained virtual address space.
[1] https://lore.kernel.org/linux-mm/
d0a136a0-4a31-46bc-adf4-
2db109a61672@kernel.org/
[2] https://lore.kernel.org/linux-mm/CAJuCfpHXLdQy1a2B6xN2d7quTYwg2OoZseYPZTRpU0eHHKD-sQ@mail.gmail.com/
Link: https://lkml.kernel.org/r/[email protected]
Fixes: efa7df3e3bb5 ("mm: align larger anonymous mappings on THP boundaries")
Signed-off-by: Yang Shi <[email protected]>
Reported-by: Jiri Slaby <[email protected]>
Reported-by: Suren Baghdasaryan <[email protected]>
Tested-by: Jiri Slaby <[email protected]>
Tested-by: Suren Baghdasaryan <[email protected]>
Reviewed-by: Matthew Wilcox (Oracle) <[email protected]>
Cc: Rik van Riel <[email protected]>
Cc: Christopher Lameter <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>