Re: [PATCH] mm,oom: use per signal_struct flag rather than clear TIF_MEMDIE

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu 30-06-16 19:51:53, Tetsuo Handa wrote:
> Michal Hocko wrote:
[...]
> > I have changed that to cmpxchg because lowmemory killer is called
> > outside of oom_lock.
> 
> Android's lowmemory killer is no longer using mark_oom_victim().

You are right! The mmotm tree doesn't have the patch because it was
routed via Greg. I will probably keep the cmpxchg, though, because it
it less error prone and doesn't add much...
 
[...]

> By the way, are you going to fix use_mm() race? Currently, we don't wake up
> OOM reaper if some kernel thread is holding a reference to that mm via
> use_mm(). But currently we can hit
> 
>   (1) OOM killer fails to find use_mm() users using for_each_process() in
>       oom_kill_process() and wakes up OOM reaper.
> 
>   (2) Some kernel thread calls use_mm().
> 
>   (3) OOM reaper ignores use_mm() users and reaps that mm.
> 
> race. I think we need to make use_mm() fail after mark_oom_victim() is called.

Considering it would matter only for the vhost which I would like to be
oom reaper safe I would prefer to do the later and not treat kthreads
special.

Thanks!
-- 
Michal Hocko
SUSE Labs

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]