[RFC PATCH v2 2/2] Implement sharing/unsharing of PMDs for FS/DAX

2019-06-07 Thread Larry Bassel
This is based on (but somewhat different from) what hugetlbfs does to share/unshare page tables. Signed-off-by: Larry Bassel --- include/linux/hugetlb.h | 4 ++ mm/huge_memory.c| 37 + mm/hugetlb.c| 8 ++-- mm/memory.c | 108

[RFC PATCH v2 1/2] Rename CONFIG_ARCH_WANT_HUGE_PMD_SHARE to CONFIG_ARCH_HAS_HUGE_PMD_SHARE

2019-06-07 Thread Larry Bassel
Signed-off-by: Larry Bassel --- arch/arm64/Kconfig | 2 +- arch/arm64/mm/hugetlbpage.c | 2 +- arch/x86/Kconfig| 2 +- mm/hugetlb.c| 6 +++--- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig index 697ea05

[RFC PATCH v2 0/2] Share PMDs for FS/DAX on x86

2019-06-07 Thread Larry Bassel
ntation of sharing and unsharing is based on, but somewhat different than that in mm/hugetlb.c, though some of the code from this file could be reused and thus was made non-static. Larry Bassel (2): Rename CONFIG_ARCH_WANT_HUGE_PMD_SHARE to CONFIG_ARCH_HAS_HUGE_PMD_SHARE Implement sharing/un

Re: [PATCH, RFC 2/2] Implement sharing/unsharing of PMDs for FS/DAX

2019-05-24 Thread Larry Bassel
On 14 May 19 16:01, Kirill A. Shutemov wrote: > On Thu, May 09, 2019 at 09:05:33AM -0700, Larry Bassel wrote: [trim] > > --- a/mm/huge_memory.c > > +++ b/mm/huge_memory.c > > @@ -1747,6 +1747,33 @@ static inline void zap_deposited_table(struct > > mm_struct *mm, pmd_t *

Re: [PATCH, RFC 0/2] Share PMDs for FS/DAX on x86

2019-05-14 Thread Larry Bassel
On 14 May 19 15:28, Kirill A. Shutemov wrote: > On Thu, May 09, 2019 at 09:05:31AM -0700, Larry Bassel wrote: > > This patchset implements sharing of page table entries pointing > > to 2MiB pages (PMDs) for FS/DAX on x86. > > -EPARSE. > > How do you share entries? En

Re: question about page tables in DAX/FS/PMEM case

2019-02-21 Thread Larry Bassel
[adding linux-mm] On 21 Feb 19 15:41, Jerome Glisse wrote: > On Wed, Feb 20, 2019 at 03:06:22PM -0800, Larry Bassel wrote: > > I'm working on sharing page tables in the DAX/XFS/PMEM/PMD case. > > > > If multiple processes would use the identical page of PMDs correspond

question about page tables in DAX/FS/PMEM case

2019-02-20 Thread Larry Bassel
I'm working on sharing page tables in the DAX/XFS/PMEM/PMD case. If multiple processes would use the identical page of PMDs corresponding to a 1 GiB address range of DAX/XFS/PMEM/PMDs, presumably one can instead of populating a new PUD, just atomically increment a refcount and point to the same PU

question about mmap MAP_PRIVATE on PMEM/DAX/fs files

2019-02-06 Thread Larry Bassel
Is mmaping a PMEM/DAX/fs file MAP_PRIVATE supported? Is it something that people are likely to want to do? If it is supported, suppose I open a file in PMEM/DAX/fs, mmap it MAP_PRIVATE, read from the memory mapped file (with memory accesses, not the read syscall) and take a page fault which the ke

RFC: revisiting shared page tables

2018-12-04 Thread Larry Bassel
with Dave's 2.6.13 patch (plus fixes to the known bugs in it) and forward port it to the tip, rather than starting from scratch? Thanks. Larry Bassel

Re: [RFC] mm, THP: Map read-only text segments using large THP pages

2018-05-17 Thread Larry Bassel
On 17 May 18 08:23, Matthew Wilcox wrote: > > I can't find any information on what page sizes SPARC supports. > Maybe you could point me at a reference? All I've managed to find is > the architecture manuals for SPARC which believe it is not their purpose > to mandate an MMU. > Page sizes of 8K

[PATCH v8 1/2] arm64: adjust el0_sync so that a function can be called

2014-06-03 Thread Larry Bassel
similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call (save far_el1 in x26 temporarily instead). Acked-by: Will Deacon Reviewed-by: Kevin Hilman Tested-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/kernel/entry.S

[PATCH v8 0/2] context tracker support for arm64

2014-06-03 Thread Larry Bassel
/will/linux.git) Changes v2 to v3: * Save/restore necessary registers in ct_user_enter and ct_user_exit * Annotate "error paths" out of el0_sync with ct_user_exit Changes v1 to v2: * Save far_el1 in x26 temporarily Larry Bassel (2): arm64: adjust el0_sync so that a function can

[PATCH v8 2/2] arm64: enable context tracking

2014-06-03 Thread Larry Bassel
e by Kevin. Acked-by: Will Deacon Reviewed-by: Kevin Hilman Tested-by: Kevin Hilman Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 4 arch/arm64/kernel/entry.S

[PATCH v7 0/2] context tracker support for arm64

2014-05-30 Thread Larry Bassel
nd ct_user_exit * Annotate "error paths" out of el0_sync with ct_user_exit Changes v1 to v2: * Save far_el1 in x26 temporarily Larry Bassel (2): arm64: adjust el0_sync so that a function can be called arm64: enable context tracking arch/arm64/Kconfig | 1

[PATCH v7 2/2] arm64: enable context tracking

2014-05-30 Thread Larry Bassel
e by Kevin. Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel Acked-by: Will Deacon --- arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 4 arch/arm64/kernel/entry.S| 39 +++- 3 files changed, 43 insert

[PATCH v7 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-30 Thread Larry Bassel
similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call (save far_el1 in x26 temporarily instead). Signed-off-by: Larry Bassel Acked-by: Will Deacon --- arch/arm64/kernel/entry.S | 19 +-- 1 file changed, 13 insertions(+), 6 dele

[PATCH v6 0/2] context tracker support for arm64

2014-05-29 Thread Larry Bassel
er_exit Changes v1 to v2: * Save far_el1 in x26 temporarily Larry Bassel (2): arm64: adjust el0_sync so that a function can be called arm64: enable context tracking arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 4 +++ arch/arm64/kerne

[PATCH v6 2/2] arm64: enable context tracking

2014-05-29 Thread Larry Bassel
e by Kevin. Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 4 arch/arm64/kernel/entry.S| 39 +++- 3 files changed, 43 insertions(+), 1 deletion(-)

[PATCH v6 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-29 Thread Larry Bassel
similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call (save far_el1 in x26 temporarily instead). Signed-off-by: Larry Bassel --- arch/arm64/kernel/entry.S | 19 +-- 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a

[PATCH v6 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-29 Thread Larry Bassel
similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call (save far_el1 in x26 temporarily instead). Signed-off-by: Larry Bassel --- arch/arm64/kernel/entry.S | 19 +-- 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a

[PATCH v6 2/2] arm64: enable context tracking

2014-05-29 Thread Larry Bassel
e by Kevin. Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 4 arch/arm64/kernel/entry.S| 39 +++- 3 files changed, 43 insertions(+), 1 deletion(-)

[PATCH v6 0/2] context tracker support for arm64

2014-05-29 Thread Larry Bassel
er_exit Changes v1 to v2: * Save far_el1 in x26 temporarily *** BLURB HERE *** Larry Bassel (2): arm64: adjust el0_sync so that a function can be called arm64: enable context tracking arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 4 +++ arch/arm64/kerne

Re: [PATCH v5 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-28 Thread Larry Bassel
On 28 May 14 12:27, Will Deacon wrote: > Hi Larry, > > On Mon, May 26, 2014 at 07:56:12PM +0100, Larry Bassel wrote: > > To implement the context tracker properly on arm64, > > a function call needs to be made after debugging and > > interrupts are turned on, but befo

[PATCH v5 0/2] context tracker support for arm64

2014-05-26 Thread Larry Bassel
necessary registers in ct_user_enter and ct_user_exit * Annotate "error paths" out of el0_sync with ct_user_exit Changes v1 to v2: * Save far_el1 in x26 temporarily Larry Bassel (2): arm64: adjust el0_sync so that a function can be called arm64: enable context tracking

[PATCH v5 2/2] arm64: enable context tracking

2014-05-26 Thread Larry Bassel
e by Kevin. Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 1 + arch/arm64/kernel/entry.S| 46 3 files changed, 48 insertions(+) diff --git a/

[PATCH v5 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-26 Thread Larry Bassel
similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call (save far_el1 in x26 temporarily instead). Signed-off-by: Larry Bassel --- arch/arm64/kernel/entry.S | 23 --- 1 file changed, 16 insertions(+), 7 deletions(-) diff --

Re: [PATCH v4 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-23 Thread Larry Bassel
On 23 May 14 15:44, Catalin Marinas wrote: > On Thu, May 22, 2014 at 11:35:20PM +0100, Larry Bassel wrote: > > > On 05/22/2014 03:27 PM, Larry Bassel wrote: > > > > To implement the context tracker properly on arm64, > > > > a function call needs to be made af

Re: [PATCH v4 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-22 Thread Larry Bassel
On 22 May 14 16:23, Christopher Covington wrote: > Hi Larry, > > On 05/22/2014 03:27 PM, Larry Bassel wrote: > > To implement the context tracker properly on arm64, > > a function call needs to be made after debugging and > > interrupts are turned on, but before the lr

[PATCH v4 0/2] context tracker support for arm64

2014-05-22 Thread Larry Bassel
Save far_el1 in x26 temporarily Larry Bassel (2): arm64: adjust el0_sync so that a function can be called arm64: enable context tracking arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 1 + arch/arm64/kernel/entry.S| 72 -

[PATCH v4 2/2] arm64: enable context tracking

2014-05-22 Thread Larry Bassel
e by Kevin. Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 1 + arch/arm64/kernel/entry.S| 48 3 files changed, 50 insertions(+) diff --git a/

[PATCH v4 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-22 Thread Larry Bassel
similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call (save far_el1 in x26 temporarily instead). Signed-off-by: Larry Bassel --- arch/arm64/kernel/entry.S | 24 +--- 1 file changed, 17 insertions(+), 7 deletions(-) diff --

[PATCH v3] arm64: Support arch_irq_work_raise() via self IPIs

2014-05-12 Thread Larry Bassel
lof Johansson Signed-off-by: Stephen Boyd Tested-by: Olof Johansson Signed-off-by: Russell King Changes v2 to v3: * Do not call is_smp() as this is only defined on arm32 Changes v1 to v2: * Include ARM 7887/1 bugfix Signed-off-by: Larry Bassel Reviewed-by: Kevin Hilman ---

Re: [PATCH v2] arm64: Support arch_irq_work_raise() via self IPIs

2014-05-12 Thread Larry Bassel
On 12 May 14 10:29, Will Deacon wrote: > On Sat, May 10, 2014 at 11:23:41PM +0100, Larry Bassel wrote: > > Support for arch_irq_work_raise() was missing from > > arm64 (a prerequisite for FULL_NOHZ). > > [...] > > > @@ -455,6 +457,14 @@ void arch_send_ca

[PATCH v2] arm64: Support arch_irq_work_raise() via self IPIs

2014-05-10 Thread Larry Bassel
Reported-by: Olof Johansson Signed-off-by: Stephen Boyd Tested-by: Olof Johansson Signed-off-by: Russell King Changes v1 to v2: * Include ARM 7887/1 bugfix Signed-off-by: Larry Bassel Reviewed-by: Kevin Hilman --- arch/arm64/include/asm/hardirq.h | 2 +- arch/arm64/ker

Re: [PATCH] arm64: Support arch_irq_work_raise() via self IPIs

2014-05-10 Thread Larry Bassel
On 09 May 14 16:57, Catalin Marinas wrote: > On Mon, May 05, 2014 at 09:48:27PM +0100, Larry Bassel wrote: > > Support for arch_irq_work_raise() was missing from > > arm64 (a prerequisite for FULL_NOHZ). > > > > This patch is based on the arm32 patch ARM 787

[PATCH v3 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-09 Thread Larry Bassel
. For similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call (save far_el1 in x26 temporarily instead). Signed-off-by: Larry Bassel Reviewed-by: Kevin Hilman --- arch/arm64/kernel/entry.S | 27 +++ 1 file change

[PATCH v3 2/2] arm64: enable context tracking

2014-05-09 Thread Larry Bassel
a previous patch of this series). The calls to ct_user_exit are made after hw debugging has been enabled (enable_dbg). The call to ct_user_enter is made at the beginning of the kernel_exit macro. This patch is based on earlier work by Kevin Hilman. Signed-off-by: Kevin Hilman Signed-off-by: La

[PATCH v3 0/2] context tracker support for arm64

2014-05-09 Thread Larry Bassel
ot; out of el0_sync with ct_user_exit Changes v1 to v2: * Save far_el1 in x26 temporarily Larry Bassel (2): arm64: adjust el0_sync so that a function can be called arm64: enable context tracking arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 1 +

Re: [PATCH v2 2/2] arm64: enable context tracking

2014-05-07 Thread Larry Bassel
On 07 May 14 11:17, Will Deacon wrote: > On Wed, May 07, 2014 at 12:32:29AM +0100, Larry Bassel wrote: > > Make calls to ct_user_enter when the kernel is exited > > and ct_user_exit when the kernel is entered (in el0_da, > > el0_ia, el0_svc, el0_irq). > > Why onl

[PATCH v2 0/2] context tracker support for arm64

2014-05-06 Thread Larry Bassel
Implement and enable context tracking for arm64 (which is a prerequisite for FULL_NOHZ support). This patchset builds upon earlier work by Kevin Hilman and is based on 3.15-rc2. Larry Bassel (2): arm64: adjust el0_sync so that a function can be called arm64: enable context tracking arch

[PATCH v2 1/2] arm64: adjust el0_sync so that a function can be called

2014-05-06 Thread Larry Bassel
. For similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call (save far_el1 in x26 temporarily instead). Signed-off-by: Larry Bassel Reviewed-by: Kevin Hilman --- arch/arm64/kernel/entry.S | 14 +- 1 file changed, 9 insertions(

[PATCH v2 2/2] arm64: enable context tracking

2014-05-06 Thread Larry Bassel
. Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 1 + arch/arm64/kernel/entry.S| 22 ++ 3 files changed, 24 insertions(+) diff --git a/arch/arm64/Kconfig b/arch/arm64

[PATCH] arm64: Support arch_irq_work_raise() via self IPIs

2014-05-05 Thread Larry Bassel
SMP builds anyway. Signed-off-by: Stephen Boyd Reviewed-by: Kevin Hilman Cc: Frederic Weisbecker Signed-off-by: Russell King Signed-off-by: Larry Bassel Reviewed-by: Kevin Hilman --- arch/arm64/include/asm/hardirq.h | 2 +- arch/arm64/kernel/smp.c | 18 +++

[PATCH 3/3] arm64: enable context tracking

2014-04-27 Thread Larry Bassel
calls to ct_user_exit are made after hw debugging has been enabled (enable_dbg). The call to ct_user_enter is made at the end of the kernel_exit macro. Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/kernel/entry.S | 5 + 1 file changed, 5 insertions(+) diff --git a

[PATCH 2/3] arm64: add support for context tracking

2014-04-27 Thread Larry Bassel
From: Kevin Hilman Add the macros and defines needed to implement context tracking on arm64. Signed-off-by: Kevin Hilman Signed-off-by: Larry Bassel --- arch/arm64/Kconfig | 1 + arch/arm64/include/asm/thread_info.h | 1 + arch/arm64/kernel/entry.S| 16

[PATCH 0/3] context tracker support for arm64

2014-04-27 Thread Larry Bassel
Implement and enable context tracking for arm64 (which is a prerequisite for FULL_NOHZ support). This patchset builds upon earlier work by Kevin Hilman and is based on 3.15-rc2. Kevin Hilman (1): arm64: add support for context tracking Larry Bassel (2): arm64: adjust el0_sync so that a

[PATCH 1/3] arm64: adjust el0_sync so that a function can be called

2014-04-27 Thread Larry Bassel
. For similar reasons, defer the setting of x0 so that it doesn't need to be saved around the function call. Signed-off-by: Larry Bassel Reviewed-by: Kevin Hilman --- arch/arm64/kernel/entry.S | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/arch/arm64/k