Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp1049565pxv; Thu, 1 Jul 2021 16:01:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyLcygwNnh9M93uFoXA7/AXMcmzluOrRSmfaQNIp+/eAqe+scem7SXN35AWkUjzt/qbWY1o X-Received: by 2002:a17:907:7848:: with SMTP id lb8mr2339987ejc.494.1625180486832; Thu, 01 Jul 2021 16:01:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1625180486; cv=none; d=google.com; s=arc-20160816; b=vFtvtyAiPeYAvQeInYVyPkPl3HzWAADO/MXOMp0sFpko1E9EDVQynDNLaC7G6SuCbO FG23KR9IDF1zgr0+6VgOk2RptqKvR7ivL7YBk9Vs/IBCOMd0knQ83EphpJHRdWFo+FoQ bXH0a/pWGRs5gG2/aiQe4W5NPmHpFkdcA2lwXUZdhUVNlwI6rpIwo8x2WfgVrE91JyRY ZjKf7PBAwVVKxwlnwADJUo6x1HifC10cUZD5YheFVORfLH/MVmifYbGdEAJXj8DeLTLT YAf5E55wxANbN/ZU2erEszNPREvKxYvaVIrKHQiMHp49JSstljjndQ3wJTCD94kAQtoc utUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=eKQAwFjuaAaCUshwMfZMCC25WSRc/6MI7bYOaT2lCu0=; b=E5ODeKJbGJzMLBsQsO8/PTA5YvZtddSnU2gpPNsBBJwH2n5umoJciBd6c+K4tXoa2A btFGmP0B41EfDZTFARpdM7ku1jxTvCxP1nP6msokOjD6zkC9sPrZOXM4klE3rO4Xw1QY yRPrRtzOJuztfTxrOMOTqNSefNacWReZ00/JABCg9s1Y3FM5HfQhTC14iJx34jcJhegN aF/KSPdHUzUhCouhP51CWnxZDiwgu9/CeaBu5LxKtwiKOIlWvN8Jf+8el87rxMIallDz Gyr3uHKAlZ5VoJbUHipaz8GbpsdHKw/cMT5yVyEpY4C0iz0ARTkJDK4x0jWsarK+1HSs vJlA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=FoF9JYuQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id de15si1465820ejc.64.2021.07.01.16.01.02; Thu, 01 Jul 2021 16:01:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=FoF9JYuQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234089AbhGAXCe (ORCPT + 99 others); Thu, 1 Jul 2021 19:02:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34128 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234011AbhGAXCc (ORCPT ); Thu, 1 Jul 2021 19:02:32 -0400 Received: from mail-yb1-xb2c.google.com (mail-yb1-xb2c.google.com [IPv6:2607:f8b0:4864:20::b2c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 21E23C061762 for ; Thu, 1 Jul 2021 16:00:01 -0700 (PDT) Received: by mail-yb1-xb2c.google.com with SMTP id m9so13473509ybo.5 for ; Thu, 01 Jul 2021 16:00:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=eKQAwFjuaAaCUshwMfZMCC25WSRc/6MI7bYOaT2lCu0=; b=FoF9JYuQr2PlAVV/PhJWgD36muB9/aW/s+nV24F+xMy0h2zSpj362f8TWPJDLDGa18 QHu25LoAVyZ3n/D4n+D4/Yw3QqVLPAkMkedrYl3t6mUMyP6FffkPvJr/mgzJ6CKPeocY JUfsSwAkeJoevYgGMRK4v1MYvth6O2/Rlwkh/ziIDs7+zoMwbI6ROOaHte8KUCwQQd++ HLbbCDyi2U/PtWgvf/r6u8Ta7WSkJVDfet8kOKMK6qsJ6K+zcoq6p93aP1XjH0MNOOHX Vj4luGFFW0KdDZB586uQS/Wf7MXqo+USQJHhoOL4+OQZgCerlNgrrN3YVIgCcojWU34p YTQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=eKQAwFjuaAaCUshwMfZMCC25WSRc/6MI7bYOaT2lCu0=; b=c1MKFbbjqm36nnbYRghT/a9YmY7hIAc8nq/xyu8PXEgpRECd3PaHOIO8t5HP0jJBi8 KXcsvbCN0UaELODxniulN65jUdU1drUZlAo19aK97HTv7Z23My6Oxys7CxXJd0v5Tzc6 HsMbFGqLGnqF+MdR38QF4ippjJHTq3fJ5+oqnBCYcJZ1DdAAGCyqYv3PFVgP0DX8DwkI J+RqVTwOKt04X7zTFnGmp7IhjNhovD6po7cJvbRd2jkpu9b82puwj0vAGpxHDIj6fIQl USpwDOv6MvMUJ7TQ3BHDovCjZigS6pS252Av1xnQW+OIUwKLpvWW/eRQYAn0j4cEFrRG tvyg== X-Gm-Message-State: AOAM531Lh5gEqrYLD+uf43nEDwvB0Xv77TZlTLBYvfkLXYKu8+y6hjO5 rHdhxyyaeqKwUGUFjUf+boOzPH/9xjoWxIMrUG2etQ== X-Received: by 2002:a25:83ca:: with SMTP id v10mr2997364ybm.84.1625180400150; Thu, 01 Jul 2021 16:00:00 -0700 (PDT) MIME-Version: 1.0 References: <20210623192822.3072029-1-surenb@google.com> In-Reply-To: From: Suren Baghdasaryan Date: Thu, 1 Jul 2021 15:59:48 -0700 Message-ID: Subject: Re: [PATCH 1/1] mm: introduce process_reap system call To: Andy Lutomirski Cc: Johannes Weiner , Andrew Morton , Michal Hocko , Michal Hocko , David Rientjes , Matthew Wilcox , Roman Gushchin , Rik van Riel , Minchan Kim , Christian Brauner , Christoph Hellwig , Oleg Nesterov , David Hildenbrand , Jann Horn , Shakeel Butt , Tim Murray , Linux API , Linux-MM , LKML , Android Kernel Team Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 30, 2021 at 5:44 PM Andy Lutomirski wrote: > > On Wed, Jun 30, 2021 at 2:45 PM Johannes Weiner wrote: > > > > On Wed, Jun 30, 2021 at 11:51:36AM -0700, Suren Baghdasaryan wrote: > > > On Wed, Jun 30, 2021 at 11:26 AM Andy Lutomirski wrote: > > > > Also, please consider removing all mention of the word "reap" from the > > > > user API. For better or for worse, "reap" in UNIX refers to what > > > > happens when a dead task gets wait()ed. I sincerely wish I could go > > > > back in time and gently encourage whomever invented that particular > > > > abomination to change their mind, but my time machine doesn't work. > > > > > > I see. Thanks for the note. How about process_mem_release() and > > > replacing reap with release everywhere? > > > > I don't quite understand the objection. This syscall works on tasks > > that are at the end of their life, right? Isn't something like > > process_mreap() establishing exactly the mental link we want here? > > Release is less descriptive for what this thing is to be used for. > > For better or for worse, "reap" means to make a zombie pid go away. > From the description, this new operation takes a dying process (not > necessarily a zombie yet) and aggressively frees its memory. This is > a different optioneration. > > How about "free_dying_process_memory"? process_mreap sounds definitely better and in line with names like process_madvise. So maybe we can use it?