All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christophe Leroy <christophe.leroy@csgroup.eu>
To: Kefeng Wang <wangkefeng.wang@huawei.com>,
	"linuxppc-dev@lists.ozlabs.org" <linuxppc-dev@lists.ozlabs.org>,
	"mpe@ellerman.id.au" <mpe@ellerman.id.au>,
	"benh@kernel.crashing.or" <benh@kernel.crashing.or>,
	"paulus@samba.org" <paulus@samba.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>
Cc: "akpm@linux-foundation.org" <akpm@linux-foundation.org>,
	"npiggin@gmail.com" <npiggin@gmail.com>,
	"songyuanzheng@huawei.com" <songyuanzheng@huawei.com>
Subject: Re: [PATCH v4 1/2] Revert "powerpc: Set max_mapnr correctly"
Date: Mon, 28 Mar 2022 14:12:06 +0000	[thread overview]
Message-ID: <de3e12e2-6dff-90cd-3f47-fe8deaae1fa8@csgroup.eu> (raw)
In-Reply-To: <b2ff771c-01ef-3f14-f22d-9248735fdc77@huawei.com>

Hi,

Le 26/03/2022 à 08:55, Kefeng Wang a écrit :
> Hi maintainers,
> 
> I saw the patches has been reviewed[1], could they be merged?

Thinking about it once more, I think the patches should go in reverse 
order. Patch 2 should go first and patch 1 should go after.

Otherwise, once patch 1 is applied and patch 2 is not applied yet, 
virt_addr_valid() doesn't work anymore.

Christophe

> 
> Many thanks.
> 
> [1] https://patchwork.ozlabs.org/project/linuxppc-dev/list/?series=286464
> 
> On 2022/2/16 20:11, Kefeng Wang wrote:
>> This reverts commit 602946ec2f90d5bd965857753880db29d2d9a1e9.
>>
>> If CONFIG_HIGHMEM enabled, highmem will be disappeared with max_mapnr
>> set to max_low_pfn, see mem_init(),
>>
>>    for (pfn = highmem_mapnr; pfn < max_mapnr; ++pfn) {
>>          ...
>>     free_highmem_page();
>>    }
>>
>> Revert it and will fix virt_addr_valid() check in the next patch.
>>
>> Cc: Christophe Leroy <christophe.leroy@csgroup.eu>
>> Fixes: 602946ec2f90 ("powerpc: Set max_mapnr correctly")
>> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
>> ---
>> v4:
>> - new patch
>>   arch/powerpc/mm/mem.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c
>> index 8e301cd8925b..4d221d033804 100644
>> --- a/arch/powerpc/mm/mem.c
>> +++ b/arch/powerpc/mm/mem.c
>> @@ -255,7 +255,7 @@ void __init mem_init(void)
>>   #endif
>>       high_memory = (void *) __va(max_low_pfn * PAGE_SIZE);
>> -    set_max_mapnr(max_low_pfn);
>> +    set_max_mapnr(max_pfn);
>>       kasan_late_init();

WARNING: multiple messages have this Message-ID (diff)
From: Christophe Leroy <christophe.leroy@csgroup.eu>
To: Kefeng Wang <wangkefeng.wang@huawei.com>,
	"linuxppc-dev@lists.ozlabs.org" <linuxppc-dev@lists.ozlabs.org>,
	"mpe@ellerman.id.au" <mpe@ellerman.id.au>,
	"benh@kernel.crashing.or" <benh@kernel.crashing.or>,
	"paulus@samba.org" <paulus@samba.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>
Cc: "akpm@linux-foundation.org" <akpm@linux-foundation.org>,
	"songyuanzheng@huawei.com" <songyuanzheng@huawei.com>,
	"npiggin@gmail.com" <npiggin@gmail.com>
Subject: Re: [PATCH v4 1/2] Revert "powerpc: Set max_mapnr correctly"
Date: Mon, 28 Mar 2022 14:12:06 +0000	[thread overview]
Message-ID: <de3e12e2-6dff-90cd-3f47-fe8deaae1fa8@csgroup.eu> (raw)
In-Reply-To: <b2ff771c-01ef-3f14-f22d-9248735fdc77@huawei.com>

Hi,

Le 26/03/2022 à 08:55, Kefeng Wang a écrit :
> Hi maintainers,
> 
> I saw the patches has been reviewed[1], could they be merged?

Thinking about it once more, I think the patches should go in reverse 
order. Patch 2 should go first and patch 1 should go after.

Otherwise, once patch 1 is applied and patch 2 is not applied yet, 
virt_addr_valid() doesn't work anymore.

Christophe

> 
> Many thanks.
> 
> [1] https://patchwork.ozlabs.org/project/linuxppc-dev/list/?series=286464
> 
> On 2022/2/16 20:11, Kefeng Wang wrote:
>> This reverts commit 602946ec2f90d5bd965857753880db29d2d9a1e9.
>>
>> If CONFIG_HIGHMEM enabled, highmem will be disappeared with max_mapnr
>> set to max_low_pfn, see mem_init(),
>>
>>    for (pfn = highmem_mapnr; pfn < max_mapnr; ++pfn) {
>>          ...
>>     free_highmem_page();
>>    }
>>
>> Revert it and will fix virt_addr_valid() check in the next patch.
>>
>> Cc: Christophe Leroy <christophe.leroy@csgroup.eu>
>> Fixes: 602946ec2f90 ("powerpc: Set max_mapnr correctly")
>> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
>> ---
>> v4:
>> - new patch
>>   arch/powerpc/mm/mem.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c
>> index 8e301cd8925b..4d221d033804 100644
>> --- a/arch/powerpc/mm/mem.c
>> +++ b/arch/powerpc/mm/mem.c
>> @@ -255,7 +255,7 @@ void __init mem_init(void)
>>   #endif
>>       high_memory = (void *) __va(max_low_pfn * PAGE_SIZE);
>> -    set_max_mapnr(max_low_pfn);
>> +    set_max_mapnr(max_pfn);
>>       kasan_late_init();

  parent reply	other threads:[~2022-03-28 14:12 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-16 12:11 [PATCH v4 1/2] Revert "powerpc: Set max_mapnr correctly" Kefeng Wang
2022-02-16 12:11 ` Kefeng Wang
2022-02-16 12:11 ` [PATCH v4 2/2] powerpc: Fix virt_addr_valid() check Kefeng Wang
2022-02-16 12:11   ` Kefeng Wang
2022-03-09 16:01   ` [v4,2/2] " Christophe Leroy
2022-03-09 16:00 ` [v4,1/2] Revert "powerpc: Set max_mapnr correctly" Christophe Leroy
2022-03-26  7:55 ` [PATCH v4 1/2] " Kefeng Wang
2022-03-26  7:55   ` Kefeng Wang
2022-03-28 10:37   ` Michael Ellerman
2022-03-28 10:37     ` Michael Ellerman
2022-03-28 10:59     ` Christophe Leroy
2022-03-28 10:59       ` Christophe Leroy
2022-04-01 11:23       ` Michael Ellerman
2022-04-01 11:23         ` Michael Ellerman
2022-04-01 12:07         ` Christophe Leroy
2022-04-01 12:07           ` Christophe Leroy
2022-03-28 14:12   ` Christophe Leroy [this message]
2022-03-28 14:12     ` Christophe Leroy
2022-03-29 11:32     ` Kefeng Wang
2022-03-29 11:32       ` Kefeng Wang
2022-04-04 12:31       ` Michael Ellerman
2022-04-04 12:31         ` Michael Ellerman
2022-04-06  2:21         ` Kefeng Wang
2022-04-06  2:21           ` Kefeng Wang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=de3e12e2-6dff-90cd-3f47-fe8deaae1fa8@csgroup.eu \
    --to=christophe.leroy@csgroup.eu \
    --cc=akpm@linux-foundation.org \
    --cc=benh@kernel.crashing.or \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    --cc=npiggin@gmail.com \
    --cc=paulus@samba.org \
    --cc=songyuanzheng@huawei.com \
    --cc=wangkefeng.wang@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.