Re: [PATCH 1/2] shmem: fix tmpfs to handle the huge= option properly
From: Aneesh Kumar K.V <hidden>
Date: 2016-09-22 10:58:29
Also in:
lkml, nvdimm
Toshi Kani [off-list ref] writes:
shmem_get_unmapped_area() checks SHMEM_SB(sb)->huge incorrectly, which leads to a reversed effect of "huge=" mount option. Fix the check in shmem_get_unmapped_area(). Note, the default value of SHMEM_SB(sb)->huge remains as SHMEM_HUGE_NEVER. User will need to specify "huge=" option to enable huge page mappings.
Any update on getting this merged ? Reviewed-by: Aneesh Kumar K.V <redacted>
quoted hunk ↗ jump to hunk
Reported-by: Hillf Danton <redacted> Signed-off-by: Toshi Kani <redacted> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Kirill A. Shutemov <redacted> Cc: Hugh Dickins <hughd@google.com> --- mm/shmem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)diff --git a/mm/shmem.c b/mm/shmem.c index fd8b2b5..aec5b49 100644 --- a/mm/shmem.c +++ b/mm/shmem.c@@ -1980,7 +1980,7 @@ unsigned long shmem_get_unmapped_area(struct file *file, return addr; sb = shm_mnt->mnt_sb; } - if (SHMEM_SB(sb)->huge != SHMEM_HUGE_NEVER) + if (SHMEM_SB(sb)->huge == SHMEM_HUGE_NEVER) return addr; } --To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
-- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>