diff --git a/mm/memory.c b/mm/memory.c index 4a7c8be9fe71..f9c3ad489823 100644 --- a/mm/memory.c +++ b/mm/memory.c @@ -5457,7 +5457,7 @@ struct vm_area_struct *lock_vma_under_rcu(struct mm_struct *mm, * concurrent mremap() with MREMAP_DONTUNMAP could dissociate the VMA * from its anon_vma. */ - if (unlikely(!vma->anon_vma && !vma_is_tcp(vma))) + if (vma_is_anonymous(vma) && !vma->anon_vma) goto inval_end_read; /*