Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp6438033pxb; Wed, 17 Feb 2021 04:45:14 -0800 (PST) X-Google-Smtp-Source: ABdhPJyw/0LntxnO2Lvf8I1UyL6SMkain8NQYB9vXBJdfXek0QUca1g1dJG0fp26Pr16XR2eMOoa X-Received: by 2002:a17:906:5292:: with SMTP id c18mr22410747ejm.450.1613565913984; Wed, 17 Feb 2021 04:45:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613565913; cv=none; d=google.com; s=arc-20160816; b=tJ2XNDqHWsKDEpL04y/XgWYkNsybExASZcWn2bL2oES1QD+WHCZ38PIf69JICzO+8v +M/gWjSfRuOKtEqsl5m9Idh6wxoXLXhSvPKgFX/eKjM9qdzMtpXX7XmeO0uuuOucjAai Dx/XmIup/hMmWg83g+oRLeHJ24ebqoVMuhCieKWnk4rGyi0bEUo50CodKL5deAYP/sHW fwOoggOEU0W1J6rLk3XZaqy6/A1OBcoE2nZZDixuwi5UZ0otny4dgrWn4XplzVZfEc16 6ucUoEKKqdcCNu9Fi0v2siZS1llFz41+7TD5tC5bX8YLNp3UHvkPb8wR2fxvpGgJpywe pkjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=eFaD6cMmUflfe3zZL8l/1NnW+074aRMBx7mpt03K63o=; b=NN/lTHQ7qQA1m+0MsvL40OT30hGzLc34vlIqn0b6YZc+JdX7pSpWLP8737oSS2Aw0+ s62JL6uBLZvgRjFqH2sH33CqSx7tnZV9Xc3Jmo2XC0wmMhVWtX/zvRsoLpjGNMQZKJtn pcEPlxgQxi++dErAc7k0gI2S+lb3DBaNZoHGZL6SjC1wzbXDVEzeD0Qal+SsHHsp72KO FWKRKwc3bAFh7ojiCWBdMo8Ro/Qj2TfB+sN4o+uPRzclAgQrSg4CqdlUVaReCVV9ovQ8 mg3NVnnRtliYBPcL/H7lRJ6s/LAwPQvnSsa93pRAqVuJiXQ3YKINS3RVY65wnKhi8bt9 H/lw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=T3NWYvma; 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=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a21si1261274edn.168.2021.02.17.04.44.50; Wed, 17 Feb 2021 04:45:13 -0800 (PST) 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=@suse.com header.s=susede1 header.b=T3NWYvma; 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=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232660AbhBQMld (ORCPT + 99 others); Wed, 17 Feb 2021 07:41:33 -0500 Received: from mx2.suse.de ([195.135.220.15]:39216 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232090AbhBQMl3 (ORCPT ); Wed, 17 Feb 2021 07:41:29 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1613565642; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=eFaD6cMmUflfe3zZL8l/1NnW+074aRMBx7mpt03K63o=; b=T3NWYvman7n71RhYgVvyPrPRDNUhUpUESPEg1c+s/N1CuBVc0QBEPJW6rIvcSjTwOhyXpy 2VYCtSP/dZG7z5I2jh4WrO+TJ1rMZMu1jvL/jpMXu5XDO7F/zKwaNNaRDv3ee++RcExMS/ /4Q7qPxK6uEgQ7X9LGLMF8fTy9ce8F8= Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id B2025AF26; Wed, 17 Feb 2021 12:40:42 +0000 (UTC) Date: Wed, 17 Feb 2021 13:40:36 +0100 From: Michal Hocko To: Eiichi Tsukata Cc: Mike Kravetz , "corbet@lwn.net" , "mcgrof@kernel.org" , "keescook@chromium.org" , "yzaikin@google.com" , "akpm@linux-foundation.org" , "linux-doc@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-mm@kvack.org" , "linux-fsdevel@vger.kernel.org" , Felipe Franciosi Subject: Re: [RFC PATCH] mm, oom: introduce vm.sacrifice_hugepage_on_oom Message-ID: References: <20210216030713.79101-1-eiichi.tsukata@nutanix.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 17-02-21 13:31:07, Michal Hocko wrote: [...] > Thanks for your usecase description. It helped me to understand what you > are doing and how this can be really useful for your particular setup. > This is really a very specific situation from my POV. I am not yet sure > this is generic enough to warrant for a yet another tunable. One thing > you can do [1] is to > hook into oom notifiers interface (register_oom_notifier) and release > pages from the callback. Forgot to mention that this would be done from a kernel module. > Why is that batter than a global tunable? > For one thing you can make the implementation tailored to your specific > usecase. As the review feedback has shown this would be more tricky to > be done in a general case. Unlike a generic solution it would allow you > to coordinate with your userspace if you need. Would something like that > work for you? > > --- > [1] and I have to say I hate myself for suggesting that because I was > really hoping this interface would go away. But the reality disagrees so > I gave up on that goal... > -- > Michal Hocko > SUSE Labs -- Michal Hocko SUSE Labs