Re: [PATCH v4 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-01 Thread Alexandre Ghiti
On 03/01/2019 07:25 AM, Alex Ghiti wrote: On 2/28/19 5:26 PM, Mike Kravetz wrote: On 2/28/19 12:23 PM, Dave Hansen wrote: On 2/28/19 11:50 AM, Mike Kravetz wrote: On 2/28/19 11:13 AM, Dave Hansen wrote: +    if (hstate_is_gigantic(h) && !IS_ENABLED(CONFIG_CONTIG_ALLOC)) { +    spin_lock(

Re: [PATCH v4 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-01 Thread Alexandre Ghiti
On 03/01/2019 02:33 PM, Vlastimil Babka wrote: On 3/1/19 2:21 PM, Alexandre Ghiti wrote: I collected mistakes here: domain name expired and no mailing list added :) Really sorry about that, I missed the whole discussion (if any). Could someone forward it to me (if any) ? Thanks ! Bounced you

[PATCH v5 0/4] Fix free/allocation of runtime gigantic pages

2019-03-06 Thread Alexandre Ghiti
suggested by Vlastimil Babka: - Get rid of ARCH_HAS_GIGANTIC_PAGE - Get rid of architecture specific gigantic_page_supported - Factorize CMA or (MEMORY_ISOLATION && COMPACTION) into COMPACTION_CORE *** BLURB HERE *** Alexandre Ghiti (4): sh: Advertise gigantic page support sparc: Ad

[PATCH v5 1/4] sh: Advertise gigantic page support

2019-03-06 Thread Alexandre Ghiti
DER (11) Signed-off-by: Alexandre Ghiti --- arch/sh/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index a9c36f95744a..299a17bed67c 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig @@ -53,6 +53,7 @@ config SUPERH select HAVE_FUTEX_CMPXCHG

[PATCH v5 2/4] sparc: Advertise gigantic page support

2019-03-06 Thread Alexandre Ghiti
ned-off-by: Alexandre Ghiti --- arch/sparc/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig index d5dd652fb8cc..0b7f0e0fefa5 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig @@ -90,6 +90,7 @@ config SPARC64 sel

[PATCH v5 3/4] mm: Simplify MEMORY_ISOLATION && COMPACTION || CMA into CONTIG_ALLOC

2019-03-06 Thread Alexandre Ghiti
This condition allows to define alloc_contig_range, so simplify it into a more accurate naming. Suggested-by: Vlastimil Babka Signed-off-by: Alexandre Ghiti --- arch/arm64/Kconfig | 2 +- arch/powerpc/platforms/Kconfig.cputype | 2 +- arch/s390/Kconfig

[PATCH v5 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-06 Thread Alexandre Ghiti
On systems without CONTIG_ALLOC activated but that support gigantic pages, boottime reserved gigantic pages can not be freed at all. This patch simply enables the possibility to hand back those pages to memory allocator. Signed-off-by: Alexandre Ghiti --- arch/arm64/Kconfig

[PATCH v6 0/4] Fix free/allocation of runtime gigantic pages

2019-03-07 Thread Alexandre Ghiti
ctorize CMA or (MEMORY_ISOLATION && COMPACTION) into COMPACTION_CORE Alexandre Ghiti (4): sh: Advertise gigantic page support sparc: Advertise gigantic page support mm: Simplify MEMORY_ISOLATION && COMPACTION || CMA into CONTIG_ALLOC hugetlb: allow to free gigan

[PATCH v6 1/4] sh: Advertise gigantic page support

2019-03-07 Thread Alexandre Ghiti
DER (11) Signed-off-by: Alexandre Ghiti --- arch/sh/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index a9c36f95744a..299a17bed67c 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig @@ -53,6 +53,7 @@ config SUPERH select HAVE_FUTEX_CMPXCHG

[PATCH v6 2/4] sparc: Advertise gigantic page support

2019-03-07 Thread Alexandre Ghiti
ned-off-by: Alexandre Ghiti Acked-by: David S. Miller --- arch/sparc/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig index d5dd652fb8cc..0b7f0e0fefa5 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig @@ -90,6 +90,7 @@ config SPAR

[PATCH v6 3/4] mm: Simplify MEMORY_ISOLATION && COMPACTION || CMA into CONTIG_ALLOC

2019-03-07 Thread Alexandre Ghiti
This condition allows to define alloc_contig_range, so simplify it into a more accurate naming. Suggested-by: Vlastimil Babka Signed-off-by: Alexandre Ghiti Acked-by: Vlastimil Babka --- arch/arm64/Kconfig | 2 +- arch/powerpc/platforms/Kconfig.cputype | 2 +- arch/s390

[PATCH v6 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-07 Thread Alexandre Ghiti
On systems without CONTIG_ALLOC activated but that support gigantic pages, boottime reserved gigantic pages can not be freed at all. This patch simply enables the possibility to hand back those pages to memory allocator. Signed-off-by: Alexandre Ghiti Acked-by: David S. Miller [sparc] --- arch

Re: [PATCH v6 0/4] Fix free/allocation of runtime gigantic pages

2019-03-13 Thread Alexandre Ghiti
On 03/13/2019 05:41 PM, Dave Hansen wrote: On 3/7/19 5:20 AM, Alexandre Ghiti wrote: This series fixes sh and sparc that did not advertise their gigantic page support and then were not able to allocate and free those pages at runtime. It renames MEMORY_ISOLATION && COMPACTION || CMA c

Re: [PATCH v6 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-14 Thread Alexandre Ghiti
On 03/14/2019 06:52 AM, Aneesh Kumar K.V wrote: Alexandre Ghiti writes: On systems without CONTIG_ALLOC activated but that support gigantic pages, boottime reserved gigantic pages can not be freed at all. This patch simply enables the possibility to hand back those pages to memory allocator

Re: [PATCH v6 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-14 Thread Alexandre Ghiti
On 03/14/2019 02:17 PM, Aneesh Kumar K.V wrote: On 3/14/19 5:13 PM, Alexandre Ghiti wrote: On 03/14/2019 06:52 AM, Aneesh Kumar K.V wrote: Alexandre Ghiti writes: On systems without CONTIG_ALLOC activated but that support gigantic pages, boottime reserved gigantic pages can not be freed

[PATCH v7 0/4] Fix free/allocation of runtime gigantic pages

2019-03-17 Thread Alexandre Ghiti
architecture specific gigantic_page_supported - Factorize CMA or (MEMORY_ISOLATION && COMPACTION) into COMPACTION_CORE Alexandre Ghiti (4): sh: Advertise gigantic page support sparc: Advertise gigantic page support mm: Simplify MEMORY_ISOLATION && COMPACTION || CMA into CONT

[PATCH v7 1/4] sh: Advertise gigantic page support

2019-03-17 Thread Alexandre Ghiti
DER (11) Signed-off-by: Alexandre Ghiti --- arch/sh/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index a9c36f95744a..299a17bed67c 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig @@ -53,6 +53,7 @@ config SUPERH select HAVE_FUTEX_CMPXCHG

[PATCH v7 2/4] sparc: Advertise gigantic page support

2019-03-17 Thread Alexandre Ghiti
ned-off-by: Alexandre Ghiti Acked-by: David S. Miller --- arch/sparc/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig index d5dd652fb8cc..0b7f0e0fefa5 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig @@ -90,6 +90,7 @@ config SPAR

[PATCH v7 3/4] mm: Simplify MEMORY_ISOLATION && COMPACTION || CMA into CONTIG_ALLOC

2019-03-17 Thread Alexandre Ghiti
This condition allows to define alloc_contig_range, so simplify it into a more accurate naming. Suggested-by: Vlastimil Babka Signed-off-by: Alexandre Ghiti Acked-by: Vlastimil Babka --- arch/arm64/Kconfig | 2 +- arch/powerpc/platforms/Kconfig.cputype | 2 +- arch/s390

[PATCH v7 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-17 Thread Alexandre Ghiti
On systems without CONTIG_ALLOC activated but that support gigantic pages, boottime reserved gigantic pages can not be freed at all. This patch simply enables the possibility to hand back those pages to memory allocator. Signed-off-by: Alexandre Ghiti Acked-by: David S. Miller [sparc] --- arch

[PATCH v8 1/4] sh: Advertise gigantic page support

2019-03-26 Thread Alexandre Ghiti
DER (11) Signed-off-by: Alexandre Ghiti --- arch/sh/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index b1c91ea9a958..0d9fb2468e0b 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig @@ -53,6 +53,7 @@ config SUPERH select HAVE_FUTEX_CMPXCHG

[PATCH v8 2/4] sparc: Advertise gigantic page support

2019-03-26 Thread Alexandre Ghiti
ned-off-by: Alexandre Ghiti Acked-by: David S. Miller --- arch/sparc/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig index 40f8f4f73fe8..ebcc9435db08 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig @@ -91,6 +91,7 @@ config SPAR

[PATCH v8 3/4] mm: Simplify MEMORY_ISOLATION && COMPACTION || CMA into CONTIG_ALLOC

2019-03-26 Thread Alexandre Ghiti
This condition allows to define alloc_contig_range, so simplify it into a more accurate naming. Suggested-by: Vlastimil Babka Signed-off-by: Alexandre Ghiti Acked-by: Vlastimil Babka --- arch/arm64/Kconfig | 2 +- arch/powerpc/platforms/Kconfig.cputype | 2 +- arch/s390

[PATCH v8 0/4] Fix free/allocation of runtime gigantic pages

2019-03-26 Thread Alexandre Ghiti
Get rid of architecture specific gigantic_page_supported - Factorize CMA or (MEMORY_ISOLATION && COMPACTION) into COMPACTION_CORE Alexandre Ghiti (4): sh: Advertise gigantic page support sparc: Advertise gigantic page support mm: Simplify MEMORY_ISOLATION && COMPACTION || CMA int

[PATCH v8 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-26 Thread Alexandre Ghiti
On systems without CONTIG_ALLOC activated but that support gigantic pages, boottime reserved gigantic pages can not be freed at all. This patch simply enables the possibility to hand back those pages to memory allocator. Signed-off-by: Alexandre Ghiti Acked-by: David S. Miller [sparc] --- arch

Re: [PATCH v8 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-27 Thread Alexandre Ghiti
On 03/27/2019 08:01 AM, Aneesh Kumar K.V wrote: On 3/27/19 12:06 PM, Alexandre Ghiti wrote: On systems without CONTIG_ALLOC activated but that support gigantic pages, boottime reserved gigantic pages can not be freed at all. This patch simply enables the possibility to hand back those pages

Re: [PATCH v8 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-27 Thread Alexandre Ghiti
On 03/27/2019 09:55 AM, Aneesh Kumar K.V wrote: On 3/27/19 2:14 PM, Alexandre Ghiti wrote: On 03/27/2019 08:01 AM, Aneesh Kumar K.V wrote: On 3/27/19 12:06 PM, Alexandre Ghiti wrote: On systems without CONTIG_ALLOC activated but that support gigantic pages, boottime reserved gigantic pages

Re: [PATCH v8 4/4] hugetlb: allow to free gigantic pages regardless of the configuration

2019-03-27 Thread Alexandre Ghiti
On 03/27/2019 11:05 AM, Aneesh Kumar K.V wrote: Alexandre Ghiti writes: On 03/27/2019 09:55 AM, Aneesh Kumar K.V wrote: On 3/27/19 2:14 PM, Alexandre Ghiti wrote: On 03/27/2019 08:01 AM, Aneesh Kumar K.V wrote: On 3/27/19 12:06 PM, Alexandre Ghiti wrote: . This is now #define

Re: [PATCH v6 00/11] hugetlb: Factorize hugetlb architecture primitives

2018-08-19 Thread Alexandre Ghiti
Hi Michal, This patchset got acked, tested and reviewed by quite a few people, and it has been suggested that it should be included in -mm tree: could you tell me if something else needs to be done for its inclusion ? Thanks for your time, Alex On 08/06/2018 07:57 PM, Alexandre Ghiti

Re: [PATCH v6 00/11] hugetlb: Factorize hugetlb architecture primitives

2018-08-20 Thread Alexandre Ghiti
Ok, my bad, sorry about that, I have just added Andrew as CC then. Thank you, Alex On 08/20/2018 09:17 AM, Michal Hocko wrote: On Mon 20-08-18 08:45:10, Alexandre Ghiti wrote: Hi Michal, This patchset got acked, tested and reviewed by quite a few people, and it has been suggested that it

[PATCH v7 00/11] hugetlb: Factorize hugetlb architecture primitives

2018-09-19 Thread Alexandre Ghiti
. v1, v2, v3: Same version, just problems with email provider and misuse of --batch-size option of git send-email Alexandre Ghiti (11): hugetlb: Harmonize hugetlb.h arch specific defines

[PATCH v7 01/11] hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h

2018-09-19 Thread Alexandre Ghiti
asm-generic/hugetlb.h proposes generic implementations of hugetlb related functions: use __HAVE_ARCH_HUGE* defines in order to make arch specific implementations of hugetlb functions consistent with pgtable.h scheme. Signed-off-by: Alexandre Ghiti Acked-by: Catalin Marinas # arm64 Reviewed-by

[PATCH v7 02/11] hugetlb: Introduce generic version of hugetlb_free_pgd_range

2018-09-19 Thread Alexandre Ghiti
arm, arm64, mips, parisc, sh, x86 architectures use the same version of hugetlb_free_pgd_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton # MIPS parts

[PATCH v7 03/11] hugetlb: Introduce generic version of set_huge_pte_at

2018-09-19 Thread Alexandre Ghiti
arm, ia64, mips, powerpc, sh, x86 architectures use the same version of set_huge_pte_at, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton # MIPS parts Acked

[PATCH v7 04/11] hugetlb: Introduce generic version of huge_ptep_get_and_clear

2018-09-19 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_get_and_clear, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton # MIPS parts Acked-by: Ingo

[PATCH v7 05/11] hugetlb: Introduce generic version of huge_ptep_clear_flush

2018-09-19 Thread Alexandre Ghiti
arm, x86 architectures use the same version of huge_ptep_clear_flush, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton # MIPS parts Acked-by: Ingo Molnar

[PATCH v7 06/11] hugetlb: Introduce generic version of huge_pte_none

2018-09-19 Thread Alexandre Ghiti
arm, arm64, ia64, mips, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_pte_none, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton

[PATCH v7 07/11] hugetlb: Introduce generic version of huge_pte_wrprotect

2018-09-19 Thread Alexandre Ghiti
arm, arm64, ia64, mips, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_pte_wrprotect, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul

[PATCH v7 08/11] hugetlb: Introduce generic version of prepare_hugepage_range

2018-09-19 Thread Alexandre Ghiti
arm, arm64, powerpc, sparc, x86 architectures use the same version of prepare_hugepage_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton # MIPS parts

[PATCH v7 09/11] hugetlb: Introduce generic version of huge_ptep_set_wrprotect

2018-09-19 Thread Alexandre Ghiti
arm, ia64, mips, powerpc, sh, x86 architectures use the same version of huge_ptep_set_wrprotect, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton # MIPS parts

[PATCH v7 11/11] hugetlb: Introduce generic version of huge_ptep_get

2018-09-19 Thread Alexandre Ghiti
ia64, mips, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_ptep_get, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton # MIPS parts

[PATCH v7 10/11] hugetlb: Introduce generic version of huge_ptep_set_access_flags

2018-09-19 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_set_access_flags, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Tested-by: Helge Deller # parisc Acked-by: Catalin Marinas # arm64 Acked-by: Paul Burton # MIPS parts Acked-by

[PATCH] hugetlb: allow to free gigantic pages regardless of the configuration

2019-01-17 Thread Alexandre Ghiti
From: Alexandre Ghiti On systems without CMA or (MEMORY_ISOLATION && COMPACTION) activated but that support gigantic pages, boottime reserved gigantic pages can not be freed at all. This patchs simply enables the possibility to hand back those pages to memory allocator. This commit then

[PATCH v2] hugetlb: allow to free gigantic pages regardless of the configuration

2019-02-13 Thread Alexandre Ghiti
gantic pages, it just means that runtime allocation of gigantic pages is not supported, one can still allocate boottime gigantic pages if the architecture supports it. Signed-off-by: Alexandre Ghiti --- Changes in v2 as suggested by Vlastimil Babka: - Get rid of ARCH_HAS_GIGANTIC_PAGE - Get rid

Re: [PATCH v2] hugetlb: allow to free gigantic pages regardless of the configuration

2019-02-14 Thread Alexandre Ghiti
On 02/13/2019 08:30 PM, Dave Hansen wrote: -#if (defined(CONFIG_MEMORY_ISOLATION) && defined(CONFIG_COMPACTION)) || defined(CONFIG_CMA) +#ifdef CONFIG_COMPACTION_CORE static __init int gigantic_pages_init(void) { /* With compaction or CMA we can allocate gigantic pages at runtime *

Re: [PATCH v2] hugetlb: allow to free gigantic pages regardless of the configuration

2019-02-14 Thread Alexandre Ghiti
On 02/14/2019 10:52 AM, Vlastimil Babka wrote: On 2/13/19 8:30 PM, Dave Hansen wrote: -#if (defined(CONFIG_MEMORY_ISOLATION) && defined(CONFIG_COMPACTION)) || defined(CONFIG_CMA) +#ifdef CONFIG_COMPACTION_CORE static __init int gigantic_pages_init(void) { /* With compaction or CMA w

[PATCH v3] hugetlb: allow to free gigantic pages regardless of the configuration

2019-02-14 Thread Alexandre Ghiti
c pages, it just means that runtime allocation of gigantic pages is not supported, one can still allocate boottime gigantic pages if the architecture supports it. Signed-off-by: Alexandre Ghiti --- Changes in v3 as suggested by Vlastimil Babka and Dave Hansen: - config definition was wrong

[PATCH 01/11] hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h

2018-07-04 Thread Alexandre Ghiti
asm-generic/hugetlb.h proposes generic implementations of hugetlb related functions: use __HAVE_ARCH_HUGE* defines in order to make arch specific implementations of hugetlb functions consistent with pgtable.h scheme. Signed-off-by: Alexandre Ghiti --- arch/arm64/include/asm/hugetlb.h | 2

[PATCH 04/11] hugetlb: Introduce generic version of huge_ptep_get_and_clear

2018-07-04 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_get_and_clear, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include

[PATCH 02/11] hugetlb: Introduce generic version of hugetlb_free_pgd_range

2018-07-04 Thread Alexandre Ghiti
arm, arm64, mips, parisc, sh, x86 architectures use the same version of hugetlb_free_pgd_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 12 ++-- arch/arm64/include/asm/hugetlb.h | 10

[PATCH 05/11] hugetlb: Introduce generic version of huge_ptep_clear_flush

2018-07-04 Thread Alexandre Ghiti
arm, x86 architectures use the same version of huge_ptep_clear_flush, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include/asm/hugetlb.h

[PATCH 00/11] hugetlb: Factorize architecture hugetlb primitives

2018-07-04 Thread Alexandre Ghiti
could be factorized a bit more (cf huge_ptep_set_wrprotect). This patchset has been compiled on x86 only. Alexandre Ghiti (11): hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h hugetlb: Introduce generic version of hugetlb_free_pgd_range hugetlb: Introduce generic version of

[PATCH 03/11] hugetlb: Introduce generic version of set_huge_pte_at

2018-07-04 Thread Alexandre Ghiti
arm, ia64, mips, powerpc, sh, x86 architectures use the same version of set_huge_pte_at, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

Re: [PATCH 05/11] hugetlb: Introduce generic version of huge_ptep_clear_flush

2018-07-04 Thread Alexandre Ghiti
Just discovered my email provider limit of mails per minute, please drop this serie, I'll send a v2 using --batch-size option of git send-email. Sorry about that. On 07/04/2018 07:52 AM, Alexandre Ghiti wrote: arm, x86 architectures use the same version of huge_ptep_clear_flush, so move

[PATCH 00/11] hugetlb: Factorize architecture hugetlb primitives

2018-07-04 Thread Alexandre Ghiti
at all. powerpc could be factorized a bit more (cf huge_ptep_set_wrprotect). This patchset has been compiled on x86 only. Alexandre Ghiti (11): hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h hugetlb: Introduce generic version of hugetlb_free_pgd_range hugetlb: Introduce

[PATCH 01/11] hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h

2018-07-04 Thread Alexandre Ghiti
asm-generic/hugetlb.h proposes generic implementations of hugetlb related functions: use __HAVE_ARCH_HUGE* defines in order to make arch specific implementations of hugetlb functions consistent with pgtable.h scheme. Signed-off-by: Alexandre Ghiti --- arch/arm64/include/asm/hugetlb.h | 2

[PATCH 02/11] hugetlb: Introduce generic version of hugetlb_free_pgd_range

2018-07-04 Thread Alexandre Ghiti
arm, arm64, mips, parisc, sh, x86 architectures use the same version of hugetlb_free_pgd_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 12 ++-- arch/arm64/include/asm/hugetlb.h | 10

[PATCH 03/11] hugetlb: Introduce generic version of set_huge_pte_at

2018-07-04 Thread Alexandre Ghiti
arm, ia64, mips, powerpc, sh, x86 architectures use the same version of set_huge_pte_at, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

[PATCH 04/11] hugetlb: Introduce generic version of huge_ptep_get_and_clear

2018-07-04 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_get_and_clear, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include

[PATCH 05/11] hugetlb: Introduce generic version of huge_ptep_clear_flush

2018-07-04 Thread Alexandre Ghiti
arm, x86 architectures use the same version of huge_ptep_clear_flush, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include/asm/hugetlb.h

[PATCH v2 00/11] hugetlb: Factorize architecture hugetlb primitives

2018-07-04 Thread Alexandre Ghiti
at all. powerpc could be factorized a bit more (cf huge_ptep_set_wrprotect). This patchset has been compiled on x86 only. Alexandre Ghiti (11): hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h hugetlb: Introduce generic version of hugetlb_free_pgd_range hugetlb: Introduce

[PATCH v2 01/11] hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h

2018-07-04 Thread Alexandre Ghiti
asm-generic/hugetlb.h proposes generic implementations of hugetlb related functions: use __HAVE_ARCH_HUGE* defines in order to make arch specific implementations of hugetlb functions consistent with pgtable.h scheme. Signed-off-by: Alexandre Ghiti --- arch/arm64/include/asm/hugetlb.h | 2

[PATCH v2 02/11] hugetlb: Introduce generic version of hugetlb_free_pgd_range

2018-07-04 Thread Alexandre Ghiti
arm, arm64, mips, parisc, sh, x86 architectures use the same version of hugetlb_free_pgd_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 12 ++-- arch/arm64/include/asm/hugetlb.h | 10

[PATCH v2 03/11] hugetlb: Introduce generic version of set_huge_pte_at

2018-07-04 Thread Alexandre Ghiti
arm, ia64, mips, powerpc, sh, x86 architectures use the same version of set_huge_pte_at, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

[PATCH v2 04/11] hugetlb: Introduce generic version of huge_ptep_get_and_clear

2018-07-04 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_get_and_clear, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include

[PATCH v2 05/11] hugetlb: Introduce generic version of huge_ptep_clear_flush

2018-07-04 Thread Alexandre Ghiti
arm, x86 architectures use the same version of huge_ptep_clear_flush, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include/asm/hugetlb.h

[PATCH v2 06/11] hugetlb: Introduce generic version of huge_pte_none

2018-07-04 Thread Alexandre Ghiti
arm, arm64, ia64, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_pte_none, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 5 - arch/arm64/include/asm/hugetlb.h | 5

[PATCH v3 00/11] hugetlb: Factorize hugetlb architecture primitives

2018-07-04 Thread Alexandre Ghiti
at all. powerpc could be factorized a bit more (cf huge_ptep_set_wrprotect). This patchset has been compiled on x86 only. Alexandre Ghiti (11): hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h hugetlb: Introduce generic version of hugetlb_free_pgd_range hugetlb: Introduce

[PATCH v3 01/11] hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h

2018-07-04 Thread Alexandre Ghiti
asm-generic/hugetlb.h proposes generic implementations of hugetlb related functions: use __HAVE_ARCH_HUGE* defines in order to make arch specific implementations of hugetlb functions consistent with pgtable.h scheme. Signed-off-by: Alexandre Ghiti --- arch/arm64/include/asm/hugetlb.h | 2

[PATCH v3 02/11] hugetlb: Introduce generic version of hugetlb_free_pgd_range

2018-07-04 Thread Alexandre Ghiti
arm, arm64, mips, parisc, sh, x86 architectures use the same version of hugetlb_free_pgd_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 12 ++-- arch/arm64/include/asm/hugetlb.h | 10

[PATCH v3 03/11] hugetlb: Introduce generic version of set_huge_pte_at

2018-07-04 Thread Alexandre Ghiti
arm, ia64, mips, powerpc, sh, x86 architectures use the same version of set_huge_pte_at, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

[PATCH v3 04/11] hugetlb: Introduce generic version of huge_ptep_get_and_clear

2018-07-04 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_get_and_clear, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include

[PATCH v3 05/11] hugetlb: Introduce generic version of huge_ptep_clear_flush

2018-07-04 Thread Alexandre Ghiti
arm, x86 architectures use the same version of huge_ptep_clear_flush, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include/asm/hugetlb.h

[PATCH v3 06/11] hugetlb: Introduce generic version of huge_pte_none

2018-07-04 Thread Alexandre Ghiti
arm, arm64, ia64, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_pte_none, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 5 - arch/arm64/include/asm/hugetlb.h | 5

[PATCH v3 07/11] hugetlb: Introduce generic version of huge_pte_wrprotect

2018-07-04 Thread Alexandre Ghiti
arm, arm64, ia64, mips, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_pte_wrprotect, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 5 - arch/arm64/include/asm/hugetlb.h

[PATCH v3 08/11] hugetlb: Introduce generic version of prepare_hugepage_range

2018-07-04 Thread Alexandre Ghiti
arm, arm64, powerpc, sparc, x86 architectures use the same version of prepare_hugepage_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 11 --- arch/arm64/include/asm/hugetlb.h | 11

[PATCH v3 09/11] hugetlb: Introduce generic version of huge_ptep_set_wrprotect

2018-07-04 Thread Alexandre Ghiti
hence has not been done. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h| 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include/asm/hugetlb.h | 6 -- arch/mips/include/asm/hugetlb.h | 6 -- arch/parisc

[PATCH v3 10/11] hugetlb: Introduce generic version of huge_ptep_set_access_flags

2018-07-04 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_set_access_flags, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 7 --- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

[PATCH v3 11/11] hugetlb: Introduce generic version of huge_ptep_get

2018-07-04 Thread Alexandre Ghiti
ia64, mips, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_ptep_get, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 1 + arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

[PATCH v4 00/11] hugetlb: Factorize hugetlb architecture primitives

2018-07-05 Thread Alexandre Ghiti
version, just problems with email provider and misuse of --batch-size option of git send-email Alexandre Ghiti (11): hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h hugetlb: Introduce generic version of hugetlb_free_pgd_range hugetlb: Introduce generic version of set_huge_pte_at

[PATCH v4 01/11] hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h

2018-07-05 Thread Alexandre Ghiti
asm-generic/hugetlb.h proposes generic implementations of hugetlb related functions: use __HAVE_ARCH_HUGE* defines in order to make arch specific implementations of hugetlb functions consistent with pgtable.h scheme. Signed-off-by: Alexandre Ghiti --- arch/arm64/include/asm/hugetlb.h | 2

[PATCH v4 02/11] hugetlb: Introduce generic version of hugetlb_free_pgd_range

2018-07-05 Thread Alexandre Ghiti
arm, arm64, mips, parisc, sh, x86 architectures use the same version of hugetlb_free_pgd_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 12 ++-- arch/arm64/include/asm/hugetlb.h | 10

[PATCH v4 04/11] hugetlb: Introduce generic version of huge_ptep_get_and_clear

2018-07-05 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_get_and_clear, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include

[PATCH v4 05/11] hugetlb: Introduce generic version of huge_ptep_clear_flush

2018-07-05 Thread Alexandre Ghiti
arm, x86 architectures use the same version of huge_ptep_clear_flush, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include/asm/hugetlb.h

[PATCH v4 03/11] hugetlb: Introduce generic version of set_huge_pte_at

2018-07-05 Thread Alexandre Ghiti
arm, ia64, mips, powerpc, sh, x86 architectures use the same version of set_huge_pte_at, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

[PATCH v4 06/11] hugetlb: Introduce generic version of huge_pte_none

2018-07-05 Thread Alexandre Ghiti
arm, arm64, ia64, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_pte_none, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 5 - arch/arm64/include/asm/hugetlb.h | 5

[PATCH v4 07/11] hugetlb: Introduce generic version of huge_pte_wrprotect

2018-07-05 Thread Alexandre Ghiti
arm, arm64, ia64, mips, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_pte_wrprotect, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 5 - arch/arm64/include/asm/hugetlb.h

[PATCH v4 08/11] hugetlb: Introduce generic version of prepare_hugepage_range

2018-07-05 Thread Alexandre Ghiti
arm, arm64, powerpc, sparc, x86 architectures use the same version of prepare_hugepage_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb.h | 11 --- arch/arm64/include/asm/hugetlb.h | 11

[PATCH v4 09/11] hugetlb: Introduce generic version of huge_ptep_set_wrprotect

2018-07-05 Thread Alexandre Ghiti
hence has not been done. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h| 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64/include/asm/hugetlb.h | 6 -- arch/mips/include/asm/hugetlb.h | 6 -- arch/parisc

[PATCH v4 10/11] hugetlb: Introduce generic version of huge_ptep_set_access_flags

2018-07-05 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_set_access_flags, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 7 --- arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

[PATCH v4 11/11] hugetlb: Introduce generic version of huge_ptep_get

2018-07-05 Thread Alexandre Ghiti
ia64, mips, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_ptep_get, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti --- arch/arm/include/asm/hugetlb-3level.h | 1 + arch/arm64/include/asm/hugetlb.h | 1 + arch/ia64

Re: [PATCH v4 00/11] hugetlb: Factorize hugetlb architecture primitives

2018-07-25 Thread Alexandre Ghiti
Hi Paul, Thanks for having tested it, I remove mips from my list. Thanks again, Alex On 07/25/2018 02:34 AM, Paul Burton wrote: Hi Alexandre, On Thu, Jul 05, 2018 at 11:07:05AM +, Alexandre Ghiti wrote: In order to reduce copy/paste of functions across architectures and then make

Re: [PATCH v4 00/11] hugetlb: Factorize hugetlb architecture primitives

2018-07-26 Thread Alexandre Ghiti
Hi Mike, Thanks for your review. I'm going to fix the 2nd patch as you said, you're right, no need to move the #include at the bottom of the file. I'm going to post a v5, add -mm in cc and ask for inclusion in their tree. Thanks again for your time, Alex On 07/26/2018 09:16 PM, Mike Kravetz

[PATCH v5 00/11] hugetlb: Factorize hugetlb architecture primitives

2018-07-30 Thread Alexandre Ghiti
pointed by Christophe Leroy. v1, v2, v3: Same version, just problems with email provider and misuse of --batch-size option of git send-email Alexandre Ghiti (11): hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h hugetlb: Introduce generic version of hugetlb_free_pgd_range

[PATCH v5 01/11] hugetlb: Harmonize hugetlb.h arch specific defines with pgtable.h

2018-07-30 Thread Alexandre Ghiti
asm-generic/hugetlb.h proposes generic implementations of hugetlb related functions: use __HAVE_ARCH_HUGE* defines in order to make arch specific implementations of hugetlb functions consistent with pgtable.h scheme. Signed-off-by: Alexandre Ghiti Reviewed-by: Mike Kravetz --- arch/arm64

[PATCH v5 02/11] hugetlb: Introduce generic version of hugetlb_free_pgd_range

2018-07-30 Thread Alexandre Ghiti
arm, arm64, mips, parisc, sh, x86 architectures use the same version of hugetlb_free_pgd_range, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Reviewed-by: Mike Kravetz --- arch/arm/include/asm/hugetlb.h | 9 - arch/arm64/include/asm

[PATCH v5 03/11] hugetlb: Introduce generic version of set_huge_pte_at

2018-07-30 Thread Alexandre Ghiti
arm, ia64, mips, powerpc, sh, x86 architectures use the same version of set_huge_pte_at, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Reviewed-by: Mike Kravetz --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm

[PATCH v5 04/11] hugetlb: Introduce generic version of huge_ptep_get_and_clear

2018-07-30 Thread Alexandre Ghiti
arm, ia64, sh, x86 architectures use the same version of huge_ptep_get_and_clear, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Reviewed-by: Mike Kravetz --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h

[PATCH v5 05/11] hugetlb: Introduce generic version of huge_ptep_clear_flush

2018-07-30 Thread Alexandre Ghiti
arm, x86 architectures use the same version of huge_ptep_clear_flush, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Reviewed-by: Mike Kravetz --- arch/arm/include/asm/hugetlb-3level.h | 6 -- arch/arm64/include/asm/hugetlb.h | 1 + arch

[PATCH v5 06/11] hugetlb: Introduce generic version of huge_pte_none

2018-07-30 Thread Alexandre Ghiti
arm, arm64, ia64, parisc, powerpc, sh, sparc, x86 architectures use the same version of huge_pte_none, so move this generic implementation into asm-generic/hugetlb.h. Signed-off-by: Alexandre Ghiti Reviewed-by: Mike Kravetz --- arch/arm/include/asm/hugetlb.h | 5 - arch/arm64/include

  1   2   3   4   >