[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aLFSt1uId1B-AUk_@tiehlicka>
Date: Fri, 29 Aug 2025 09:11:51 +0200
From: Michal Hocko <mhocko@...e.com>
To: "Liam R. Howlett" <Liam.Howlett@...cle.com>
Cc: Shakeel Butt <shakeel.butt@...ux.dev>,
Lorenzo Stoakes <lorenzo.stoakes@...cle.com>,
zhongjinji <zhongjinji@...or.com>, rientjes@...gle.com,
akpm@...ux-foundation.org, linux-mm@...ck.org,
linux-kernel@...r.kernel.org, tglx@...utronix.de,
liulu.liu@...or.com, feng.han@...or.com
Subject: Re: [PATCH v5 2/2] mm/oom_kill: Have the OOM reaper and exit_mmap()
traverse the maple tree in opposite order
On Wed 27-08-25 00:12:34, Liam R. Howlett wrote:
[...]
> > > I'd think using MMF_ to reduce the race
> > > would achieve the same goal with less risk - which is why I bring it up.
> > >
> >
> > With MMF_ flag, are you suggesting oom reaper to skip the unmapping of
> > the oom-killed process?
>
> Yes, specifically move the MMF_OOM_SKIP flag to earlier in the exit
> path to reduce the possibility of the race/contention.
MMF_OOM_SKIP is a "hide from oom killer" flag and that means that as
soon as you set it up the next oom killer invocation would kill another
task while the current one hasn't freed up the memory yet and therefore
you have a potentially pointless kill.
--
Michal Hocko
SUSE Labs
Powered by blists - more mailing lists