Message ID | 20230807230513.102486-8-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 A1861C04FDF for <linux-mm@archiver.kernel.org>; Mon, 7 Aug 2023 23:05:38 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id E31E694000C; Mon, 7 Aug 2023 19:05:36 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id E0998940008; Mon, 7 Aug 2023 19:05:36 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C5BB594000C; Mon, 7 Aug 2023 19:05:36 -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 B79F7940008 for <linux-mm@kvack.org>; Mon, 7 Aug 2023 19:05:36 -0400 (EDT) Received: from smtpin23.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id 8CF351A0BFE for <linux-mm@kvack.org>; Mon, 7 Aug 2023 23:05:36 +0000 (UTC) X-FDA: 81098842272.23.BEBF79A Received: from mail-yb1-f181.google.com (mail-yb1-f181.google.com [209.85.219.181]) by imf23.hostedemail.com (Postfix) with ESMTP id 87F01140012 for <linux-mm@kvack.org>; Mon, 7 Aug 2023 23:05:33 +0000 (UTC) Authentication-Results: imf23.hostedemail.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=WW7U9RxJ; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (imf23.hostedemail.com: domain of vishal.moola@gmail.com designates 209.85.219.181 as permitted sender) smtp.mailfrom=vishal.moola@gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1691449533; 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=dV51lKtiOhMWQgAl7GNvRpOxJtkn3o5Ia4Rm5PKGOL0=; b=4DzgIhawf5kHfmcTRQGsi7XAO8PfF80qjMy9edtU0o0uO47F2vr1GV9Rlz1bNNO60OT85g 5mKa6QCS8bVEcfEDmXVC/uHhGNTtXDNUqIlkpZwmmIecHAc8KDw0ZgtmJ0cNHEI1nX14RN YG7QDX1CfT3qbWXrlijCIX18pWDOiHg= ARC-Authentication-Results: i=1; imf23.hostedemail.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=WW7U9RxJ; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (imf23.hostedemail.com: domain of vishal.moola@gmail.com designates 209.85.219.181 as permitted sender) smtp.mailfrom=vishal.moola@gmail.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1691449533; a=rsa-sha256; cv=none; b=6UpEaFqFTno3RzMx4ZD4ikOPuahsHlbKo9wYyg2S/nAX0J7Qy81lPr7dmoeato2SkgT5BG Yq/Cq/c20QbGrbRh3gmYA/zKQSBzL48u5urSPkJxxQCpahRDKKn7g6uIoQd5xykMeNZtkF 4pEZZYPNrd0ceTC2kRuS2ZOMoBOrrr8= Received: by mail-yb1-f181.google.com with SMTP id 3f1490d57ef6-d3563cb41e9so4205372276.0 for <linux-mm@kvack.org>; Mon, 07 Aug 2023 16:05:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691449532; x=1692054332; 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=dV51lKtiOhMWQgAl7GNvRpOxJtkn3o5Ia4Rm5PKGOL0=; b=WW7U9RxJoy+3YY4y3qa+Z9OsxlwmyOU3wMBaX5rDPLFmIEHt/X6v4NdYOpBq8PRkh5 HGAvbPPuVPcaXp+7bIkcS5zKLOts7aoRAq2rmpfhl809GhQ5Z7qhyD2D1O9jUw02JT8D ByQrQ+74LtD1rxejz5iV5Ji3t3biqjBaLILP+cGmcXMABNbKMRqAqcPv+Q5eVbDOwvco pnySxrcubM/hR4SWo6309aJr0ghUYXqxorm9LprpxBDG4pKG7rw8FnMSIxuCIl+L3G3f pQ7sJFVehZ1e4LudKLyLwUTD+K2Hcr+cYbBqgmDPIUau/hEmU0pgvAzvLPGNFfNzyEIP WwxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691449532; x=1692054332; 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=dV51lKtiOhMWQgAl7GNvRpOxJtkn3o5Ia4Rm5PKGOL0=; b=evVtpxdAL1BHAqFJxMZeArqcu19zniwr8anhfoUUGxk2VuKQ20jRt/R6NZamEhWlYS 8Ak3aE8qyRjwKsyz2G2U3XAB9v8Fk1o1qRoHoKX25CinYYNtKPZDQfH4WYyb0CvfJgsV mNu7qJwRGr2g7ZcK/10tOgwy6fHrzJZ8cacL1armXtjhRiTjc14WD/RwglIFjw7NObFE 61Bwb1fOYrq8tYLYSjzbOzKd/0YLEI8pkHEfxYxWFeoUEC05oEM36Bjw6o365NqDthoj 8PfNTfTD9x5cQx+dYTpKdyk2xhHorYScIaghug9CpCoNtxYkQLsuyfDLs/qRjh+vkbP8 zwRg== X-Gm-Message-State: AOJu0YyWcndvUSLt6lKQf4DuEi8BkePl+QwIeSMQh9Lg76TuUSEQtAuQ EMySCCSXc3tYitV2I1AhCpA= X-Google-Smtp-Source: AGHT+IEvrDCY+UE05HZYU4gf4n6Ovk9myxbAlbrTcNmkwiJKi0vLSKG9giGoSfLWvI4ILhQ42gUDlQ== X-Received: by 2002:a25:bd7:0:b0:d14:6e28:69a4 with SMTP id 206-20020a250bd7000000b00d146e2869a4mr9317696ybl.29.1691449532541; Mon, 07 Aug 2023 16:05:32 -0700 (PDT) Received: from unknowna0e70b2ca394.attlocal.net ([2600:1700:2f7d:1800::16]) by smtp.googlemail.com with ESMTPSA id d190-20020a25cdc7000000b00d3596aca5bcsm2545203ybf.34.2023.08.07.16.05.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Aug 2023 16:05:32 -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 mm-unstable v9 07/31] mm: Convert pmd_ptlock_init() to use ptdescs Date: Mon, 7 Aug 2023 16:04:49 -0700 Message-Id: <20230807230513.102486-8-vishal.moola@gmail.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230807230513.102486-1-vishal.moola@gmail.com> References: <20230807230513.102486-1-vishal.moola@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 87F01140012 X-Rspam-User: X-Rspamd-Server: rspam04 X-Stat-Signature: wqsfchbdgmfc5q1arm946zhdxi988gtk X-HE-Tag: 1691449533-300260 X-HE-Meta: U2FsdGVkX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aqZ0TTLUo41Ai0zIpHmBqCjf47rTvbvWfIkzPAlLMk8L3edatBmVMnX2gqmy9lIplGdUjVtme3uS4mc13mo5GBpeONefaGW1L5cA8lFXaKoYx/WwwyikMoKYq7Vtdg3H91iXsjpGkghz3syqEtB/QDiM5dUhvV203B6do5vpTmmyVh6160ilA3nKeO7U2HIpL6TmmcDevsG3CUgF0SR829erSJ2JazfNNIY5h0Pghw+MBwfMxH2hFmNAbvkgSIp+nPfS8yyU0QDZaMU88wYnR46/33sRFhRQ9r8GXfiKLCtuodBhgTX9xHhBhyqP4v+39eHYsmlnWYaS1OecJnbRS7J9MP7c0CC/fjWBAR2rhOtiKbfQ6wqQ4C1kok37Q+I7F1usl9CqwSPzSt6PYxDIDruVFvAmXG1oL3hfDwJNKRPyzSQJA1TmBl8yWJ8LUI9EbHxxOEF0v5BYsGMlBbe6uVA5eVOKsHRnfi8vw0xhso3en+YbuFbEBn2aWbJhp5FfZaeSA3W5c1OEwaZZXcZXsDaEiTa9ovsMKnUIXuD4= 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 bc82a64e5f01..040982fe9063 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -2993,12 +2993,12 @@ static inline spinlock_t *pmd_lockptr(struct mm_struct *mm, pmd_t *pmd) return ptlock_ptr(pmd_ptdesc(pmd)); } -static inline bool pmd_ptlock_init(struct page *page) +static inline bool pmd_ptlock_init(struct ptdesc *ptdesc) { #ifdef CONFIG_TRANSPARENT_HUGEPAGE - page->pmd_huge_pte = NULL; + ptdesc->pmd_huge_pte = NULL; #endif - return ptlock_init(page); + return ptlock_init(ptdesc_page(ptdesc)); } static inline void pmd_ptlock_free(struct page *page) @@ -3018,7 +3018,7 @@ static inline spinlock_t *pmd_lockptr(struct mm_struct *mm, pmd_t *pmd) return &mm->page_table_lock; } -static inline bool pmd_ptlock_init(struct page *page) { return true; } +static inline bool pmd_ptlock_init(struct ptdesc *ptdesc) { return true; } static inline void pmd_ptlock_free(struct page *page) {} #define pmd_huge_pte(mm, pmd) ((mm)->pmd_huge_pte) @@ -3034,7 +3034,7 @@ static inline spinlock_t *pmd_lock(struct mm_struct *mm, pmd_t *pmd) static inline bool pgtable_pmd_page_ctor(struct page *page) { - if (!pmd_ptlock_init(page)) + if (!pmd_ptlock_init(page_ptdesc(page))) return false; __SetPageTable(page); inc_lruvec_page_state(page, NR_PAGETABLE);