Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1410652 > unrolled thread
| Started by | Oleg Nesterov <oleg@redhat.com> |
|---|---|
| First post | 2016-05-31 23:50 +0200 |
| Last post | 2016-05-31 23:50 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH 5/6] mm, oom: kill all tasks sharing the mm Oleg Nesterov <oleg@redhat.com> - 2016-05-31 23:50 +0200
| From | Oleg Nesterov <oleg@redhat.com> |
|---|---|
| Date | 2016-05-31 23:50 +0200 |
| Subject | Re: [PATCH 5/6] mm, oom: kill all tasks sharing the mm |
| Message-ID | <rEZHY-7YV-11@gated-at.bofh.it> |
On 05/31, Michal Hocko wrote: > > On Mon 30-05-16 20:18:16, Oleg Nesterov wrote: > > > > perhaps the is_global_init() == T case needs a warning too? the previous changes > > take care about vfork() from /sbin/init, so the only reason we can see it true > > is that /sbin/init shares the memory with a memory hog... Nevermind, forget. > > I have another two patches waiting for this to settle and one of them > adds a warning to that path. Good, > > This is a bit off-topic, but perhaps we can also change the PF_KTHREAD check later. > > Of course we should not try to kill this kthread, but can_oom_reap can be true in > > this case. A kernel thread which does use_mm() should handle the errors correctly > > if (say) get_user() fails because we unmap the memory. > > I was worried that the kernel thread would see a zero page so this could > lead to a data corruption. We can't avoid this anyway. use_mm(victim->mm) can be called after we decide to kill the victim. So I think that we should always ignore kthreads, and in task_will_free_mem() too. But let me repeat, I agree we should discuss this later, I am not trying to suggest this change right now. Oleg.
Back to top | Article view | linux.kernel
csiph-web