From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 73EB615ADB4 for ; Fri, 20 Feb 2026 10:25:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771583143; cv=none; b=sAn60V1ImnGpYZBRHx6MtbnbSBVVawBOUshoWWZXd4RkLtGh1gXknjEBuhkAyLqcHk1FUk9+ZvBskLdXrXQituwkzzZlLanlYB7QleVPBo5ZL4zohSiX7ipdM6QRC5a6GJjSZM6EpjvWv5Y6A0b922HArY3fUzLqMsNMawPwLV0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771583143; c=relaxed/simple; bh=fHah0S5EiDYqAgVFYIH+gMaVRw0f/1dDoBvuNE5U2VI=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=d/eIVPVAIfnDiKxiv6XQRSd6uSVFGZyCCryUHYgF6CWzJxQvPO3cAuh7vcVgXONhtt+hoKqQGDrK5VIdvDyinbjTq0ZLF9H5NwCYTrMKOIY1qS2sZ8kk8PFqEM2CI+7/kxcmUqsmP/J5wBtCwzr3U89oQBJCCAbulSqRdAidMqQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=RN7maaPJ; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="RN7maaPJ" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 09801C116C6; Fri, 20 Feb 2026 10:25:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1771583143; bh=fHah0S5EiDYqAgVFYIH+gMaVRw0f/1dDoBvuNE5U2VI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=RN7maaPJvT08Xjj1xqxQX7/6YIpJ67iktTwqQUoO/AuJZ/51ixeV3h0DvF2QGF9n9 qVNhmzOUKgR7bymsT+7lLXaoV3MQNZJ/2jtu0D3kRHqbUN5jmN6oUv7GjFxlOwTFkH 1TwIl/N3tp4jqHzj7JmBJj8OGhRLNA1JGHokVT1OWfvA9YpIeb1VZDrsWdMZCdv0bN i/QjySoM1tg7kYeIQFK3UytAVsfnjzQfbstOvjsTcSiVVuLJhn1pgejcL3kknCkf2e ogEYWRK5OdB5mD3k1e75M47/hvMVIcRhGTZ+Cc7tZwpQT3qF1I3I0geNTsv5a8NWbc WrVuYRNuVbz5Q== Date: Fri, 20 Feb 2026 12:25:36 +0200 From: Mike Rapoport To: "Vishal Moola (Oracle)" Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, x86@kernel.org, Dave Hansen , "Matthew Wilcox (Oracle)" , akpm@linux-foundation.org, Andy Lutomirski , Peter Zijlstra Subject: Re: [PATCH v6 0/4] Convert x86/mm/pat to generic page table apis Message-ID: References: <20260219020354.321088-1-vishal.moola@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20260219020354.321088-1-vishal.moola@gmail.com> On Wed, Feb 18, 2026 at 06:03:50PM -0800, Vishal Moola (Oracle) wrote: > set_memory.c has a call to pagetable_free(), while the allocation sites > use get_free_pages(). This causes issues separately allocating ptdescs > from struct page. > > It turns out that we can just use the appropriate generic pagetable > apis for allocation/freeing. This helps simplify and standardize the > code. > > In the short term, this helps enable Matthew's work to allocate frozen > pagetables[1]. And in the long term, this will help us cleanly split > ptdesc allocations from struct page[2]. > > [1] https://lore.kernel.org/linux-mm/20251113140448.1814860-1-willy@infradead.org/ > [2] https://lore.kernel.org/linux-mm/20251020001652.2116669-1-willy@infradead.org/ > > ------ > > Based on current mm-new. > > v6: > - Drop the renaming of *page* functions > - Use existing page table api instead of creating new apis > - Split the pmd and populate_pgd() changes into separate patches > - Reword the cover letter to describe the new approach > > v5 link: > https://lore.kernel.org/all/20260211195233.368497-1-vishal.moola@gmail.com/ > > Vishal Moola (Oracle) (4): > x86/mm/pat: Convert pte code to use page table apis > x86/mm/pat: Convert pmd code to use page table apis > x86/mm/pat: Convert populate_pgd() to use page table apis > x86/mm/pat: Convert split_large_page() to use ptdescs > > arch/x86/mm/pat/set_memory.c | 36 ++++++++++++++++++++++++------------ > 1 file changed, 24 insertions(+), 12 deletions(-) Acked-by: Mike Rapoport (Microsoft) > > -- > 2.53.0 > -- Sincerely yours, Mike.