lkml.org 
[lkml]   [2022]   [Aug]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v2] mm/gup.c: Simplify and fix check_and_migrate_movable_pages() return codes
On Mon, Aug 1, 2022 at 8:32 PM Alistair Popple <apopple@nvidia.com> wrote:
>
> When pinning pages with FOLL_LONGTERM check_and_migrate_movable_pages()
> is called to migrate pages out of zones which should not contain any
> longterm pinned pages.
>
> When migration succeeds all pages will have been unpinned so pinning
> needs to be retried. This is indicated by returning zero. When all pages
> are in the correct zone the number of pinned pages is returned.
>
> However migration can also fail, in which case pages are unpinned and
> -ENOMEM is returned. However if the failure was due to not being unable
> to isolate a page zero is returned. This leads to indefinite looping in
> __gup_longterm_locked().

Hi Alistair,

During prohibiting pinning movable zone development, there was a
discussion where we figured that isolation errors should be transient
[1]. What isolation errors are you seeing that lead to infinite loop?
Why do they happen?

Pasha

[1] https://lore.kernel.org/linux-mm/20201218104655.GW32193@dhcp22.suse.cz

\
 
 \ /
  Last update: 2022-08-02 23:37    [W:0.116 / U:1.384 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site