Message ID | 20231106154950.3399469-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 j7csp2750283vqu; Mon, 6 Nov 2023 07:51:29 -0800 (PST) X-Google-Smtp-Source: AGHT+IFWb+5BMaGv30P1Qa5YppYOLAUoyFlrYjNPeJMg923wj4PjUZ/56fHlgng7c7eEfR9n0DHl X-Received: by 2002:a05:6a00:1ca0:b0:6c3:1c74:9c5 with SMTP id y32-20020a056a001ca000b006c31c7409c5mr14350003pfw.0.1699285888920; Mon, 06 Nov 2023 07:51:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1699285888; cv=none; d=google.com; s=arc-20160816; b=P/P+aPCl1rcq848Vbx82e0r7prVT8jjrXCY0GCVROIDEPkLI1JVlRDv4rE2BT8aGRN l12xFo57UQDSLAhYECezz5ebgAS+W9Jkl+kh1ulQbooQYIIZ8rqDzaJQN6gfYNoPL1fA bNIvBgtC/6wP2oMaDyw+yBQer9CbMVYnQ8E6+IgU7KdKncxr1OzLaWXWWM1tPrs1i1qD xcRdx55BgFOftN+QFOtRiVP1cLDqp7yVOtpjBF9ITXNKD7WfI2Bkr+xfBb3wpuzO9M32 P76y5S6y+fxYYwr48rUba6AIZyEZ7VJCIOtwlSmrNbDv5D7spSho+ezZEdRutUu+D5rK MFAA== 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=Be8dDiPU4F4BN5latp/s5l4SDKOmOvvLe+l6hsQaRRlWEApEm3rV7Sc1IyMb5k74ME 7HTg05RXYWMhIsKg9JBi9evp6vGqFcLJ6eZERDPZ5cg92TnUtyg+j66p8CLuNJdk2EQS Wtxyl/2cMK6EysLLz6Mnuu94StIeFu2KZcNXpBsQzhJFebNy3uVLRriE9hIWn1jHSkXk O6dzO5tRJisGF5IKsY6gn9s7gcomuilPXr2oUpf09/LaUtjGZBoHuvYpBWwsmz53FfHf 5PmS7jJiNvImPk7fPSDfZTWQXmJ3IN2LQfCRrWsbOBdumWNbdsFiHWDkZbN06P2jlOp7 GCGw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 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 lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id cf7-20020a056a02084700b00565cc12ee24si8850533pgb.874.2023.11.06.07.51.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Nov 2023 07:51:28 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 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 lipwig.vger.email (Postfix) with ESMTP id 0C32F807D98D; Mon, 6 Nov 2023 07:50:29 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232573AbjKFPuI (ORCPT <rfc822;jaysivo@gmail.com> + 35 others); Mon, 6 Nov 2023 10:50:08 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32962 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232326AbjKFPuE (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 6 Nov 2023 10:50:04 -0500 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 51558D45; Mon, 6 Nov 2023 07:50:01 -0800 (PST) Received: from dggpemm100001.china.huawei.com (unknown [172.30.72.55]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4SPG4t11wVzVlmQ; Mon, 6 Nov 2023 23:49:50 +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; Mon, 6 Nov 2023 23:49:59 +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 02/10] s390: pgtable: use a folio in ptep_zap_swap_entry() Date: Mon, 6 Nov 2023 23:49:42 +0800 Message-ID: <20231106154950.3399469-3-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20231106154950.3399469-1-wangkefeng.wang@huawei.com> References: <20231106154950.3399469-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: dggems703-chm.china.huawei.com (10.3.19.180) 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 lipwig.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 (lipwig.vger.email [0.0.0.0]); Mon, 06 Nov 2023 07:50:29 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1781830400310157917 X-GMAIL-MSGID: 1781830400310157917 |
Series |
mm: convert mm counter to take a folio
|
|
Commit Message
Kefeng Wang
Nov. 6, 2023, 3:49 p.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); }