All of lore.kernel.org
 help / color / mirror / Atom feed
From: zhong jiang <zhongjiang@huawei.com>
To: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Cc: Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>,
	Robert Richter <rrichter@cavium.com>,
	Mark Rutland <mark.rutland@arm.com>,
	Arnd Bergmann <arnd@arndb.de>, Rob Herring <robh+dt@kernel.org>,
	<dwoods@ezchip.com>, Jeremy Linton <jeremy.linton@arm.com>,
	"linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [RESEND PATCH 1/2] arm64: change from CONT_PMD_SHIFT to CONT_PTE_SHIFT
Date: Thu, 15 Dec 2016 10:59:39 +0800	[thread overview]
Message-ID: <5852071B.60202@huawei.com> (raw)
In-Reply-To: <CAKv+Gu8Qh8N+fagYqtO_04fZ=Wxg5S-=4bmPD0bxQrSyb+NZvw@mail.gmail.com>

On 2016/12/14 22:45, Ard Biesheuvel wrote:
> On 14 December 2016 at 14:19, zhongjiang <zhongjiang@huawei.com> wrote:
>> From: zhong jiang <zhongjiang@huawei.com>
>>
>> I think that CONT_PTE_SHIFT is more reasonable even if they are some
>> value. and the patch is not any functional change.
>>
> This may be the case for 64k pages, but not for 16k pages, and I
> actually think add_default_hugepagesz() could be made unconditional,
> given that both 64k on 4k kernels and 2 MB on 16k kernels are useful
> hugepage sizes that are not otherwise available by default.
 I agree that we can make add_default_hugepagesz() to be unconditional.
 but I do not know the history why it did so at that time. The patch
 just is based on the current kernel.

 by the way, please review the second patch if you have time. Any comment
 will be welcomed.

 Thanks
 zhongjiang
>> Signed-off-by: zhong jiang <zhongjiang@huawei.com>
> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>
>> ---
>>  arch/arm64/mm/hugetlbpage.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/arch/arm64/mm/hugetlbpage.c b/arch/arm64/mm/hugetlbpage.c
>> index 2e49bd2..0a4c97b 100644
>> --- a/arch/arm64/mm/hugetlbpage.c
>> +++ b/arch/arm64/mm/hugetlbpage.c
>> @@ -323,7 +323,7 @@ static __init int setup_hugepagesz(char *opt)
>>  static __init int add_default_hugepagesz(void)
>>  {
>>         if (size_to_hstate(CONT_PTES * PAGE_SIZE) == NULL)
>> -               hugetlb_add_hstate(CONT_PMD_SHIFT);
>> +               hugetlb_add_hstate(CONT_PTE_SHIFT);
>>         return 0;
>>  }
>>  arch_initcall(add_default_hugepagesz);
>> --
>> 1.8.3.1
>>
> .
>

WARNING: multiple messages have this Message-ID (diff)
From: zhongjiang@huawei.com (zhong jiang)
To: linux-arm-kernel@lists.infradead.org
Subject: [RESEND PATCH 1/2] arm64: change from CONT_PMD_SHIFT to CONT_PTE_SHIFT
Date: Thu, 15 Dec 2016 10:59:39 +0800	[thread overview]
Message-ID: <5852071B.60202@huawei.com> (raw)
In-Reply-To: <CAKv+Gu8Qh8N+fagYqtO_04fZ=Wxg5S-=4bmPD0bxQrSyb+NZvw@mail.gmail.com>

On 2016/12/14 22:45, Ard Biesheuvel wrote:
> On 14 December 2016 at 14:19, zhongjiang <zhongjiang@huawei.com> wrote:
>> From: zhong jiang <zhongjiang@huawei.com>
>>
>> I think that CONT_PTE_SHIFT is more reasonable even if they are some
>> value. and the patch is not any functional change.
>>
> This may be the case for 64k pages, but not for 16k pages, and I
> actually think add_default_hugepagesz() could be made unconditional,
> given that both 64k on 4k kernels and 2 MB on 16k kernels are useful
> hugepage sizes that are not otherwise available by default.
 I agree that we can make add_default_hugepagesz() to be unconditional.
 but I do not know the history why it did so at that time. The patch
 just is based on the current kernel.

 by the way, please review the second patch if you have time. Any comment
 will be welcomed.

 Thanks
 zhongjiang
>> Signed-off-by: zhong jiang <zhongjiang@huawei.com>
> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>
>> ---
>>  arch/arm64/mm/hugetlbpage.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/arch/arm64/mm/hugetlbpage.c b/arch/arm64/mm/hugetlbpage.c
>> index 2e49bd2..0a4c97b 100644
>> --- a/arch/arm64/mm/hugetlbpage.c
>> +++ b/arch/arm64/mm/hugetlbpage.c
>> @@ -323,7 +323,7 @@ static __init int setup_hugepagesz(char *opt)
>>  static __init int add_default_hugepagesz(void)
>>  {
>>         if (size_to_hstate(CONT_PTES * PAGE_SIZE) == NULL)
>> -               hugetlb_add_hstate(CONT_PMD_SHIFT);
>> +               hugetlb_add_hstate(CONT_PTE_SHIFT);
>>         return 0;
>>  }
>>  arch_initcall(add_default_hugepagesz);
>> --
>> 1.8.3.1
>>
> .
>

  reply	other threads:[~2016-12-15  3:00 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-14 14:19 [RESEND PATCH 0/2] fix some trivial bug involving the contiguous bit zhongjiang
2016-12-14 14:19 ` zhongjiang
2016-12-14 14:19 ` [RESEND PATCH 1/2] arm64: change from CONT_PMD_SHIFT to CONT_PTE_SHIFT zhongjiang
2016-12-14 14:19   ` zhongjiang
2016-12-14 14:45   ` Ard Biesheuvel
2016-12-14 14:45     ` Ard Biesheuvel
2016-12-15  2:59     ` zhong jiang [this message]
2016-12-15  2:59       ` zhong jiang
2017-01-03 12:31   ` Catalin Marinas
2017-01-03 12:31     ` Catalin Marinas
2016-12-14 14:19 ` [RESEND PATCH 2/2] arm64: make WANT_HUGE_PMD_SHARE depends on HUGETLB_PAGE zhongjiang
2016-12-14 14:19   ` zhongjiang
2016-12-16  9:10   ` zhong jiang
2016-12-16  9:10     ` zhong jiang
2016-12-16 12:35     ` Will Deacon
2016-12-16 12:35       ` Will Deacon
2016-12-16 12:56       ` zhong jiang
2016-12-16 12:56         ` zhong jiang
2016-12-16 14:08       ` zhong jiang
2016-12-16 14:08         ` zhong jiang

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=5852071B.60202@huawei.com \
    --to=zhongjiang@huawei.com \
    --cc=ard.biesheuvel@linaro.org \
    --cc=arnd@arndb.de \
    --cc=catalin.marinas@arm.com \
    --cc=dwoods@ezchip.com \
    --cc=jeremy.linton@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=rrichter@cavium.com \
    --cc=will.deacon@arm.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.