Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1239159

Re: [PATCH] mm/mmap.c: Remove redundant vma looping

From Andrea Arcangeli <aarcange@redhat.com>
Newsgroups linux.kernel
Subject Re: [PATCH] mm/mmap.c: Remove redundant vma looping
Date 2015-10-04 19:30 +0200
Message-ID <qfVgK-6VO-9@gated-at.bofh.it> (permalink)
References <qfAOZ-2Tr-3@gated-at.bofh.it> <qfBi2-3GQ-13@gated-at.bofh.it> <qfJyV-6Y7-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hello Chen,

On Sun, Oct 04, 2015 at 12:55:29PM +0800, Chen Gang wrote:
> Theoretically, the lock and unlock need to be symmetric, if we have to
> lock f_mapping all firstly, then lock all anon_vma, probably, we also
> need to unlock anon_vma all, then unlock all f_mapping.

They don't need to be symmetric because the unlocking order doesn't
matter. To avoid lock inversion deadlocks it is enough to enforce the
lock order.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] mm/mmap.c: Remove redundant vma looping Chen Gang <xili_gchen_5257@hotmail.com> - 2015-10-03 21:40 +0200
  Re: [PATCH] mm/mmap.c: Remove redundant vma looping Richard Weinberger <richard.weinberger@gmail.com> - 2015-10-03 22:10 +0200
    Re: [PATCH] mm/mmap.c: Remove redundant vma looping Chen Gang <xili_gchen_5257@hotmail.com> - 2015-10-04 07:00 +0200
      Re: [PATCH] mm/mmap.c: Remove redundant vma looping Andrea Arcangeli <aarcange@redhat.com> - 2015-10-04 19:30 +0200
        RE: [PATCH] mm/mmap.c: Remove redundant vma looping Chen Gang <xili_gchen_5257@hotmail.com> - 2015-10-05 14:30 +0200

csiph-web