[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e3e33130-35ab-499b-b86f-f0c2b3121cf2@redhat.com>
Date: Mon, 28 Apr 2025 09:06:58 +0200
From: David Hildenbrand <david@...hat.com>
To: David Woodhouse <dwmw2@...radead.org>, Mike Rapoport <rppt@...nel.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
"Sauerwein, David" <dssauerw@...zon.de>,
Anshuman Khandual <anshuman.khandual@....com>,
Ard Biesheuvel <ardb@...nel.org>, Catalin Marinas <catalin.marinas@....com>,
Marc Zyngier <maz@...nel.org>, Mark Rutland <mark.rutland@....com>,
Mike Rapoport <rppt@...ux.ibm.com>, Will Deacon <will@...nel.org>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
linux-mm@...ck.org, Ruihan Li <lrh2000@....edu.cn>
Subject: Re: [PATCH v4 1/7] mm: Introduce for_each_valid_pfn() and use it from
reserve_bootmem_region()
On 26.04.25 00:01, David Woodhouse wrote:
> On Thu, 2025-04-24 at 23:11 +0200, David Hildenbrand wrote:
>>
>>> + unsigned long pfn;
>>>
>>> - for (; start_pfn < end_pfn; start_pfn++) {
>>> - if (pfn_valid(start_pfn)) {
>>> - struct page *page = pfn_to_page(start_pfn);
>>> + for_each_valid_pfn (pfn, PFN_DOWN(start), PFN_UP(end)) {
>>
>> ^ space should be removed
>
>
> I was treating for_each_foobar() like for(), which always *does* have
> the space before the parentheses. But a quick grep shows that that's
> the minority, by at least two orders of magnitude. Fixing it locally;
> thanks.
Yeah, it's frowned upon. Note that checkpatch will properly complain:
WARNING: space prohibited between function name and open parenthesis '('
#70: FILE: mm/mm_init.c:782:
+ for_each_valid_pfn (pfn, PFN_DOWN(start), PFN_UP(end)) {
--
Cheers,
David / dhildenb
Powered by blists - more mailing lists