Re: [PATCH v6 1/2] kexec: Consolidate machine_kexec_mask_interrupts() implementation

2025-01-27 Thread Will Deacon
On Wed, Dec 04, 2024 at 02:20:02PM +, Eliav Farber wrote: > Consolidate the machine_kexec_mask_interrupts implementation into a common > function located in a new file: kernel/irq/kexec.c. This removes duplicate > implementations from architecture-specific files in arch/arm, arch/arm64, > arch/

Re: [PATCH v5 05/17] arm64: pgtable: use mmu gather to free p4d level page table

2025-01-17 Thread Will Deacon
On Tue, Jan 14, 2025 at 10:26:54AM +0800, Qi Zheng wrote: > Hi Will, > > On 2025/1/14 00:26, Will Deacon wrote: > > On Wed, Jan 08, 2025 at 02:57:21PM +0800, Qi Zheng wrote: > > > Like other levels of page tables, also use mmu gather mechanism to free &g

Re: [PATCH v5 09/17] arm64: pgtable: move pagetable_dtor() to __tlb_remove_table()

2025-01-13 Thread Will Deacon
by: Kevin Brodsky > Cc: linux-arm-ker...@lists.infradead.org > --- > arch/arm64/include/asm/tlb.h | 10 -- > 1 file changed, 4 insertions(+), 6 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH v5 05/17] arm64: pgtable: use mmu gather to free p4d level page table

2025-01-13 Thread Will Deacon
On Wed, Jan 08, 2025 at 02:57:21PM +0800, Qi Zheng wrote: > Like other levels of page tables, also use mmu gather mechanism to free > p4d level page table. > > Signed-off-by: Qi Zheng > Originally-by: Peter Zijlstra (Intel) > Reviewed-by: Kevin Brodsky > Cc: linux-arm-ker...@lists.infradead.org

Re: [PATCH v6 1/5] arm: perf: Drop unused functions

2024-11-07 Thread Will Deacon
them here. > > Signed-off-by: Colton Lewis > Reviewed-by: Oliver Upton > --- > arch/arm/include/asm/perf_event.h | 7 --- > arch/arm/kernel/perf_callchain.c | 17 - > 2 files changed, 24 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH 05/28] arm64: vdso: Use only one single vvar mapping

2024-10-28 Thread Will Deacon
sing the vDSO. It all seems ok, so: Acked-by: Will Deacon Tested-by: Will Deacon Will

Re: [PATCH 04/28] arm64: vdso: Drop LBASE_VDSO

2024-10-28 Thread Will Deacon
> Signed-off-by: Thomas Weißschuh > --- > arch/arm64/include/asm/vdso.h | 9 + > arch/arm64/kernel/vdso/vdso.lds.S | 2 +- > arch/arm64/kernel/vdso32/vdso.lds.S | 2 +- > 3 files changed, 3 insertions(+), 10 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH v2] of/fdt: add dt_phys arg to early_init_dt_scan and early_init_dt_verify

2024-10-28 Thread Will Deacon
On Wed, Oct 23, 2024 at 06:14:26PM +0100, Usama Arif wrote: > __pa() is only intended to be used for linear map addresses and using > it for initial_boot_params which is in fixmap for arm64 will give an > incorrect value. Hence save the physical address when it is known at > boot time when calling

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-15 Thread Will Deacon
On Tue, Oct 15, 2024 at 10:59:11AM +0100, Joey Gouly wrote: > On Mon, Oct 14, 2024 at 06:10:23PM +0100, Will Deacon wrote: > > Kevin, Joey, > > > > On Wed, Oct 09, 2024 at 03:43:01PM +0100, Will Deacon wrote: > > > On Tue, Sep 24, 2024 at 01:27:58PM +0200, Kevin B

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-14 Thread Will Deacon
Kevin, Joey, On Wed, Oct 09, 2024 at 03:43:01PM +0100, Will Deacon wrote: > On Tue, Sep 24, 2024 at 01:27:58PM +0200, Kevin Brodsky wrote: > > On 22/08/2024 17:11, Joey Gouly wrote: > > > @@ -1178,6 +1237,9 @@ static void setup_return(struct pt_regs *regs, > >

Re: [PATCH 3/9] arm64: vdso: Remove timekeeper include

2024-10-14 Thread Will Deacon
#include > #include > #include > -#include > #include > #include > #include Acked-by: Will Deacon Will

Re: [PATCH 1/9] vdso: Remove timekeeper argument of __arch_update_vsyscall()

2024-10-14 Thread Will Deacon
: Thomas Weißschuh > --- > arch/arm64/include/asm/vdso/vsyscall.h | 3 +-- > include/asm-generic/vdso/vsyscall.h| 3 +-- > kernel/time/vsyscall.c | 2 +- > 3 files changed, 3 insertions(+), 5 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-09 Thread Will Deacon
Hi Kevin, On Tue, Sep 24, 2024 at 01:27:58PM +0200, Kevin Brodsky wrote: > On 22/08/2024 17:11, Joey Gouly wrote: > > @@ -1178,6 +1237,9 @@ static void setup_return(struct pt_regs *regs, struct > > k_sigaction *ka, > > sme_smstop(); > > } > > > > + if (system_supports_poe()) >

Re: [PATCH v5 06/30] arm64: context switch POR_EL0 register

2024-09-13 Thread Will Deacon
On Thu, Sep 12, 2024 at 01:48:35PM +0100, Joey Gouly wrote: > On Thu, Sep 12, 2024 at 11:50:18AM +0100, Will Deacon wrote: > > On Wed, Sep 11, 2024 at 08:33:54AM -0700, Dave Hansen wrote: > > > On 9/11/24 08:01, Kevin Brodsky wrote: > > > > On 22/08/2024 17:10, Joey G

Re: [PATCH v5 06/30] arm64: context switch POR_EL0 register

2024-09-12 Thread Will Deacon
Hi Dave, On Wed, Sep 11, 2024 at 08:33:54AM -0700, Dave Hansen wrote: > On 9/11/24 08:01, Kevin Brodsky wrote: > > On 22/08/2024 17:10, Joey Gouly wrote: > >> @@ -371,6 +382,9 @@ int copy_thread(struct task_struct *p, const struct > >> kernel_clone_args *args) > >>if (system_supports_

Re: [PATCH v5 06/30] arm64: context switch POR_EL0 register

2024-09-04 Thread Will Deacon
On Wed, Sep 04, 2024 at 01:55:03PM +0100, Joey Gouly wrote: > On Wed, Sep 04, 2024 at 12:43:02PM +0100, Will Deacon wrote: > > Right, there's quite a lot I need to do: > > > > - Uncorrupt your patches > > - Fix the conflict in the kvm selftests > > - Drop

Re: [PATCH v5 06/30] arm64: context switch POR_EL0 register

2024-09-04 Thread Will Deacon
On Wed, Sep 04, 2024 at 12:32:21PM +0100, Joey Gouly wrote: > On Wed, Sep 04, 2024 at 11:22:54AM +0100, Will Deacon wrote: > > On Tue, Sep 03, 2024 at 03:54:13PM +0100, Joey Gouly wrote: > > > On Mon, Sep 02, 2024 at 08:08:08PM +0100, Catalin Marinas wrote: > > > >

Re: [PATCH v5 06/30] arm64: context switch POR_EL0 register

2024-09-04 Thread Will Deacon
On Tue, Sep 03, 2024 at 03:54:13PM +0100, Joey Gouly wrote: > On Mon, Sep 02, 2024 at 08:08:08PM +0100, Catalin Marinas wrote: > > On Tue, Aug 27, 2024 at 12:38:04PM +0100, Will Deacon wrote: > > > On Fri, Aug 23, 2024 at 07:40:52PM +0100, Catalin Marinas wrote: > > > &

Re: [PATCH v5 08/30] KVM: arm64: make kvm_at() take an OP_AT_*

2024-08-30 Thread Will Deacon
er Upton > Cc: Catalin Marinas > Cc: Will Deacon > Reviewed-by: Marc Zyngier > --- > arch/arm64/include/asm/kvm_asm.h | 3 ++- > arch/arm64/kvm/hyp/include/hyp/fault.h | 2 +- > 2 files changed, 3 insertions(+), 2 deletions(-) Acked-by: Will Deacon > diff --git arch

Re: [PATCH v5 08/30] KVM: arm64: make kvm_at() take an OP_AT_*

2024-08-30 Thread Will Deacon
Hey Marc, On Fri, Aug 30, 2024 at 09:01:18AM +0100, Marc Zyngier wrote: > On Fri, 23 Aug 2024 14:48:11 +0100, > Will Deacon wrote: > > > > On Thu, Aug 22, 2024 at 04:10:51PM +0100, Joey Gouly wrote: > > > To allow using newer instructions that current assembl

Re: [PATCH v5 06/30] arm64: context switch POR_EL0 register

2024-08-27 Thread Will Deacon
On Fri, Aug 23, 2024 at 07:40:52PM +0100, Catalin Marinas wrote: > On Fri, Aug 23, 2024 at 06:08:36PM +0100, Will Deacon wrote: > > On Fri, Aug 23, 2024 at 05:41:06PM +0100, Catalin Marinas wrote: > > > On Fri, Aug 23, 2024 at 03:45:32PM +0100, Will Deacon wrote: > > > &

Re: [PATCH v5 06/30] arm64: context switch POR_EL0 register

2024-08-23 Thread Will Deacon
On Fri, Aug 23, 2024 at 05:41:06PM +0100, Catalin Marinas wrote: > On Fri, Aug 23, 2024 at 03:45:32PM +0100, Will Deacon wrote: > > On Thu, Aug 22, 2024 at 04:10:49PM +0100, Joey Gouly wrote: > > > +static void permission_overlay_switch(struct task_struct *next) &

Re: [PATCH v5 06/30] arm64: context switch POR_EL0 register

2024-08-23 Thread Will Deacon
On Thu, Aug 22, 2024 at 04:10:49PM +0100, Joey Gouly wrote: > POR_EL0 is a register that can be modified by userspace directly, > so it must be context switched. > > Signed-off-by: Joey Gouly > Cc: Catalin Marinas > Cc: Will Deacon > Reviewed-by: Catalin Marinas > -

Re: [PATCH v5 08/30] KVM: arm64: make kvm_at() take an OP_AT_*

2024-08-23 Thread Will Deacon
er Upton > Cc: Catalin Marinas > Cc: Will Deacon > Reviewed-by: Marc Zyngier > --- > arch/arm64/include/asm/kvm_asm.h | 3 ++- > arch/arm64/kvm/hyp/include/hyp/fault.h | 2 +- > 2 files changed, 3 insertions(+), 2 deletions(-) Marc -- what would you like to do with this p

Re: [PATCH v5 04/30] arm64: disable trapping of POR_EL0 to EL2

2024-08-23 Thread Will Deacon
On Thu, Aug 22, 2024 at 04:10:47PM +0100, Joey Gouly wrote: > Allow EL0 or EL1 to access POR_EL0 without being trapped to EL2. > > Signed-off-by: Joey Gouly > Cc: Catalin Marinas > Cc: Will Deacon > Acked-by: Catalin Marinas > Reviewed-by: Anshuman Khandual > --- &

Re: [PATCH v6 RESED 1/2] dma: replace zone_dma_bits by zone_dma_limit

2024-08-16 Thread Will Deacon
On Sun, Aug 11, 2024 at 10:09:35AM +0300, Baruch Siach wrote: > From: Catalin Marinas > > Hardware DMA limit might not be power of 2. When RAM range starts above > 0, say 4GB, DMA limit of 30 bits should end at 5GB. A single high bit > can not encode this limit. > > Use plain address for DMA zon

Re: [PATCH 13/13] mm: Remove devmap related functions and page table bits

2024-07-08 Thread Will Deacon
arch/arm64/include/asm/pgtable.h | 24 + Not only do you exclusively remove code, but you also give us back a pte bit! What's not to like? Acked-by: Will Deacon # arm64 Will

Re: [PATCH RESEND v8 16/16] bpf: remove CONFIG_BPF_JIT dependency on CONFIG_MODULES of

2024-05-17 Thread Will Deacon
Hi Klara, On Fri, May 17, 2024 at 01:00:31AM +0200, Klara Modin wrote: > On 2024-05-05 18:06, Mike Rapoport wrote: > > From: "Mike Rapoport (IBM)" > > > > BPF just-in-time compiler depended on CONFIG_MODULES because it used > > module_alloc() to allocate memory for the generated code. > > > > S

Re: [PATCH 1/3] x86/cpu: Actually turn off mitigations by default for SPECULATION_MITIGATIONS=n

2024-04-19 Thread Will Deacon
On Fri, Apr 19, 2024 at 07:06:00AM -0700, Sean Christopherson wrote: > On Fri, Apr 19, 2024, Will Deacon wrote: > > On Mon, Apr 15, 2024 at 07:31:23AM -0700, Sean Christopherson wrote: > > > On Mon, Apr 15, 2024, Geert Uytterhoeven wrote: > > > Oof. I completely m

Re: [PATCH 1/3] x86/cpu: Actually turn off mitigations by default for SPECULATION_MITIGATIONS=n

2024-04-19 Thread Will Deacon
On Mon, Apr 15, 2024 at 07:31:23AM -0700, Sean Christopherson wrote: > On Mon, Apr 15, 2024, Geert Uytterhoeven wrote: > > On Sat, Apr 13, 2024 at 11:38 AM Michael Ellerman > > wrote: > > > Michael Ellerman writes: > > > > Stephen Rothwell writes: > > > ... > > > >> On Tue, 9 Apr 2024 10:51:05

Re: [PATCH] asm-generic/mmiowb: Mark accesses to fix KCSAN warnings

2024-04-19 Thread Will Deacon
On Thu, Apr 04, 2024 at 03:38:53PM +1100, Rohan McLure wrote: > Prior to this patch, data races are detectable by KCSAN of the following > forms: > > [1] Asynchronous calls to mmiowb_set_pending() from an interrupt context > or otherwise outside of a critical section > [2] Interrupted critical

Re: [PATCH 1/4] KVM: delete .change_pte MMU notifier callback

2024-04-19 Thread Will Deacon
On Thu, Apr 18, 2024 at 12:53:26PM -0700, Sean Christopherson wrote: > On Thu, Apr 18, 2024, Will Deacon wrote: > > On Mon, Apr 15, 2024 at 10:03:51AM -0700, Sean Christopherson wrote: > > > On Sat, Apr 13, 2024, Marc Zyngier wrote: > > > > On Fri, 12 Apr 2024 15:54

Re: [PATCH 1/4] KVM: delete .change_pte MMU notifier callback

2024-04-18 Thread Will Deacon
On Mon, Apr 15, 2024 at 10:03:51AM -0700, Sean Christopherson wrote: > On Sat, Apr 13, 2024, Marc Zyngier wrote: > > On Fri, 12 Apr 2024 15:54:22 +0100, Sean Christopherson > > wrote: > > > > > > On Fri, Apr 12, 2024, Marc Zyngier wrote: > > > > On

Re: [PATCH 1/4] KVM: delete .change_pte MMU notifier callback

2024-04-12 Thread Will Deacon
rn false; > -} > - > bool kvm_age_gfn(struct kvm *kvm, struct kvm_gfn_range *range) > { > u64 size = (range->end - range->start) << PAGE_SHIFT; Thanks. It's nice to see this code retire: Acked-by: Will Deacon Also, if you're in the business of hacking t

Re: [RFC PATCH 04/12] arm64: Implement ARCH_HAS_KERNEL_FPU_SUPPORT

2023-12-13 Thread Will Deacon
On Thu, Dec 07, 2023 at 09:54:34PM -0800, Samuel Holland wrote: > arm64 provides an equivalent to the common kernel-mode FPU API, but in a > different header and using different function names. Add a wrapper > header, and export CFLAGS adjustments as found in lib/raid6/Makefile. > > Signed-off-by:

Re: [PATCH v3 04/13] mm/execmem, arch: convert remaining overrides of module_alloc to execmem

2023-11-07 Thread Will Deacon
On Mon, Oct 30, 2023 at 09:00:53AM +0200, Mike Rapoport wrote: > On Thu, Oct 26, 2023 at 11:24:39AM +0100, Will Deacon wrote: > > On Thu, Oct 26, 2023 at 11:58:00AM +0300, Mike Rapoport wrote: > > > On Mon, Oct 23, 2023 at 06:14:20PM +0100, Will Deacon wrote: > > > >

Re: [PATCH v3 04/13] mm/execmem, arch: convert remaining overrides of module_alloc to execmem

2023-10-26 Thread Will Deacon
On Thu, Oct 26, 2023 at 11:58:00AM +0300, Mike Rapoport wrote: > On Mon, Oct 23, 2023 at 06:14:20PM +0100, Will Deacon wrote: > > On Mon, Sep 18, 2023 at 10:29:46AM +0300, Mike Rapoport wrote: > > > diff --git a/arch/arm64/kernel/module.c b/arch/arm64/kernel/module.c > &

Re: [PATCH v3 07/13] arm64, execmem: extend execmem_params for generated code allocations

2023-10-23 Thread Will Deacon
; -{ > - return __vmalloc_node_range(PAGE_SIZE, 1, VMALLOC_START, VMALLOC_END, > - GFP_KERNEL, PAGE_KERNEL_ROX, VM_FLUSH_RESET_PERMS, > - NUMA_NO_NODE, __builtin_return_address(0)); > -} It's slightly curious that we didn't clear the tag here, so it's nice that it all happens magically with your series: Acked-by: Will Deacon Will

Re: [PATCH v3 04/13] mm/execmem, arch: convert remaining overrides of module_alloc to execmem

2023-10-23 Thread Will Deacon
Hi Mike, On Mon, Sep 18, 2023 at 10:29:46AM +0300, Mike Rapoport wrote: > From: "Mike Rapoport (IBM)" > > Extend execmem parameters to accommodate more complex overrides of > module_alloc() by architectures. > > This includes specification of a fallback range required by arm, arm64 > and powerp

Re: [PATCH v2 2/2] arm64: hugetlb: Fix set_huge_pte_at() to work with all swap entries

2023-09-22 Thread Will Deacon
folio_size(folio), &pgsize); > + ncontig = num_contig_ptes(sz, &pgsize); > > - for (i = 0; i < ncontig; i++, ptep++) > + if (!pte_present(pte)) { > + for (i = 0; i < ncontig; i++, ptep++, addr += pgsize) > set_pte_at(mm, addr, ptep, pte); Our set_pte_at() doesn't use 'addr' for anything and the old code didn't even bother to increment it here! I'm fine adding that, but it feels unrelated to the issue which this patch is actually fixing. Either way: Acked-by: Will Deacon Will

Re: [PATCH] word-at-a-time: use the same return type for has_zero regardless of endianness

2023-08-04 Thread Will Deacon
On Wed, Aug 02, 2023 at 08:17:32PM +0200, Arnd Bergmann wrote: > On Wed, Aug 2, 2023, at 19:37, Linus Torvalds wrote: > > On Wed, 2 Aug 2023 at 09:16, Nathan Chancellor wrote: > >> > >> We see this warning with ARCH=arm64 defconfig + CONFIG_CPU_BIG_ENDIAN=y. > > > > Oh Christ. I didn't even realiz

Re: [PATCH 0/3] COVER: Remove memcpy_page_flushcache()

2023-03-27 Thread Will Deacon
On Wed, 15 Mar 2023 16:20:53 -0700, Ira Weiny wrote: > Commit 21b56c847753 ("iov_iter: get rid of separate bvec and xarray > callbacks") removed the calls to memcpy_page_flushcache(). > > kmap_atomic() is deprecated and used in the x86 version of > memcpy_page_flushcache(). > > Remove the unneces

Re: lockref scalability on x86-64 vs cpu_relax

2023-01-13 Thread Will Deacon
On Fri, Jan 13, 2023 at 02:12:50AM +0100, Mateusz Guzik wrote: > On 1/13/23, Linus Torvalds wrote: > > Side note on your access() changes - if it turns out that you can > > remove all the cred games, we should possibly then revert my old > > commit d7852fbd0f04 ("access: avoid the RCU grace period

Re: [PATCH v3 01/14] perf/hw_breakpoint: Add KUnit test for constraints accounting

2022-07-22 Thread Will Deacon
On Fri, Jul 22, 2022 at 12:31:45PM +0200, Dmitry Vyukov wrote: > On Fri, 22 Jul 2022 at 12:11, Will Deacon wrote: > > > > > On Mon, Jul 04, 2022 at 05:05:01PM +0200, Marco Elver wrote: > > > > > I'm not immediately sure what would be necessary

Re: [PATCH v3 01/14] perf/hw_breakpoint: Add KUnit test for constraints accounting

2022-07-22 Thread Will Deacon
On Fri, Jul 22, 2022 at 11:20:25AM +0200, Dmitry Vyukov wrote: > On Fri, 22 Jul 2022 at 11:10, Will Deacon wrote: > > > [adding Will] > > > > > > On Mon, Jul 04, 2022 at 05:05:01PM +0200, Marco Elver wrote: > > > > Add KUnit test for hw_break

Re: [PATCH v3 01/14] perf/hw_breakpoint: Add KUnit test for constraints accounting

2022-07-22 Thread Will Deacon
On Thu, Jul 21, 2022 at 05:22:07PM +0100, Mark Rutland wrote: > Hi Marco, > > [adding Will] > > On Mon, Jul 04, 2022 at 05:05:01PM +0200, Marco Elver wrote: > > Add KUnit test for hw_breakpoint constraints accounting, with various > > interesting mixes of breakpoint targets (some care was taken t

Re: [PATCH -next v6 00/10]arm64: add machine check safe support

2022-06-28 Thread Will Deacon
On Tue, 21 Jun 2022 07:26:28 +, Tong Tiangen wrote: > With the increase of memory capacity and density, the probability of > memory error increases. The increasing size and density of server RAM > in the data center and cloud have shown increased uncorrectable memory > errors. > > Currently, t

Re: [PATCH -next v6 02/10] arm64: asm-extable: move data fields

2022-06-28 Thread Will Deacon
On Tue, Jun 21, 2022 at 07:26:30AM +, Tong Tiangen wrote: > In subsequent patches we'll need to fill in extable data fields in > regular assembly files. In preparation for this, move the definitions of > the extable data fields earlier in asm-extable.h so that they are > defined for both assemb

Re: [PATCH v1 4/7] arm64/pgtable: support __HAVE_ARCH_PTE_SWP_EXCLUSIVE

2022-03-21 Thread Will Deacon
On Mon, Mar 21, 2022 at 04:07:48PM +0100, David Hildenbrand wrote: > On 21.03.22 15:38, Will Deacon wrote: > > On Wed, Mar 16, 2022 at 06:27:01PM +, Catalin Marinas wrote: > >> On Tue, Mar 15, 2022 at 03:18:34PM +0100, David Hildenbrand wrote: > >>> diff --git a/

Re: [PATCH v1 4/7] arm64/pgtable: support __HAVE_ARCH_PTE_SWP_EXCLUSIVE

2022-03-21 Thread Will Deacon
On Mon, Mar 21, 2022 at 02:38:02PM +, Will Deacon wrote: > On Wed, Mar 16, 2022 at 06:27:01PM +, Catalin Marinas wrote: > > On Tue, Mar 15, 2022 at 03:18:34PM +0100, David Hildenbrand wrote: > > > diff --git a/arch/arm64/include/asm/pgtable-prot.h > > > b/arc

Re: [PATCH v1 4/7] arm64/pgtable: support __HAVE_ARCH_PTE_SWP_EXCLUSIVE

2022-03-21 Thread Will Deacon
On Wed, Mar 16, 2022 at 06:27:01PM +, Catalin Marinas wrote: > On Tue, Mar 15, 2022 at 03:18:34PM +0100, David Hildenbrand wrote: > > diff --git a/arch/arm64/include/asm/pgtable-prot.h > > b/arch/arm64/include/asm/pgtable-prot.h > > index b1e1b74d993c..62e0ebeed720 100644 > > --- a/arch/arm64/

Re: [PATCH 04/12] arm64: Use of_get_cpu_hwid()

2021-10-07 Thread Will Deacon
he DT tools will ensure 'reg' is present. > > Cc: Catalin Marinas > Cc: Will Deacon > Signed-off-by: Rob Herring > --- > arch/arm64/kernel/smp.c | 31 ++- > 1 file changed, 2 insertions(+), 29 deletions(-) Acked-by: Will Deacon It'

[PATCH] powerpc/svm: Don't issue ultracalls if !mem_encrypt_active()

2021-07-30 Thread Will Deacon
y: Sachin Sant Tested-by: Sachin Sant Tested-by: Nathan Chancellor Link: https://lore.kernel.org/r/1905cd70-7656-42ae-99e2-a31fc3812...@linux.vnet.ibm.com/ Signed-off-by: Will Deacon --- arch/powerpc/platforms/pseries/svm.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/arch/powerpc/p

Re: [powerpc][next-20210727] Boot failure - kernel BUG at arch/powerpc/kernel/interrupt.c:98!

2021-07-29 Thread Will Deacon
On Wed, Jul 28, 2021 at 10:35:34AM -0700, Nathan Chancellor wrote: > On Wed, Jul 28, 2021 at 01:31:06PM +0530, Sachin Sant wrote: > > next-20210723 was good. The boot failure seems to have been introduced with > > next-20210726. > > > > I have attached the boot log. > > I noticed this with OpenS

Re: [PATCH v2] Revert "mm/pgtable: add stubs for {pmd/pub}_{set/clear}_huge"

2021-07-21 Thread Will Deacon
On Wed, 21 Jul 2021 17:02:13 +1000, Michael Ellerman wrote: > This reverts commit c742199a014de23ee92055c2473d91fe5561ffdf. > > c742199a014d ("mm/pgtable: add stubs for {pmd/pub}_{set/clear}_huge") > breaks arm64 in at least two ways for configurations where PUD or PMD > folding occur: > > 1. W

[PATCH 2/2] Revert "mm/pgtable: add stubs for {pmd/pub}_{set/clear}_huge"

2021-07-20 Thread Will Deacon
rnel.org/r/20210717160118.9855-1-jonat...@marek.ca Fixes: c742199a014d ("mm/pgtable: add stubs for {pmd/pub}_{set/clear}_huge") Signed-off-by: Jonathan Marek Signed-off-by: Will Deacon --- arch/arm64/mm/mmu.c | 20 arch/x86/mm/pgtable.c | 34 +++--

[PATCH 1/2] Revert "powerpc/8xx: add support for huge pages on VMAP and VMALLOC"

2021-07-20 Thread Will Deacon
Cc: Catalin Marinas Cc: Andrew Morton Cc: Nicholas Piggin Cc: Mark Rutland Cc: Geert Uytterhoeven Cc: Marc Zyngier Link: https://lore.kernel.org/r/20210719170615.horde.qio1wp3k5eblo-d9xxhd...@messagerie.c-s.fr Signed-off-by: Will Deacon --- arch/powerpc/Kconfig

[PATCH 0/2] Fix arm64 boot regression in 5.14

2021-07-20 Thread Will Deacon
stubs for {pmd/pub}_{set/clear}_huge" Will Deacon (1): Revert "powerpc/8xx: add support for huge pages on VMAP and VMALLOC" arch/arm64/mm/mmu.c | 20 - arch/powerpc/Kconfig | 2 +- arch/powerpc/include/asm/nohash/32/mmu-8xx.

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-07-12 Thread Will Deacon
On Tue, Jul 06, 2021 at 12:59:57PM -0400, Konrad Rzeszutek Wilk wrote: > On Tue, Jul 06, 2021 at 05:57:21PM +0100, Will Deacon wrote: > > On Tue, Jul 06, 2021 at 10:46:07AM -0400, Konrad Rzeszutek Wilk wrote: > > > On Tue, Jul 06, 2021 at 04:05:13PM +0200, Christoph Hellwig wro

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-07-08 Thread Will Deacon
On Tue, Jul 06, 2021 at 12:14:16PM -0700, Nathan Chancellor wrote: > On 7/6/2021 10:06 AM, Will Deacon wrote: > > On Tue, Jul 06, 2021 at 04:39:11PM +0100, Robin Murphy wrote: > > > On 2021-07-06 15:05, Christoph Hellwig wrote: > > > > On Tue, Jul 06, 2021 at 03:01:

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-07-06 Thread Will Deacon
On Tue, Jul 06, 2021 at 04:39:11PM +0100, Robin Murphy wrote: > On 2021-07-06 15:05, Christoph Hellwig wrote: > > On Tue, Jul 06, 2021 at 03:01:04PM +0100, Robin Murphy wrote: > > > FWIW I was pondering the question of whether to do something along those > > > lines or just scrap the default assign

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-07-06 Thread Will Deacon
On Tue, Jul 06, 2021 at 10:46:07AM -0400, Konrad Rzeszutek Wilk wrote: > On Tue, Jul 06, 2021 at 04:05:13PM +0200, Christoph Hellwig wrote: > > On Tue, Jul 06, 2021 at 03:01:04PM +0100, Robin Murphy wrote: > > > FWIW I was pondering the question of whether to do something along those > > > lines o

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-07-06 Thread Will Deacon
On Tue, Jul 06, 2021 at 06:48:48AM +0200, Christoph Hellwig wrote: > On Mon, Jul 05, 2021 at 08:03:52PM +0100, Will Deacon wrote: > > So at this point, the AMD IOMMU driver does: > > > > swiotlb= (iommu_default_passthrough() || sme_me_mask) ? 1 : 0; > >

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-07-05 Thread Will Deacon
Hi Nathan, I may have just spotted something in these logs... On Fri, Jul 02, 2021 at 10:55:17PM -0700, Nathan Chancellor wrote: > [2.340956] pci :0c:00.1: Adding to iommu group 4 > [2.340996] pci :0c:00.2: Adding to iommu group 4 > [2.341038] pci :0c:00.3: Adding to iommu

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-07-02 Thread Will Deacon
Hi Nathan, On Thu, Jul 01, 2021 at 12:52:20AM -0700, Nathan Chancellor wrote: > On 7/1/2021 12:40 AM, Will Deacon wrote: > > On Wed, Jun 30, 2021 at 08:56:51AM -0700, Nathan Chancellor wrote: > > > On Wed, Jun 30, 2021 at 12:43:48PM +0100, Will Deacon wrote: > > > >

Re: [PATCH v15 12/12] of: Add plumbing for restricted DMA pool

2021-07-02 Thread Will Deacon
ted DMA when the restricted-dma-pool is presented. > > > > > > Signed-off-by: Claire Chang > > > Tested-by: Stefano Stabellini > > > Tested-by: Will Deacon > > > > With this patch in place, all sparc and sparc64 qemu emulations > > fail to

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-07-01 Thread Will Deacon
On Wed, Jun 30, 2021 at 08:56:51AM -0700, Nathan Chancellor wrote: > On Wed, Jun 30, 2021 at 12:43:48PM +0100, Will Deacon wrote: > > On Wed, Jun 30, 2021 at 05:17:27PM +0800, Claire Chang wrote: > > > `BUG: unable to handle page fault for address: 003a8290` and > &g

Re: [PATCH v15 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-06-30 Thread Will Deacon
d > > > use it to determine whether to bounce the data or not. This will be > > > useful later to allow for different pools. > > > > > > Signed-off-by: Claire Chang > > > Reviewed-by: Christoph Hellwig > > > Tested-by: Stefano Stabellini > &

Re: [PATCH v15 00/12] Restricted DMA

2021-06-25 Thread Will Deacon
On Thu, Jun 24, 2021 at 03:19:48PM -0400, Konrad Rzeszutek Wilk wrote: > On Thu, Jun 24, 2021 at 11:55:14PM +0800, Claire Chang wrote: > > This series implements mitigations for lack of DMA access control on > > systems without an IOMMU, which could result in the DMA accessing the > > system memory

Re: [PATCH v14 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-06-24 Thread Will Deacon
On Thu, Jun 24, 2021 at 12:34:09PM +0100, Robin Murphy wrote: > On 2021-06-24 12:18, Will Deacon wrote: > > On Thu, Jun 24, 2021 at 12:14:39PM +0100, Robin Murphy wrote: > > > On 2021-06-24 07:05, Claire Chang wrote: > > > > On Thu, Jun 24, 2021 at 1:

Re: [PATCH v14 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-06-24 Thread Will Deacon
On Thu, Jun 24, 2021 at 12:14:39PM +0100, Robin Murphy wrote: > On 2021-06-24 07:05, Claire Chang wrote: > > On Thu, Jun 24, 2021 at 1:43 PM Christoph Hellwig wrote: > > > > > > On Wed, Jun 23, 2021 at 02:44:34PM -0400, Qian Cai wrote: > > > > is_swiotlb_force_bounce at > > > > /usr/src/linux-ne

Re: [PATCH v14 06/12] swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing

2021-06-23 Thread Will Deacon
l later to allow for different pools. > > > > Signed-off-by: Claire Chang > > Reviewed-by: Christoph Hellwig > > Tested-by: Stefano Stabellini > > Tested-by: Will Deacon > > Acked-by: Stefano Stabellini > > Reverting the rest of the series up to this pa

Re: [PATCH v12 00/12] Restricted DMA

2021-06-16 Thread Will Deacon
re/arm-trusted-firmware/blob/master/plat/mediatek/mt8183/drivers/emi_mpu/emi_mpu.c#L132 > > v12: > Split is_dev_swiotlb_force into is_swiotlb_force_bounce (patch 06/12) and > is_swiotlb_for_alloc (patch 09/12) I took this for a spin in an arm64 KVM guest with virtio devices using the D

Re: [PATCH 8/8] membarrier: Rewrite sync_core_before_usermode() and improve documentation

2021-06-16 Thread Will Deacon
lly like "flushing the pipeline", but the SDM > does not permit LFENCE as an alternative to a "serializing instruction" > for this purpose.) > > Cc: Michael Ellerman > Cc: Benjamin Herrenschmidt > Cc: Paul Mackerras > Cc: linuxppc-dev@lists.ozlabs.org >

Re: [PATCH v8 00/15] Restricted DMA

2021-06-04 Thread Will Deacon
b_device_init and move it to > rmem_swiotlb_setup. > - Fix the message string in rmem_swiotlb_setup. Thanks for the v8. It works for me out of the box on arm64 under KVM, so: Tested-by: Will Deacon Note that something seems to have gone wrong with the mail threading, so the last 5 patches ended up as a separate thread for me. Probably worth posting again with all the patches in one place, if you can. Cheers, Will

Re: [PATCH v7 14/15] dt-bindings: of: Add restricted DMA pool

2021-05-27 Thread Will Deacon
On Thu, May 27, 2021 at 08:48:59PM +0800, Claire Chang wrote: > On Thu, May 27, 2021 at 7:35 PM Will Deacon wrote: > > > > On Thu, May 27, 2021 at 07:29:20PM +0800, Claire Chang wrote: > > > On Wed, May 26, 2021 at 11:53 PM Will Deacon wrote: > > > > > &

Re: [PATCH v7 14/15] dt-bindings: of: Add restricted DMA pool

2021-05-27 Thread Will Deacon
On Thu, May 27, 2021 at 07:29:20PM +0800, Claire Chang wrote: > On Wed, May 26, 2021 at 11:53 PM Will Deacon wrote: > > > > On Wed, May 26, 2021 at 01:13:22PM +0100, Will Deacon wrote: > > > On Tue, May 18, 2021 at 02:42:14PM +0800, Claire Chang wrote: > > &

Re: [PATCH v7 14/15] dt-bindings: of: Add restricted DMA pool

2021-05-26 Thread Will Deacon
On Wed, May 26, 2021 at 01:13:22PM +0100, Will Deacon wrote: > On Tue, May 18, 2021 at 02:42:14PM +0800, Claire Chang wrote: > > @@ -138,4 +160,9 @@ one for multimedia processing (named > > multimedia-memory@7700, 64MiB). > > memory-region =

Re: [PATCH v7 14/15] dt-bindings: of: Add restricted DMA pool

2021-05-26 Thread Will Deacon
Hi Claire, On Tue, May 18, 2021 at 02:42:14PM +0800, Claire Chang wrote: > Introduce the new compatible string, restricted-dma-pool, for restricted > DMA. One can specify the address and length of the restricted DMA memory > region by restricted-dma-pool in the reserved-memory node. > > Signed-of

Re: [PATCH 16/18] iommu: remove DOMAIN_ATTR_DMA_USE_FLUSH_QUEUE

2021-04-01 Thread Will Deacon
On Thu, Apr 01, 2021 at 11:59:45AM +0200, Christoph Hellwig wrote: > For now I'll just pass the iommu_domain to iommu_get_dma_strict, > so that we can check for it. We can do additional cleanups on top > of that later. Sounds good to me, cheers! Will

Re: [PATCH 16/18] iommu: remove DOMAIN_ATTR_DMA_USE_FLUSH_QUEUE

2021-03-31 Thread Will Deacon
On Wed, Mar 31, 2021 at 02:09:37PM +0100, Robin Murphy wrote: > On 2021-03-31 12:49, Will Deacon wrote: > > On Tue, Mar 30, 2021 at 05:28:19PM +0100, Robin Murphy wrote: > > > On 2021-03-30 14:58, Will Deacon wrote: > > > > On Tue, Mar 30, 2021 at 02:19:38PM +0100, Ro

Re: [PATCH v2 3/7] powerpc: convert config files to generic cmdline

2021-03-31 Thread Will Deacon
On Tue, Mar 30, 2021 at 10:35:21AM -0700, Daniel Walker wrote: > On Mon, Mar 29, 2021 at 11:07:51AM +0100, Will Deacon wrote: > > On Thu, Mar 25, 2021 at 12:59:56PM -0700, Daniel Walker wrote: > > > On Thu, Mar 25, 2021 at 01:03:55PM +0100, Christophe Leroy wrote: > > >

Re: [PATCH 16/18] iommu: remove DOMAIN_ATTR_DMA_USE_FLUSH_QUEUE

2021-03-31 Thread Will Deacon
On Tue, Mar 30, 2021 at 05:28:19PM +0100, Robin Murphy wrote: > On 2021-03-30 14:58, Will Deacon wrote: > > On Tue, Mar 30, 2021 at 02:19:38PM +0100, Robin Murphy wrote: > > > On 2021-03-30 14:11, Will Deacon wrote: > > > > On Tue, Mar 16, 2021 at 04:38:22PM

Re: [PATCH 16/18] iommu: remove DOMAIN_ATTR_DMA_USE_FLUSH_QUEUE

2021-03-30 Thread Will Deacon
On Tue, Mar 30, 2021 at 02:19:38PM +0100, Robin Murphy wrote: > On 2021-03-30 14:11, Will Deacon wrote: > > On Tue, Mar 16, 2021 at 04:38:22PM +0100, Christoph Hellwig wrote: > > > From: Robin Murphy > > > > > > Instead make the global iommu_dma_str

Re: [PATCH 18/18] iommu: remove iommu_domain_{get,set}_attr

2021-03-30 Thread Will Deacon
--- > 2 files changed, 62 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH 17/18] iommu: remove DOMAIN_ATTR_IO_PGTABLE_CFG

2021-03-30 Thread Will Deacon
| 12 - > 6 files changed, 35 insertions(+), 63 deletions(-) I'm fine with this for now, although there has been talk about passing things other than boolean flags as page-table quirks. We can cross that bridge when we get there, so: Acked-by: Will Deacon Will

Re: [PATCH 16/18] iommu: remove DOMAIN_ATTR_DMA_USE_FLUSH_QUEUE

2021-03-30 Thread Will Deacon
On Tue, Mar 16, 2021 at 04:38:22PM +0100, Christoph Hellwig wrote: > From: Robin Murphy > > Instead make the global iommu_dma_strict paramete in iommu.c canonical by > exporting helpers to get and set it and use those directly in the drivers. > > This make sure that the iommu.strict parameter al

Re: [PATCH 15/18] iommu: remove iommu_set_cmd_line_dma_api and iommu_cmd_line_dma_api

2021-03-30 Thread Will Deacon
On Tue, Mar 16, 2021 at 04:38:21PM +0100, Christoph Hellwig wrote: > Don't obsfucate the trivial bit flag check. > > Signed-off-by: Christoph Hellwig > --- > drivers/iommu/iommu.c | 23 +-- > 1 file changed, 5 insertions(+), 18 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH 14/18] iommu: remove DOMAIN_ATTR_NESTING

2021-03-30 Thread Will Deacon
> 6 files changed, 55 insertions(+), 68 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH 13/18] iommu: remove DOMAIN_ATTR_GEOMETRY

2021-03-30 Thread Will Deacon
- > drivers/vfio/vfio_iommu_type1.c | 26 -- > drivers/vhost/vdpa.c| 10 +++--- > include/linux/iommu.h | 1 - > 4 files changed, 18 insertions(+), 39 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH 12/18] iommu: remove DOMAIN_ATTR_PAGING

2021-03-30 Thread Will Deacon
On Tue, Mar 16, 2021 at 04:38:18PM +0100, Christoph Hellwig wrote: > DOMAIN_ATTR_PAGING is never used. > > Signed-off-by: Christoph Hellwig > Acked-by: Li Yang > --- > drivers/iommu/iommu.c | 5 - > include/linux/iommu.h | 1 - > 2 files changed, 6 deletions(-

Re: [PATCH 11/18] iommu/fsl_pamu: remove the snoop_id field

2021-03-30 Thread Will Deacon
nged, 2 insertions(+), 4 deletions(-) pamu_config_ppaace() takes quite a few useless parameters at this stage, but anyway: Acked-by: Will Deacon Do you know if this driver is actually useful? Once the complexity has been stripped back, the stubs and default values really stand out. Will

Re: [PATCH 10/18] iommu/fsl_pamu: enable the liodn when attaching a device

2021-03-30 Thread Will Deacon
sl/qbman/qman_portal.c | 11 --- > include/linux/iommu.h | 1 - > 4 files changed, 3 insertions(+), 66 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH 09/18] iommu/fsl_pamu: merge handle_attach_device into fsl_pamu_attach_device

2021-03-30 Thread Will Deacon
; 1 file changed, 20 insertions(+), 39 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH 08/18] iommu/fsl_pamu: merge pamu_set_liodn and map_liodn

2021-03-30 Thread Will Deacon
On Tue, Mar 16, 2021 at 04:38:14PM +0100, Christoph Hellwig wrote: > Merge the two fuctions that configure the ppaace into a single coherent > function. I somehow doubt we need the two pamu_config_ppaace calls, > but keep the existing behavior just to be on the safe side. > > Signed-off-by: Chris

Re: [PATCH 07/18] iommu/fsl_pamu: replace DOMAIN_ATTR_FSL_PAMU_STASH with a direct call

2021-03-30 Thread Will Deacon
> 5 files changed, 9 insertions(+), 40 deletions(-) Heh, this thing is so over-engineered. Acked-by: Will Deacon Will

Re: [PATCH 06/18] iommu/fsl_pamu: remove ->domain_window_enable

2021-03-30 Thread Will Deacon
On Tue, Mar 16, 2021 at 04:38:12PM +0100, Christoph Hellwig wrote: > The only thing that fsl_pamu_window_enable does for the current caller > is to fill in the prot value in the only dma_window structure, and to > propagate a few values from the iommu_domain_geometry struture into the > dma_window.

Re: [PATCH 05/18] iommu/fsl_pamu: remove support for multiple windows

2021-03-30 Thread Will Deacon
stale ^^ > - struct dma_window *win_arr; > + struct dma_window win_arr[1]; > /* list of devices associated with the domain */ > struct list_headdevices; > /* dma_domain states: Acked-by: Will Deacon Will

Re: [PATCH 04/18] iommu/fsl_pamu: merge iommu_alloc_dma_domain into fsl_pamu_domain_alloc

2021-03-30 Thread Will Deacon
hanged, 10 insertions(+), 24 deletions(-) Acked-by: Will Deacon Will

Re: [PATCH 03/18] iommu/fsl_pamu: remove support for setting DOMAIN_ATTR_GEOMETRY

2021-03-30 Thread Will Deacon
changed, 5 insertions(+), 68 deletions(-) Took me a minute to track down the other magic '36' which ends up in aperture_end, but I found it eventually so: Acked-by: Will Deacon (It does make me wonder what all this glue was intended to be used for) Will

  1   2   3   4   >