[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZywylcwmJFiVvkhb@google.com>
Date: Thu, 7 Nov 2024 03:23:01 +0000
From: Carlos Llamas <cmllamas@...gle.com>
To: Hillf Danton <hdanton@...a.com>
Cc: linux-kernel@...r.kernel.org,
Lorenzo Stoakes <lorenzo.stoakes@...cle.com>,
Suren Baghdasaryan <surenb@...gle.com>
Subject: Re: [PATCH 8/8] binder: use per-vma lock in page installation
On Thu, Nov 07, 2024 at 06:55:34AM +0800, Hillf Danton wrote:
> On Tue, 5 Nov 2024 20:02:50 +0000 Carlos Llamas <cmllamas@...gle.com>
> > Use per-vma locking for concurrent page installations, this minimizes
> > contention with unrelated vmas improving performance. The mmap_lock is
> > still acquired when needed though, e.g. before folio_walk_start().
> >
> Is the locking order correct in this patch?
>
> lock vma
> lock vma->vm_mm
Sorry, I've also fixed this issue in v2.
I was trying to avoid having to vma_lookup() again after switching
locks. However, this seems unavoidable so I've fixed the locking order
and I've also switched to get_user_pages_remote(). This seems like a
better option now.
--
Carlos Llamas
Powered by blists - more mailing lists