Message ID | 20230302115835.105364-7-wangkefeng.wang@huawei.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp4186066wrd; Thu, 2 Mar 2023 03:41:10 -0800 (PST) X-Google-Smtp-Source: AK7set9gsDqRXclh2ePw0nC1uD7bhHdzuLMXBQGA7z4r1ebzrfRf6B2nSaYOqWHNOMCVnj54jB2M X-Received: by 2002:aa7:cd8b:0:b0:4ac:b309:3d76 with SMTP id x11-20020aa7cd8b000000b004acb3093d76mr9863437edv.31.1677757270710; Thu, 02 Mar 2023 03:41:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1677757270; cv=none; d=google.com; s=arc-20160816; b=dCrbarIO75y5Ek0ylwuchdcvMMLOHTB4zDHrgO9UAM0qEM9EDkfdgpPS3SNkrU8K1L xvSFLEv3OBJeKmpXExAdHLlhZWDDDtq7RDITamdBxIj95y7SYgN8TrGRgbqxk4z6IghQ 1EvP87QrxxNuBjoCutQDMTuis4H3aTYhM9Dwdfc0E2iLlXwcCCJaMtzyllHOKrHOsXhl /6uSnqYHwbr/eKPJq3u2RQUGDmGHdnDZVyj6MnzZ150R7mD2D1yiEj5H2O5SUHUNyYHl dHCzesh1seEA5ZsTc0wSfsKidUOIbGPReb5fm5KBO/xy5Q50moSz7rbRQ/zY812ZO8TW ctZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=RV96LlTMyS60efsCIJSLjMlPFR7so6yuJxIK9Rv9A8E=; b=cHz7jbrkrCD2SFGu318672qpzwnLqnvW2C6UKeIrOE4CEI5vnCSyC9zQQn25jv0Y0J aKrEKI+DnCc5K29zGg3GfPWMOA7ggcDgpr3Zi4DJc3tonHCYAFnS4CKYfy6uREI7EmdX TTm2f8jRN9dqjdXjVRMLgKjLIBOHp13UKKINGlbld1D8Mas0Y4DedU/9NTsQ52NnFZc5 1aYIn39yyr5gWAdFy69Kv2mO37B8e4JAP0yjTHNzQRheWa0eo8INsl6n9CtJhM+jdJnX 0Wg/KkFFVg9T1J2LKE5yTMyAr+5iOCG6Sb2iAOZwN+n419NpdTrJDxY9BXSxoirpKMFg zhcA== 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h13-20020a1709060f4d00b008dd491949d3si498615ejj.252.2023.03.02.03.40.47; Thu, 02 Mar 2023 03:41:10 -0800 (PST) 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 S229668AbjCBLj0 (ORCPT <rfc822;davidbtadokoro@gmail.com> + 99 others); Thu, 2 Mar 2023 06:39:26 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33546 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229760AbjCBLjT (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 2 Mar 2023 06:39:19 -0500 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B38BF2BF02 for <linux-kernel@vger.kernel.org>; Thu, 2 Mar 2023 03:38:54 -0800 (PST) Received: from dggpemm500001.china.huawei.com (unknown [172.30.72.55]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4PS8CX2XSLzSkTR; Thu, 2 Mar 2023 19:34:48 +0800 (CST) Received: from localhost.localdomain.localdomain (10.175.113.25) by dggpemm500001.china.huawei.com (7.185.36.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.21; Thu, 2 Mar 2023 19:37:43 +0800 From: Kefeng Wang <wangkefeng.wang@huawei.com> To: <akpm@linux-foundation.org> CC: <linux-mm@kvack.org>, <linux-kernel@vger.kernel.org>, "Matthew Wilcox (Oracle)" <willy@infradead.org>, Kefeng Wang <wangkefeng.wang@huawei.com> Subject: [PATCH v2 6/7] mm: memory: use folio_throttle_swaprate() in do_cow_fault() Date: Thu, 2 Mar 2023 19:58:34 +0800 Message-ID: <20230302115835.105364-7-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20230302115835.105364-1-wangkefeng.wang@huawei.com> References: <20230302115835.105364-1-wangkefeng.wang@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.113.25] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggpemm500001.china.huawei.com (7.185.36.107) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1759256007907164880?= X-GMAIL-MSGID: =?utf-8?q?1759256007907164880?= |
Series |
mm: remove cgroup_throttle_swaprate() completely
|
|
Commit Message
Kefeng Wang
March 2, 2023, 11:58 a.m. UTC
Directly use folio_throttle_swaprate() instead of
cgroup_throttle_swaprate().
Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
---
mm/memory.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/memory.c b/mm/memory.c index 841737d5690d..b24c618d7348 100644 --- a/mm/memory.c +++ b/mm/memory.c @@ -4527,7 +4527,7 @@ static vm_fault_t do_cow_fault(struct vm_fault *vmf) put_page(vmf->cow_page); return VM_FAULT_OOM; } - cgroup_throttle_swaprate(vmf->cow_page, GFP_KERNEL); + folio_throttle_swaprate(page_folio(vmf->cow_page), GFP_KERNEL); ret = __do_fault(vmf); if (unlikely(ret & (VM_FAULT_ERROR | VM_FAULT_NOPAGE | VM_FAULT_RETRY)))