Re: Issues with the first PowerPC updates for the kernel 6.1

2022-10-30 Thread Christian Zigotzky
On 29 October 2022 at 5:33 pm, Segher Boessenkool wrote: On Mon, Oct 17, 2022 at 09:53:04AM +0200, Christian Zigotzky wrote: On 17. Oct 2022, at 02:43, Michael Ellerman wrote: Previously BIG_ENDIAN && GENERIC_CPU would use -mcpu=power5, now it uses -mcpu=power4. Maybe this is the issue. We

Re: Issues with the first PowerPC updates for the kernel 6.1

2022-10-30 Thread Christian Zigotzky
On 29 October 2022 at 01:44 pm, Christian Zigotzky wrote: On 17 October 2022 at 09:53 am, Christian Zigotzky wrote: On 17. Oct 2022, at 02:43, Michael Ellerman wrote: Previously BIG_ENDIAN && GENERIC_CPU would use -mcpu=power5, now it uses -mcpu=power4. Maybe this is the issue. We will wait

Re: Issues with the first PowerPC updates for the kernel 6.1 #forregzbot

2022-10-30 Thread Thorsten Leemhuis
[Note: this mail is primarily send for documentation purposes and/or for regzbot, my Linux kernel regression tracking bot. That's why I removed most or all folks from the list of recipients, but left any that looked like a mailing lists. These mails usually contain '#forregzbot' in the subject, to

Re: [PATCH v6 21/25] powerpc: Provide syscall wrapper

2022-10-30 Thread Andreas Schwab
This breaks powerpc32. The fallocate syscall misinterprets its arguments. -- Andreas Schwab, sch...@linux-m68k.org GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1 "And now for something completely different."

Re: [PATCH v6 21/25] powerpc: Provide syscall wrapper

2022-10-30 Thread Andreas Schwab
It probably breaks every syscall with a 64-bit argument. -- Andreas Schwab, sch...@linux-m68k.org GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1 "And now for something completely different."

Re: [PATCH 1/2] powerpc/32: fix syscall wrappers with 64-bit arguments of unaligned register-pairs

2022-10-30 Thread Andreas Schwab
On Okt 12 2022, Nicholas Piggin wrote: > diff --git a/arch/powerpc/kernel/syscalls/syscall.tbl > b/arch/powerpc/kernel/syscalls/syscall.tbl > index 2bca64f96164..e9e0df4f9a61 100644 > --- a/arch/powerpc/kernel/syscalls/syscall.tbl > +++ b/arch/powerpc/kernel/syscalls/syscall.tbl > @@ -228,8

Re: [PATCH v4] hugetlb: simplify hugetlb handling in follow_page_mask

2022-10-30 Thread Peter Xu
On Fri, Oct 28, 2022 at 11:11:08AM -0700, Mike Kravetz wrote: > +struct page *hugetlb_follow_page_mask(struct vm_area_struct *vma, > + unsigned long address, unsigned int flags) > +{ > + struct hstate *h = hstate_vma(vma); > + struct mm_struct *mm = vma->vm_mm;

[PATCH v5] hugetlb: simplify hugetlb handling in follow_page_mask

2022-10-30 Thread Mike Kravetz
During discussions of this series [1], it was suggested that hugetlb handling code in follow_page_mask could be simplified. At the beginning of follow_page_mask, there currently is a call to follow_huge_addr which 'may' handle hugetlb pages. ia64 is the only architecture which provides a

Re: [PATCH v6 21/25] powerpc: Provide syscall wrapper

2022-10-30 Thread Andreas Schwab
On Okt 30 2022, Arnd Bergmann wrote: > On Sun, Oct 30, 2022, at 16:34, Andreas Schwab wrote: >> This breaks powerpc32. The fallocate syscall misinterprets its >> arguments. > > It was fixed in Nope. -- Andreas Schwab, sch...@linux-m68k.org GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552

Re: [PATCH v6 21/25] powerpc: Provide syscall wrapper

2022-10-30 Thread Arnd Bergmann
On Sun, Oct 30, 2022, at 16:34, Andreas Schwab wrote: > This breaks powerpc32. The fallocate syscall misinterprets its > arguments. It was fixed in https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e237506238352f3bfa9cf3983cdab873e35651eb Arnd

Re: [PATCH v4] hugetlb: simplify hugetlb handling in follow_page_mask

2022-10-30 Thread Mike Kravetz
On 10/30/22 15:45, Peter Xu wrote: > On Fri, Oct 28, 2022 at 11:11:08AM -0700, Mike Kravetz wrote: > > + } else { > > + if (is_hugetlb_entry_migration(entry)) { > > + spin_unlock(ptl); > > + hugetlb_vma_unlock_read(vma); > > Just noticed it when

Re: [PATCH v6 21/25] powerpc: Provide syscall wrapper

2022-10-30 Thread Michael Ellerman
Andreas Schwab writes: > On Okt 30 2022, Arnd Bergmann wrote: > >> On Sun, Oct 30, 2022, at 16:34, Andreas Schwab wrote: >>> This breaks powerpc32. The fallocate syscall misinterprets its >>> arguments. >> >> It was fixed in > > Nope. Ack.

Re: [PATCH v2 -next] powerpc/powermac: Fix symbol not declared warnings

2022-10-30 Thread chenlifu
在 2022/8/19 21:06, Chen Lifu 写道: 1. ppc_override_l2cr and ppc_override_l2cr_value are only used in l2cr_init() function, remove them and used *l2cr directly. 2. has_l2cache is not used outside of the file, so mark it static and do not initialise statics to 0. Fixes the following

[RFC PATCH 00/19] Remove STACK_FRAME_OVERHEAD

2022-10-30 Thread Nicholas Piggin
This is some quick hacking, hardly tested but might have potential. I think we're not validating the perf kernel stack walker bounds quite correctly, and not setting up decent stack frames for the child in copy_thread. So at least those two things we could do. Maybe patch 1 should go upstream as

[RFC PATCH 01/19] powerpc/perf: callchain validate kernel stack pointer bounds

2022-10-30 Thread Nicholas Piggin
The interrupt frame detection and loads from the hypothetical pt_regs are not bounds-checked. The next-frame validation only bounds-checks STACK_FRAME_OVERHEAD, which does not include the pt_regs. Add another test for this. Signed-off-by: Nicholas Piggin --- Could the user set r1 to be equal to

[RFC PATCH 02/19] powerpc: Rearrange copy_thread child stack creation

2022-10-30 Thread Nicholas Piggin
This makes it a bit clearer where the stack frame is created, and will allow easier use of some of the stack offset constants in a later change. Signed-off-by: Nicholas Piggin --- arch/powerpc/kernel/process.c | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git

[RFC PATCH 04/19] powerpc/pseries: hvcall stack frame overhead

2022-10-30 Thread Nicholas Piggin
This call may use the min size stack frame. The scratch space used is in the caller's parameter area frame, not this function's frame. Signed-off-by: Nicholas Piggin --- arch/powerpc/platforms/pseries/hvCall.S | 38 + 1 file changed, 20 insertions(+), 18 deletions(-)

[RFC PATCH 03/19] powerpc/64: Remove asm interrupt tracing call helpers

2022-10-30 Thread Nicholas Piggin
These are unused. Remove. Signed-off-by: Nicholas Piggin --- arch/powerpc/include/asm/irqflags.h | 29 - 1 file changed, 29 deletions(-) diff --git a/arch/powerpc/include/asm/irqflags.h b/arch/powerpc/include/asm/irqflags.h index 1a6c1ce17735..81e0a5025be8 100644

[RFC PATCH 05/19] powerpc/32: Use load and store multiple in GPR save/restore macros

2022-10-30 Thread Nicholas Piggin
--- arch/powerpc/include/asm/ppc_asm.h | 18 -- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/include/asm/ppc_asm.h b/arch/powerpc/include/asm/ppc_asm.h index 753a2757bcd4..ac44383d350a 100644 --- a/arch/powerpc/include/asm/ppc_asm.h +++