Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752479AbdHBQkI (ORCPT ); Wed, 2 Aug 2017 12:40:08 -0400 Received: from mx1.redhat.com ([209.132.183.28]:60240 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751192AbdHBQkG (ORCPT ); Wed, 2 Aug 2017 12:40:06 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 6CB41859FA Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=aarcange@redhat.com Date: Wed, 2 Aug 2017 18:40:01 +0200 From: Andrea Arcangeli To: Michal Hocko Cc: Mike Rapoport , Andrew Morton , "Dr. David Alan Gilbert" , Pavel Emelyanov , linux-mm , lkml , stable@vger.kernel.org Subject: Re: [PATCH] userfaultfd_zeropage: return -ENOSPC in case mm has gone Message-ID: <20170802164001.GF21775@redhat.com> References: <1501136819-21857-1-git-send-email-rppt@linux.vnet.ibm.com> <20170731122204.GB4878@dhcp22.suse.cz> <20170731133247.GK29716@redhat.com> <20170731134507.GC4829@dhcp22.suse.cz> <20170802123440.GD17905@rapoport-lnx> <20170802155522.GB21775@redhat.com> <20170802162248.GA3476@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170802162248.GA3476@dhcp22.suse.cz> User-Agent: Mutt/1.8.3 (2017-05-23) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Wed, 02 Aug 2017 16:40:06 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 921 Lines: 18 On Wed, Aug 02, 2017 at 06:22:49PM +0200, Michal Hocko wrote: > ESRCH refers to "no such process". Strictly speaking userfaultfd code is > about a mm which is gone but that is a mere detail. In fact the owner of Well this whole issue about which retval, is about a mere detail in the first place, so I don't think you can discount all other mere details as irrelevant in the evaluation of a change to solve a mere detail. > But as I've said, this might be really risky to change. My impression > was that userfaultfd is not widely used yet and those can be fixed > easily but if that is not the case then we have to live with the current > ENOSPC. The only change would be for userfaultfd non cooperative mode, and CRIU is the main user of that. So I think it is up to Mike to decide, I'm fine either ways. I certainly agree ESRCH could be a slightly better fit, I only wanted to clarify it's not a 100% match either.