From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756179AbbJAR4c (ORCPT ); Thu, 1 Oct 2015 13:56:32 -0400 Received: from mx1.redhat.com ([209.132.183.28]:53577 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752284AbbJAR4b (ORCPT ); Thu, 1 Oct 2015 13:56:31 -0400 Date: Thu, 1 Oct 2015 19:53:19 +0200 From: Oleg Nesterov To: Michal Hocko Cc: Andrew Morton , David Rientjes , Kyle Walker , Stanislav Kozina , Tetsuo Handa , linux-kernel@vger.kernel.org Subject: Re: [PATCH -mm v2 1/3] mm/oom_kill: remove the wrong fatal_signal_pending() check in oom_kill_process() Message-ID: <20151001175319.GA16313@redhat.com> References: <20150930182341.GA15047@redhat.com> <20150930182405.GA15238@redhat.com> <20151001124941.GC24077@dhcp22.suse.cz> <20151001150010.GB6781@redhat.com> <20151001152739.GJ24077@dhcp22.suse.cz> <20151001154115.GA10342@redhat.com> <20151001161916.GK24077@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20151001161916.GK24077@dhcp22.suse.cz> User-Agent: Mutt/1.5.18 (2008-05-17) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/01, Michal Hocko wrote: > > zap_process will add SIGKILL to all threads but the > current which will go on without being killed and if this is not a > thread group leader then we would miss it. Yes. And note that de_thread() does the same. Speaking of oom-killer this is mostly fine, the execing thread is going to release its old ->mm and it has already passed the copy_strings() stage which can use a lot more memory. But in theory (in practice currently this seems impossible without SIGKILL) exec can fail before exec_mmap(), so if we want to zap its ->mm we need to ensure it can't return to user space. > Acked-by: Michal Hocko Thanks! Oleg.