From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mike Kravetz Subject: [PATCH v4 10/10] mm: madvise allow remove operation for hugetlbfs Date: Tue, 21 Jul 2015 11:09:44 -0700 Message-ID: <1437502184-14269-11-git-send-email-mike.kravetz@oracle.com> References: <1437502184-14269-1-git-send-email-mike.kravetz@oracle.com> Return-path: In-Reply-To: <1437502184-14269-1-git-send-email-mike.kravetz@oracle.com> Sender: owner-linux-mm@kvack.org To: linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-api@vger.kernel.org Cc: Dave Hansen , Naoya Horiguchi , David Rientjes , Hugh Dickins , Davidlohr Bueso , Aneesh Kumar , Hillf Danton , Christoph Hellwig , Andrew Morton , Michal Hocko , Mike Kravetz List-Id: linux-api@vger.kernel.org Now that we have hole punching support for hugetlbfs, we can also support the MADV_REMOVE interface to it. Signed-off-by: Dave Hansen Signed-off-by: Mike Kravetz --- mm/madvise.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/madvise.c b/mm/madvise.c index 67d5fe7..fa6479a 100644 --- a/mm/madvise.c +++ b/mm/madvise.c @@ -468,7 +468,7 @@ static long madvise_remove(struct vm_area_struct *vma, *prev = NULL; /* tell sys_madvise we drop mmap_sem */ - if (vma->vm_flags & (VM_LOCKED | VM_HUGETLB)) + if (vma->vm_flags & VM_LOCKED) return -EINVAL; f = vma->vm_file; -- 2.1.0 -- 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: email@kvack.org