[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1612321006.e59gckigqu.astroid@bobo.none>
Date: Wed, 03 Feb 2021 13:01:47 +1000
From: Nicholas Piggin <npiggin@...il.com>
To: Russell King - ARM Linux admin <linux@...linux.org.uk>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Christophe Leroy <christophe.leroy@...roup.eu>,
Ding Tianhong <dingtianhong@...wei.com>,
Christoph Hellwig <hch@...radead.org>,
Jonathan Cameron <Jonathan.Cameron@...wei.com>,
linux-arch@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org, linux-mm@...ck.org,
linuxppc-dev@...ts.ozlabs.org,
Rick Edgecombe <rick.p.edgecombe@...el.com>
Subject: Re: [PATCH v12 01/14] ARM: mm: add missing pud_page define to 2-level
page tables
Excerpts from Russell King - ARM Linux admin's message of February 2, 2021 9:13 pm:
> On Tue, Feb 02, 2021 at 09:05:02PM +1000, Nicholas Piggin wrote:
>> diff --git a/arch/arm/include/asm/pgtable.h b/arch/arm/include/asm/pgtable.h
>> index c02f24400369..d63a5bb6bd0c 100644
>> --- a/arch/arm/include/asm/pgtable.h
>> +++ b/arch/arm/include/asm/pgtable.h
>> @@ -166,6 +166,9 @@ extern struct page *empty_zero_page;
>>
>> extern pgd_t swapper_pg_dir[PTRS_PER_PGD];
>>
>> +#define pud_page(pud) pmd_page(__pmd(pud_val(pud)))
>> +#define pud_write(pud) pmd_write(__pmd(pud_val(pud)))
>
> As there is no PUD, does it really make sense to return a valid
> struct page (which will be the PTE page) for pud_page(), which is
> several tables above?
There is no PUD on 3-level either, and the pgtable-nopud.h which it uses
also passes down p4d_page to pud_page, so by convention...
Although in this case at least for my next patch it won't acutally use
pud_page unless it's a leaf entry so maybe it shouldn't get called
anyway.
Thanks,
Nick
Powered by blists - more mailing lists