Message ID | 20230417205048.15870-32-vishal.moola@gmail.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id A5F56C88CB3 for <linux-mm@archiver.kernel.org>; Mon, 17 Apr 2023 20:53:48 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 0A504280005; Mon, 17 Apr 2023 16:53:32 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 02D8690000D; Mon, 17 Apr 2023 16:53:31 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id DC287280005; Mon, 17 Apr 2023 16:53:31 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id BFFB190000D for <linux-mm@kvack.org>; Mon, 17 Apr 2023 16:53:31 -0400 (EDT) Received: from smtpin06.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id 9F4121C66E6 for <linux-mm@kvack.org>; Mon, 17 Apr 2023 20:53:31 +0000 (UTC) X-FDA: 80692083822.06.2680A7F Received: from mail-pl1-f179.google.com (mail-pl1-f179.google.com [209.85.214.179]) by imf15.hostedemail.com (Postfix) with ESMTP id 94447A000F for <linux-mm@kvack.org>; Mon, 17 Apr 2023 20:53:29 +0000 (UTC) Authentication-Results: imf15.hostedemail.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=Bs6MBnbj; spf=pass (imf15.hostedemail.com: domain of vishal.moola@gmail.com designates 209.85.214.179 as permitted sender) smtp.mailfrom=vishal.moola@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1681764809; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=CSVYEUhM0zGHlDR1yqa5KIpwwPynV1rh1Z3AvIT239o=; b=OrPNkZfSpgOH5cjfFo4l6iwguCJSWl/4cjKHQ30hXDUmeqR7LdZT+5BPTnhM3QQLYm5iau DpXh+HXuTLA8Df2ZqbffM9TKFArdzLWi3ztUEqoxVYjaoJQm9B9Nr1cZUIQS8SqWZ5EHEr UlUI1EvRsbXUz3+p8nbuVwH3U9eP6CA= ARC-Authentication-Results: i=1; imf15.hostedemail.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=Bs6MBnbj; spf=pass (imf15.hostedemail.com: domain of vishal.moola@gmail.com designates 209.85.214.179 as permitted sender) smtp.mailfrom=vishal.moola@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1681764809; a=rsa-sha256; cv=none; b=HLYJ5lP8uozVDVEb6/e6HDnhsKoPgNZj3XEVoHmBjxCYRZ/7QCw220/3blhW6d3mEV3vKD VN1JxFpxzdSU1hXNqZopMapBGeu+XjufvjuOhsx71u6VUsRm4WJ5tUpHZqiV/YenaG8tLJ xLr3NZoqX2UjgVMmjW1Kca+21b0FvlE= Received: by mail-pl1-f179.google.com with SMTP id i8so18360383plt.10 for <linux-mm@kvack.org>; Mon, 17 Apr 2023 13:53:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1681764808; x=1684356808; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=CSVYEUhM0zGHlDR1yqa5KIpwwPynV1rh1Z3AvIT239o=; b=Bs6MBnbjQkX1GScZCbLklar3CQYsHMcNQJhdEJMSRoz85XciXhpnQ0YtDU9kdG/nWk TxMCtPr19eviQJI5aQ6Z23KjvD0/UYdwUUF801SK8Z3tk/XuPH8n6ufK4lU6OPOoTkEa tcxsOYaiL60cLVhSI6wekl2Ojt4T3pVi0l4/Kpd6dmP8a2GTqJPhoPlibhYfl7AzaVkC 8dHP626PMZuKBlHUuWDeE5Ws0Xf5nvhx1+eNXqdjJYxnU1JpJLYxfuGpVyKb6jdKhgqK l+AozFzFnnh8JDe5VzEpQS6lDqTnIa40opwHXXYLbmcB20BMSqSIISIYF0OD142rh4KG 4Sbw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681764808; x=1684356808; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CSVYEUhM0zGHlDR1yqa5KIpwwPynV1rh1Z3AvIT239o=; b=ikefq+YH2r3SePCnFERYyrx29InJWCEcX7pQ7zXMGB+0XulWsa72gYznEHPpfCLukW BlXv5RvZGBJy4meAimRT/UYuesR1olQGw0YPk1qETxbtq3cjam5R+MYjGPepjCS29pdk pymX5DZLgZhTrANqyiXrTe4y2ab+Ccxa1M6Yv1GoKLFClOLzCUrNFTn056z4bAS5MiGB DaLWwF2PU0N3kBt9kiQmZL/xgdpMRbHjQChbOj9iw1nvdtI3aUUUsrOLN2ixprvhqAi1 EkJ1OfCRHLjVqWcF3z53j36bneX0J1CyuDxUU0E3IlmDonY9hTsOYnwWkXIcXuCposdn +gWg== X-Gm-Message-State: AAQBX9f8KiM+QQgpRyds/zK3SDtfcbHLZo4MTCXqDxkI9heON7UioDdn E4CLqny9b3WvDCvVIKlow5M= X-Google-Smtp-Source: AKy350a2GcdGbRUVrvD14pA7yb7zjU30cICJUnhJQSgTB8CRLuH7Cup5yhi/f0UjvURoMBG/RaZdVQ== X-Received: by 2002:a17:903:1206:b0:19f:1871:3dcd with SMTP id l6-20020a170903120600b0019f18713dcdmr272381plh.5.1681764808447; Mon, 17 Apr 2023 13:53:28 -0700 (PDT) Received: from fedora.hsd1.ca.comcast.net ([2601:644:937f:7f20::c139]) by smtp.googlemail.com with ESMTPSA id h7-20020a17090ac38700b0022335f1dae2sm7609707pjt.22.2023.04.17.13.53.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Apr 2023 13:53:28 -0700 (PDT) From: "Vishal Moola (Oracle)" <vishal.moola@gmail.com> To: Andrew Morton <akpm@linux-foundation.org>, Matthew Wilcox <willy@infradead.org> Cc: linux-mm@kvack.org, linux-arch@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-csky@vger.kernel.org, linux-hexagon@vger.kernel.org, loongarch@lists.linux.dev, linux-m68k@lists.linux-m68k.org, linux-mips@vger.kernel.org, linux-openrisc@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, linux-sh@vger.kernel.org, sparclinux@vger.kernel.org, linux-um@lists.infradead.org, xen-devel@lists.xenproject.org, kvm@vger.kernel.org, "Vishal Moola (Oracle)" <vishal.moola@gmail.com> Subject: [PATCH 31/33] sparc: Convert pgtable_pte_page_{ctor, dtor}() to ptdesc equivalents Date: Mon, 17 Apr 2023 13:50:46 -0700 Message-Id: <20230417205048.15870-32-vishal.moola@gmail.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230417205048.15870-1-vishal.moola@gmail.com> References: <20230417205048.15870-1-vishal.moola@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: 94447A000F X-Stat-Signature: wei3cw9k3eb7zfmy3scgs5ho84a8yr5x X-Rspam-User: X-HE-Tag: 1681764809-685495 X-HE-Meta: U2FsdGVkX19UNgOYEiFp5hqMRHFYVAqHyYY2dznrxvlS/3/p2mL8XyFTSWsPImOkvhYddmloEQHobUruUhpOV0dEORq1zK0jGjT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sjHNzqUtPo05H39cyrCFdUmfZWLGU1PFDf4TUP/N2WYAcTZz+qSYY3z6L4pbUxS/LAsiRj0y+xvjp9Sb1dFqF5gCTEtE2itC3Py8EuUBydZG3U5a7ySv7ZdG/x5bFDZpA9O/A5+DvFX0tMrQ1VCzEJDa7OyaIbvA2Hu+z2Tb0HxGIMuaE66/a4NjMZNBqF6WKSa3IiwdwuqODmT23ppbLgk5KKny+ulegJOOUXZi6FNHuDJc3amLLDnL5lmwEDYgQTX8bSl0B68ox5ZhC97w4Hw1CByTjFqVbGz2Wt97nPysNeDJWFlBAIfEZAOBs2LCPNKQI9nToRVuswKSU89PQusm8eRsZMjns0xw8Pd5MYG9pFGY4h9Loyl6DWj2lv2shEXHZ6UgYYpuyykbb/uYybIlQf++VN+yzgXAVcpA== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> |
Series |
Split ptdesc from struct page
|
expand
|
diff --git a/arch/sparc/mm/srmmu.c b/arch/sparc/mm/srmmu.c index 13f027afc875..964938aa7b88 100644 --- a/arch/sparc/mm/srmmu.c +++ b/arch/sparc/mm/srmmu.c @@ -355,7 +355,8 @@ pgtable_t pte_alloc_one(struct mm_struct *mm) return NULL; page = pfn_to_page(__nocache_pa((unsigned long)ptep) >> PAGE_SHIFT); spin_lock(&mm->page_table_lock); - if (page_ref_inc_return(page) == 2 && !pgtable_pte_page_ctor(page)) { + if (page_ref_inc_return(page) == 2 && + !ptdesc_pte_ctor(page_ptdesc(page))) { page_ref_dec(page); ptep = NULL; } @@ -371,7 +372,7 @@ void pte_free(struct mm_struct *mm, pgtable_t ptep) page = pfn_to_page(__nocache_pa((unsigned long)ptep) >> PAGE_SHIFT); spin_lock(&mm->page_table_lock); if (page_ref_dec_return(page) == 1) - pgtable_pte_page_dtor(page); + ptdesc_pte_dtor(page_ptdesc(page)); spin_unlock(&mm->page_table_lock); srmmu_free_nocache(ptep, SRMMU_PTE_TABLE_SIZE);
Part of the conversions to replace pgtable pte constructor/destructors with ptdesc equivalents. Signed-off-by: Vishal Moola (Oracle) <vishal.moola@gmail.com> --- arch/sparc/mm/srmmu.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)