Message ID | 20231104035522.2418660-3-wangkefeng.wang@huawei.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:8f47:0:b0:403:3b70:6f57 with SMTP id j7csp1450901vqu; Fri, 3 Nov 2023 20:56:20 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGPQzAUsf3h3Ycg/0kqLdoNy0GiwwxBSKolxB+ldcKTr4I0rGpZUzpSCOqT0QLufx3DQ+NK X-Received: by 2002:a05:6870:4945:b0:1d6:2476:be2e with SMTP id fl5-20020a056870494500b001d62476be2emr29844513oab.35.1699070180580; Fri, 03 Nov 2023 20:56:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1699070180; cv=none; d=google.com; s=arc-20160816; b=dMFU3QgMYGdugWQImxc6C04qOh4orJkUVksZVVYLDobiq3s84Ap9WWAkzyNq4WUHOp PWSv5JYYvKOufZkA1GnF0QWnjXhfFjJPtCdzDv5jtW79kiOANsXq+SoKwkZxbQnPbbHY EhystzR3Jk392Eyu3qaEeSo0ONF4JkObRHJkyN4Hf0zkiwR51ZNvNIc5Fgnx391Zz5po 6LRIuoIyecXLfIdV8whqUrvsI/GFf/YL7loVnDe4PPO6NN6G45jP4HTD2PYukTtqrq45 zxDrilu1bVHNhMnhETVPSe237fOYdeQeVQhW5VUo03Bt6mD9N/DcMVa0Zgc6pln5jzPZ 1PIw== 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=UmujaejCASjfQtJbBR1EzDPhPNeOSdCiPLhgFsCit5A=; fh=kUj/5waaepfljbNx30rj2BALdV0u/mUCTaFWThlgquQ=; b=D8Uz+W2RBUOI2n/W87Zi167PKECVjStkec30o3Jv0+T7qvkZKrgw1FVyFOQIAOiaqB kradYHVajWehGT9zxTNJPZSbRf1tn/04ar28PBENRG0byeQ6FowsqaLWr4kbrj/vrbZb kPaU1CdOoUJwWq6Oq3XliLrcQseipsVyihu91VMnqmAy/xHWuOShDs7EkhVPwBRV/zDw UyrxKzbhQT5/rN+b4h6Pku9eB1XAdurFl+DEjwR9C8ZPyp2i9ynWkO5sO9Zs3TCc/zYF v8EJfRawzX0HetCQE0YobS3vOBpG8UluuPyAz1MyWOPbh8PRVzGn8JclRkDD/BZ4xxGi AmiQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 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 agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id cn8-20020a056a020a8800b005b9b68add80si3076332pgb.361.2023.11.03.20.56.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 Nov 2023 20:56:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 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 (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id CE52881E5E75; Fri, 3 Nov 2023 20:56:16 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1378001AbjKDD4I (ORCPT <rfc822;lhua1029@gmail.com> + 35 others); Fri, 3 Nov 2023 23:56:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59642 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234297AbjKDDzs (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 3 Nov 2023 23:55:48 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5B5CDD45; Fri, 3 Nov 2023 20:55:44 -0700 (PDT) Received: from dggpemm100001.china.huawei.com (unknown [172.30.72.54]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4SMkGD0WzxzrTQX; Sat, 4 Nov 2023 11:52:36 +0800 (CST) Received: from localhost.localdomain (10.175.112.125) by dggpemm100001.china.huawei.com (7.185.36.93) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.31; Sat, 4 Nov 2023 11:55:41 +0800 From: Kefeng Wang <wangkefeng.wang@huawei.com> To: Andrew Morton <akpm@linux-foundation.org> CC: <linux-kernel@vger.kernel.org>, <linux-mm@kvack.org>, Matthew Wilcox <willy@infradead.org>, David Hildenbrand <david@redhat.com>, <linux-s390@vger.kernel.org>, Kefeng Wang <wangkefeng.wang@huawei.com> Subject: [PATCH v2 02/10] s390: pgtable: use a folio in ptep_zap_swap_entry() Date: Sat, 4 Nov 2023 11:55:14 +0800 Message-ID: <20231104035522.2418660-3-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20231104035522.2418660-1-wangkefeng.wang@huawei.com> References: <20231104035522.2418660-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.112.125] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggpemm100001.china.huawei.com (7.185.36.93) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Fri, 03 Nov 2023 20:56:16 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1781604213728290883 X-GMAIL-MSGID: 1781604213728290883 |
Series |
mm: convert mm counter to take a folio
|
|
Commit Message
Kefeng Wang
Nov. 4, 2023, 3:55 a.m. UTC
Use a folio in ptep_zap_swap_entry(), which is preparetion for
converting mm counter functions to take a folio.
Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
---
arch/s390/mm/pgtable.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/s390/mm/pgtable.c b/arch/s390/mm/pgtable.c index 3bd2ab2a9a34..2f946b493fff 100644 --- a/arch/s390/mm/pgtable.c +++ b/arch/s390/mm/pgtable.c @@ -730,9 +730,9 @@ static void ptep_zap_swap_entry(struct mm_struct *mm, swp_entry_t entry) if (!non_swap_entry(entry)) dec_mm_counter(mm, MM_SWAPENTS); else if (is_migration_entry(entry)) { - struct page *page = pfn_swap_entry_to_page(entry); + struct folio *folio = pfn_swap_entry_to_folio(entry); - dec_mm_counter(mm, mm_counter(page)); + dec_mm_counter(mm, mm_counter(&folio->page)); } free_swap_and_cache(entry); }