From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 1453A3E6381 for ; Tue, 18 Aug 2026 18:36:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787078180; cv=none; b=Pl92aFi/Sd6rxaFVZKMkBLrVswAmdjvdLFPFoRQYJf0DaHNZFtD7xAFKCjOglTt4o3duCLgA+ZXGce7I/XC6TI66tU4uQNMnnDTy+BZMJ/D6ua/iDsHlUKdNfEM6zdnPd452FMZUVHQPXzJsu2lPcZjdB11T72HhETZo3Z43ziM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787078180; c=relaxed/simple; bh=qLKLkPfSr08i/nx599JFD26d9wLcdRMFoNDUU+kENPs=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=FTtwBGQgdYaqL8x8X9PBO4wjUmTI53HFQ523jPMbhOok0jcOFsehDbyLAvqmhkYya8w2WsN1XB6MOEHGTSJHtwsf41i/3EQsR3Aby1mEU4RfjrQnxg7ecxYOq8ALBu+3k+1TLEvUUH48JuIA3hR+zZQ+cahy/aZiSutNWOiwjf0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=MyHq7W5o; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="MyHq7W5o" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 789A31F000E9; Tue, 18 Aug 2026 18:36:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1787078178; bh=gLXr51pEzCHb64ANlWwZ4uIr0YOOxG5gL44VOYDF9ao=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=MyHq7W5oDXYZnvecjeNJ3DZ4zGEdUDSeKFlocju1hBoH49qYmq2UB2kWjY47Bspna v71OzKQV7UyMhJrXBXs72BTWlIsYj1pZ+ft6/8v4m3lhrnjT8E4LOtKQutuDjcJ1+C vP25TI14lVPJzISwlnC7liKSjZZLx63tpGPmb6HyIsnDzBDZrS0CL5ivipLLt23szL rGV01JIl+ySkp0uSY9SRGXtENONcVandoNltQv5274MbIaBvswX1esEmibPYjNNaU7 jqSDg216CGrXCSL60EnQs8GdYYKEexrbR0EbGpVLjUV9+B7gpTMow9I1j5foVxFzwm pyGmBHIGJz6Xg== Date: Tue, 18 Aug 2026 19:36:09 +0100 From: "Lorenzo Stoakes (ARM)" To: Usama Arif Cc: Andrew Morton , david@kernel.org, chrisl@kernel.org, kasong@tencent.com, ziy@nvidia.com, linux-mm@kvack.org, ying.huang@linux.alibaba.com, Baoquan He , willy@infradead.org, youngjun.park@lge.com, hannes@cmpxchg.org, riel@surriel.com, shakeel.butt@linux.dev, alex@ghiti.fr, kas@kernel.org, baohua@kernel.org, dev.jain@arm.com, baolin.wang@linux.alibaba.com, Nico Pache , "Liam R. Howlett" , ryan.roberts@arm.com, Vlastimil Babka , lance.yang@linux.dev, linux-kernel@vger.kernel.org, nphamcs@gmail.com, shikemeng@huaweicloud.com, yosry@kernel.org, kernel-team@meta.com Subject: Re: [PATCH v6 01/12] mm: rename pmd_to_softleaf_folio() to pmd_softleaf_to_folio() Message-ID: References: <20260818131202.494754-1-usama.arif@linux.dev> <20260818131202.494754-2-usama.arif@linux.dev> 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: <20260818131202.494754-2-usama.arif@linux.dev> On Tue, Aug 18, 2026 at 06:09:42AM -0700, Usama Arif wrote: > pmd_to_softleaf_folio() converts the softleaf entry encoded by a PMD > to a folio. Rename it to pmd_softleaf_to_folio() to make the conversion > direction explicit and align it with softleaf_to_folio(). > > No functional change. > > Suggested-by: Dev Jain > Signed-off-by: Usama Arif Haha OK fair enough that's a valid correction! Reviewed-by: Lorenzo Stoakes (ARM) > --- > include/linux/leafops.h | 4 ++-- > mm/huge_memory.c | 2 +- > 2 files changed, 3 insertions(+), 3 deletions(-) > > diff --git a/include/linux/leafops.h b/include/linux/leafops.h > index 4c1476ae32343..7c13c58a5e218 100644 > --- a/include/linux/leafops.h > +++ b/include/linux/leafops.h > @@ -657,7 +657,7 @@ static inline bool pmd_is_valid_softleaf(pmd_t pmd) > } > > /** > - * pmd_to_softleaf_folio() - Convert the PMD entry to a folio. > + * pmd_softleaf_to_folio() - Convert the PMD softleaf entry to a folio. > * @pmd: PMD entry. > * > * The PMD entry is expected to be a valid PMD softleaf entry. > @@ -665,7 +665,7 @@ static inline bool pmd_is_valid_softleaf(pmd_t pmd) > * Returns: the folio the softleaf entry references if this is a valid softleaf > * entry, otherwise NULL. > */ > -static inline struct folio *pmd_to_softleaf_folio(pmd_t pmd) > +static inline struct folio *pmd_softleaf_to_folio(pmd_t pmd) > { > const softleaf_t entry = softleaf_from_pmd(pmd); > > diff --git a/mm/huge_memory.c b/mm/huge_memory.c > index ced400f72d43a..1b6b0aa2baa3b 100644 > --- a/mm/huge_memory.c > +++ b/mm/huge_memory.c > @@ -2467,7 +2467,7 @@ static struct folio *normal_or_softleaf_folio_pmd(struct vm_area_struct *vma, > > if (!thp_migration_supported()) > WARN_ONCE(1, "Non present huge pmd without pmd migration enabled!"); > - return pmd_to_softleaf_folio(pmdval); > + return pmd_softleaf_to_folio(pmdval); > } > > static bool has_deposited_pgtable(struct vm_area_struct *vma, pmd_t pmdval, > -- > 2.53.0-Meta > -- Cheers, Lorenzo