From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.4 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id ED97AC433E0 for ; Fri, 29 May 2020 01:56:58 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id CCA0020814 for ; Fri, 29 May 2020 01:56:58 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=chrisdown.name header.i=@chrisdown.name header.b="lkBaXTV2" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2404606AbgE2B4x (ORCPT ); Thu, 28 May 2020 21:56:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36466 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2391555AbgE2B4w (ORCPT ); Thu, 28 May 2020 21:56:52 -0400 Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 771C3C08C5CA for ; Thu, 28 May 2020 18:56:47 -0700 (PDT) Received: by mail-wm1-x341.google.com with SMTP id v19so1414910wmj.0 for ; Thu, 28 May 2020 18:56:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chrisdown.name; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=GN9DgkPdwejhyEVH1kmP5gS0KBOAcxSeuTuQOx2XI9o=; b=lkBaXTV2ZUB6ZO5yX3Ng0K/CASCbc9oNlaDIc8KLZ8e4v2cb+z5+AxOSC0HUqdLw42 pPHQXKJiXMf7fSmverIul8xSND7c0ygaABLVaG0hqIXTL8OJ4e0fS8l8+kZ0LHaXgNsT f3Y+1qQWXh34SIawtNNfPuqOwbkRTPMzu6he4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=GN9DgkPdwejhyEVH1kmP5gS0KBOAcxSeuTuQOx2XI9o=; b=SGbIsmZm/9J/lVOxHDLrqndEvxB4wM3kSHG7yArSbGL1WUHyLC9HdXKsFYFGl/Vcuk KbZWgqbZ6UzeZ7woCch8Cwy7e2Y+j4FCo6c8DaEvLMkzlxj1kAO3b6YUqgZ+lX6XKY3Q eu76yMuhLhzwf+b6mV+7DcUyDFIfglNdiYEfNsckmHA6UZkq/5g47YaW/dBQ/ZKEt3HM HvRAJRSOZnqOYXRU28HGB+U2r8NVKKY9AyIiwpTzmxaTQj7NnUFwQerJQOZKkFSenOo5 NS1/3prpVLzn7klGGLKcsm3unXoBzNJju8QuQoutddDZYa9lfjA8nI43TBnlZZiGoEWs hirQ== X-Gm-Message-State: AOAM530blEaNhFi4FVR2aFKDyQn856WqdEP6ESLV6OMjX7Pr5tTCGQV2 Yngmu5T2zgDUuNanOYWTZBgplg== X-Google-Smtp-Source: ABdhPJx1kaceNrBzDvGLjsUvi/4uBliHtVGdHPjh2oD497Ebo468RL7eFjpFK3j2MrZfogR+PRA4Bg== X-Received: by 2002:a7b:c096:: with SMTP id r22mr6033969wmh.92.1590717405871; Thu, 28 May 2020 18:56:45 -0700 (PDT) Received: from localhost ([2a01:4b00:8432:8a00:56e1:adff:fe3f:49ed]) by smtp.gmail.com with ESMTPSA id q11sm1858042wrv.67.2020.05.28.18.56.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 May 2020 18:56:45 -0700 (PDT) Date: Fri, 29 May 2020 02:56:44 +0100 From: Chris Down To: Yafang Shao Cc: Naresh Kamboju , Michal Hocko , Anders Roxell , "Linux F2FS DEV, Mailing List" , linux-ext4 , linux-block , Andrew Morton , open list , Linux-Next Mailing List , linux-mm , Arnd Bergmann , Andreas Dilger , Jaegeuk Kim , Theodore Ts'o , Chao Yu , Hugh Dickins , Andrea Arcangeli , Matthew Wilcox , Chao Yu , lkft-triage@lists.linaro.org, Johannes Weiner , Roman Gushchin , Cgroups Subject: Re: mm: mkfs.ext4 invoked oom-killer on i386 - pagecache_get_page Message-ID: <20200529015644.GA84588@chrisdown.name> References: <20200520190906.GA558281@chrisdown.name> <20200521095515.GK6462@dhcp22.suse.cz> <20200521163450.GV6462@dhcp22.suse.cz> <20200528150310.GG27484@dhcp22.suse.cz> <20200528164121.GA839178@chrisdown.name> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.14.2 (2020-05-25) Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Yafang Shao writes: >Look at this patch[1] carefully you will find that it introduces the >same issue that I tried to fix in another patch [2]. Even more sad is >these two patches are in the same patchset. Although this issue isn't >related with the issue found by Naresh, we have to ask ourselves why >we always make the same mistake ? >One possible answer is that we always forget the lifecyle of >memory.emin before we read it. memory.emin doesn't have the same >lifecycle with the memcg, while it really has the same lifecyle with >the reclaimer. IOW, once a reclaimer begins the protetion value should >be set to 0, and after we traversal the memcg tree we calculate a >protection value for this reclaimer, finnaly it disapears after the >reclaimer stops. That is why I highly suggest to add an new protection >member in scan_control before. I agree with you that the e{min,low} lifecycle is confusing for everyone -- the only thing I've not seen confirmation of is any confirmed correlation with the i386 oom killer issue. If you've validated that, I'd like to see the data :-)