Message ID | 20230622205745.79707-11-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 A12E6EB64DA for <linux-mm@archiver.kernel.org>; Thu, 22 Jun 2023 20:58:20 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 39FCE8D000D; Thu, 22 Jun 2023 16:58:20 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 3774F8D0001; Thu, 22 Jun 2023 16:58:20 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 107428D000D; Thu, 22 Jun 2023 16:58:20 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id EF0AB8D0001 for <linux-mm@kvack.org>; Thu, 22 Jun 2023 16:58:19 -0400 (EDT) Received: from smtpin15.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 93A2D8011C for <linux-mm@kvack.org>; Thu, 22 Jun 2023 20:58:19 +0000 (UTC) X-FDA: 80931596718.15.44F4E30 Received: from mail-yb1-f175.google.com (mail-yb1-f175.google.com [209.85.219.175]) by imf29.hostedemail.com (Postfix) with ESMTP id 982FE120010 for <linux-mm@kvack.org>; Thu, 22 Jun 2023 20:58:17 +0000 (UTC) Authentication-Results: imf29.hostedemail.com; dkim=pass header.d=gmail.com header.s=20221208 header.b="I/bVEj+D"; spf=pass (imf29.hostedemail.com: domain of vishal.moola@gmail.com designates 209.85.219.175 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=1687467497; a=rsa-sha256; cv=none; b=UAbrYzAuPy9CMnIVj+xkVW430qAdZmku7TIfP4aYBV+5urLjS+bTHZmeyT+4nFTVeXxI5f YERvxO7UKZw6q+8hMQRzhQtx3JYmdUuVlNcpvk4W1xFlPuaE57xnAzpPF9EKjQg278Hh90 Tx0RMDceHwT5g5jc4G0GFvX9bfunchQ= ARC-Authentication-Results: i=1; imf29.hostedemail.com; dkim=pass header.d=gmail.com header.s=20221208 header.b="I/bVEj+D"; spf=pass (imf29.hostedemail.com: domain of vishal.moola@gmail.com designates 209.85.219.175 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=1687467497; 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=wSwuU7fg/k+TT5PagWIdYLap7GxOydHG9fnVI01D6B4=; b=AM2bQkMWiznyzME90NOeQxnWeW2EbgQ647J5VWhFuHj5umJux2zjaOdPrcUrtQDnUmbyeY eLRFQncNMCQUgCMdbF058/EZr7/LfP2fGKu6+OyHI7BfAJwLW2t4IbYk6PQs50JCCxZ1XZ uVtnI5KDwif2ir3MjQH3REPtD1ok+90= Received: by mail-yb1-f175.google.com with SMTP id 3f1490d57ef6-bfee66a5db6so2126168276.0 for <linux-mm@kvack.org>; Thu, 22 Jun 2023 13:58:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1687467496; x=1690059496; 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=wSwuU7fg/k+TT5PagWIdYLap7GxOydHG9fnVI01D6B4=; b=I/bVEj+DUjJI8l/gEF/kUAGaYNT5Bo0ZW57h+bRIiIunD3HbfI+MBQBKO4xoy6kMld by9iDd+YOlloG6orphek9MUhK7idN+HCTnjbwImmtOZyc6e9u9PHx9KvfH/RMgtU+eEw KkmIT3OJU3QYrQoQpzTDW/lNw6UL91T+VL7WZPaAaf3blTIwnU3tSpIBE8mZnuXVnYm+ rvZ17E5R9YwQ5EOQRDXtuuSLgHPTNFwHVzddHdU5MZn7f0HGX0TpCThXTZUeoTrDSQuu 9j0W4VdWm0ZtykEhgIk1WPxDhiiNhplU95urAkZpVmBWbtxqWeEVwFyvBy3V06yBmQux q4sw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687467496; x=1690059496; 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=wSwuU7fg/k+TT5PagWIdYLap7GxOydHG9fnVI01D6B4=; b=Wr9x+xvKQEHaM1u5JGgLv1g/Q0MMtZXVgPIo4XbtcdtwQ5X1RPEE27JKjU+HmknSZQ PgJGMzaKgxuIWIHEdIDkieGFgcN/1d0n4kClsABAT9yba54sClUAuuc7ufdkMWw0VbXQ 4o2DKzPCmCItq3zp3ncHSTga/iBi7fzYrQcDoExPTMxqMPVgXFnkq/1cdYqeSWqwHFIE vq4j6ygaY0xcZKwtUnGy0R7CbCVpmoIUBITuGwBY9mzdyVgi2BWqhqd1hOXoQ0Ug/ASG ECPUwm4aElAawibHXsxFDB8o+D77+TJKQTcUuNF55ROdp+yaOwdq1HiwHB+pMuUUi3qE 1tUg== X-Gm-Message-State: AC+VfDyODazc5ps+qY5Dcg8QSS0rLpkGQMGEwVkEoqXnchgfGSYfvlFE Bzp/FL0y9fxP7CfakmWqaKA= X-Google-Smtp-Source: ACHHUZ4fKnSuVlprYtWMiqysn5f2VA+PJ55bhXLl+JTYwbJxQpJ17qCGbx2gEAsv8+8GLejR/TMFxQ== X-Received: by 2002:a25:6982:0:b0:ba8:1c9e:c77f with SMTP id e124-20020a256982000000b00ba81c9ec77fmr9956027ybc.22.1687467496585; Thu, 22 Jun 2023 13:58:16 -0700 (PDT) Received: from unknowna0e70b2ca394.attlocal.net ([2600:1700:2f7d:1800::36]) by smtp.googlemail.com with ESMTPSA id d18-20020a5b0c52000000b00bc501a1b062sm1684937ybr.42.2023.06.22.13.58.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Jun 2023 13:58:16 -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, Hugh Dickins <hughd@google.com>, "Vishal Moola (Oracle)" <vishal.moola@gmail.com>, Mike Rapoport <rppt@kernel.org> Subject: [PATCH v5 10/33] mm: Convert pmd_ptlock_free() to use ptdescs Date: Thu, 22 Jun 2023 13:57:22 -0700 Message-Id: <20230622205745.79707-11-vishal.moola@gmail.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230622205745.79707-1-vishal.moola@gmail.com> References: <20230622205745.79707-1-vishal.moola@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Server: rspam08 X-Rspamd-Queue-Id: 982FE120010 X-Stat-Signature: xcg83d3gpftcjhp1sy6sna41ci5xfqg3 X-Rspam-User: X-HE-Tag: 1687467497-671803 X-HE-Meta: U2FsdGVkX1/Z37MvE0gGH/tCFr7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AjVlZGerZc20Fh6i47AUQBiUq7y9mt8M0AByfeZNup0LVBgbvdPCvJ9MnxxAN/lIP4iCgrP76x3/4EstkKDjMwTTojrOXzlh6Xrhj/uCseJj1/nnT0mjlWnjCZZdHo3FnJjwELOZ/jk6SknJBP8BAgUqf15laR+lijWLNuwOisF0JeXtMwClrsmEQFcsZNZHdprYEUg9xIfGKg999etHMv6ZEvxxoz8jMSQcgIeDs4EMsuw74keJhYsymFoSqqcmGKNJ6jg6YAvjYs8WOe82+2xbOhC/BxfE0o53B/EXvi3shGMTl2uDh6KHythnBcMbXwqv23uWs5+GxTNs46WD0KISummSnX+OQ74BfyEJcVY8oABcd6lGZFHwBgpSZbZyqCA+rqClpC5505QZLbgey9vfhrYodKnAd1/f5hoQfH5ccY2zuDoD89Qu583qbbDHVABUWrYocNcjaZ2aZV1YeAGo8si6F/bMeXkrx3KhQs6n4/PBo2pAC+nyx/E0Fd7NkOjG2CbyYXAevd1lTx/Lrs= 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/include/linux/mm.h b/include/linux/mm.h index 4af424e4015a..0221675e4dc5 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -2934,12 +2934,12 @@ static inline bool pmd_ptlock_init(struct ptdesc *ptdesc) return ptlock_init(ptdesc); } -static inline void pmd_ptlock_free(struct page *page) +static inline void pmd_ptlock_free(struct ptdesc *ptdesc) { #ifdef CONFIG_TRANSPARENT_HUGEPAGE - VM_BUG_ON_PAGE(page->pmd_huge_pte, page); + VM_BUG_ON_PAGE(ptdesc->pmd_huge_pte, ptdesc_page(ptdesc)); #endif - ptlock_free(page); + ptlock_free(ptdesc_page(ptdesc)); } #define pmd_huge_pte(mm, pmd) (pmd_ptdesc(pmd)->pmd_huge_pte) @@ -2952,7 +2952,7 @@ static inline spinlock_t *pmd_lockptr(struct mm_struct *mm, pmd_t *pmd) } static inline bool pmd_ptlock_init(struct ptdesc *ptdesc) { return true; } -static inline void pmd_ptlock_free(struct page *page) {} +static inline void pmd_ptlock_free(struct ptdesc *ptdesc) {} #define pmd_huge_pte(mm, pmd) ((mm)->pmd_huge_pte) @@ -2976,7 +2976,7 @@ static inline bool pgtable_pmd_page_ctor(struct page *page) static inline void pgtable_pmd_page_dtor(struct page *page) { - pmd_ptlock_free(page); + pmd_ptlock_free(page_ptdesc(page)); __ClearPageTable(page); dec_lruvec_page_state(page, NR_PAGETABLE); }