From: Joonsoo Kim Date: Wed, 11 Sep 2013 21:21:55 +0000 (-0700) Subject: mm, hugetlb: remove useless check about mapping type X-Git-Tag: v3.12-rc1~52^2~213 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5944d0116c773319a48ea6812d1891aa6d0bbbbf;p=profile%2Fivi%2Fkernel-x86-ivi.git mm, hugetlb: remove useless check about mapping type is_vma_resv_set(vma, HPAGE_RESV_OWNER) implys that this mapping is for private. So we don't need to check whether this mapping is for shared or not. This patch is just for clean-up. Signed-off-by: Joonsoo Kim Cc: Aneesh Kumar Cc: Naoya Horiguchi Reviewed-by: Davidlohr Bueso Cc: David Gibson Cc: Wanpeng Li Cc: Hillf Danton Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/mm/hugetlb.c b/mm/hugetlb.c index dec5772..f6347ec 100644 --- a/mm/hugetlb.c +++ b/mm/hugetlb.c @@ -2564,8 +2564,7 @@ retry_avoidcopy: * at the time of fork() could consume its reserves on COW instead * of the full address range. */ - if (!(vma->vm_flags & VM_MAYSHARE) && - is_vma_resv_set(vma, HPAGE_RESV_OWNER) && + if (is_vma_resv_set(vma, HPAGE_RESV_OWNER) && old_page != pagecache_page) outside_reserve = 1;