Received: by 2002:a05:6358:701b:b0:131:369:b2a3 with SMTP id 27csp2601204rwo; Sun, 23 Jul 2023 20:08:01 -0700 (PDT) X-Google-Smtp-Source: APBJJlEKMa9Et2QY5eoVHBuIL00PhzeMmzmlyBNlq1eTUOZm61pB4FrraHXsH8BPszT74fRiBf3m X-Received: by 2002:a05:6a21:3389:b0:121:ca90:df01 with SMTP id yy9-20020a056a21338900b00121ca90df01mr9716940pzb.40.1690168081129; Sun, 23 Jul 2023 20:08:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690168081; cv=none; d=google.com; s=arc-20160816; b=hePZKfh3koI0A57wpJ5gWOcEcwCy3WlJ+KP1g3Jm2gDXVJveDPmaZQpvdr+V1jPymf 0zsa8F4/ZRfvSCwDI6bNZHWnH5UaGyqHEyUo7/khFDbsJ/hoGdC8+qh2hSwrDhV6KFg9 pxrOut7O66MW0+nOICOilgmqBUWb1SiUwmrlJT+xf5HnnVHorSYspDeXev+t38PRb8Ur HBbaNRkl4m+H82rd/XvyMDtvBaofAiE1FKUsPxohdPuPUkHZCWx7C97jOWiTJM7E6UC4 L+C5nmQvQfp8oVTPO9rA6XrGeMljGVIdVqHW3Nk6wMPRQ2hPA90gySNF2qcrZFLzCADb UtGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject; bh=OfunpU4gdxGlhY4eZeLjZhkzDGDulvQGUCbfZugjBKs=; fh=tNG66ssB7eZYZsJ5V2tC5uxr5AkV230Nbl6NHzDYbq4=; b=FqyYuJ5hF2rW65obsw3w7yBpBNoStPr7tmHMy1QybaESDA+JTz3JrOBCqMjpykbom6 9sPthui0fAg6mkXXnD0SZS075Xah5UClFHVdFTWVvIYZot/7aiEDKVSIg+/ZlDh0h2PN 5o/jq7A25PuMRFK4hPnUOwlJhtk5oDfxZ/VVHxBhb5YGC2n+4uPS6tTJW2lwRwX25Fag OBMCLi8atm92LGtA6oSj9rAT2JpHWSTZAe2ks4E3rU6SpUivoXoK7YSWjSusdX7HUCQ2 /pFEBYCcynrcOQORWI4vEd5+9sr3ZNsA30YhSsVt91w2qAHTejrTF1UgIqxp14oEoCXy ySSA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k11-20020a170902c40b00b001b892a54da5si8932817plk.37.2023.07.23.20.07.48; Sun, 23 Jul 2023 20:08:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230384AbjGXCbO (ORCPT + 99 others); Sun, 23 Jul 2023 22:31:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42790 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230331AbjGXCbM (ORCPT ); Sun, 23 Jul 2023 22:31:12 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 32533BF; Sun, 23 Jul 2023 19:30:55 -0700 (PDT) Received: from canpemm500002.china.huawei.com (unknown [172.30.72.55]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4R8NST2PnKzrRr6; Mon, 24 Jul 2023 09:51:53 +0800 (CST) Received: from [10.174.151.185] (10.174.151.185) by canpemm500002.china.huawei.com (7.192.104.244) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Mon, 24 Jul 2023 09:52:43 +0800 Subject: Re: [PATCH] mm/memcg: fix obsolete function name in mem_cgroup_protection() To: Matthew Wilcox CC: , , , References: <20230723032538.3190239-1-linmiaohe@huawei.com> From: Miaohe Lin Message-ID: Date: Mon, 24 Jul 2023 09:52:43 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.151.185] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To canpemm500002.china.huawei.com (7.192.104.244) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-5.3 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2023/7/24 4:37, Matthew Wilcox wrote: > On Sun, Jul 23, 2023 at 11:25:38AM +0800, Miaohe Lin wrote: >> @@ -582,9 +582,9 @@ static inline void mem_cgroup_protection(struct mem_cgroup *root, >> /* >> * There is no reclaim protection applied to a targeted reclaim. >> * We are special casing this specific case here because >> - * mem_cgroup_protected calculation is not robust enough to keep >> - * the protection invariant for calculated effective values for >> - * parallel reclaimers with different reclaim target. This is >> + * mem_cgroup_calculate_protection calculation is not robust enough >> + * to keep the protection invariant for calculated effective values >> + * for parallel reclaimers with different reclaim target. This is >> * especially a problem for tail memcgs (as they have pages on LRU) >> * which would want to have effective values 0 for targeted reclaim >> * but a different value for external reclaim. > > This reads a little awkwardly now. How about: > > * We are special casing this specific case here because > - * mem_cgroup_protected calculation is not robust enough to keep > + * mem_cgroup_calculate_protection is not robust enough to keep Sounds better. Will do it in v2. Thanks.