Re: [PATCH 11/27] m68k: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Geert Uytterhoeven
On Thu, Jan 28, 2021 at 1:54 AM Masahiro Yamada wrote: > The rules in this Makefile cannot detect the command line change because > the prerequisite 'FORCE' is missing. > > Adding 'FORCE' will result in the headers being rebuilt every time > because the 'targets' addition is also wrong; the file

Re: [PATCH 2/3] kbuild: LD_VERSION redenomination

2021-01-27 Thread Masahiro Yamada
On Sun, Dec 13, 2020 at 1:54 AM Masahiro Yamada wrote: > > Commit ccbef1674a15 ("Kbuild, lto: add ld-version and ld-ifversion > macros") introduced scripts/ld-version.sh for GCC LTO. > > At that time, this script handled 5 version fields because GCC LTO > needed the downstream binutils.

Re: [PATCH] powerpc64: Workaround sigtramp vdso return call.

2021-01-27 Thread Nicholas Piggin
+linuxppc-dev Excerpts from Raoni Fassina Firmino's message of January 28, 2021 2:21 am: > On Tue, Jan 26, 2021 at 08:45:00AM -0600, AL glibc-alpha wrote: >> >> >> On 1/26/21 8:12 AM, Florian Weimer via Libc-alpha wrote: >> > * Raoni Fassina Firmino: >> > >> > > A not so recent kernel

Re: [PATCH v15 09/10] arm64: Call kmalloc() to allocate DTB buffer

2021-01-27 Thread Joe Perches
On Thu, 2021-01-28 at 00:52 -0300, Thiago Jung Bauermann wrote: > The problem is that this patch implements only part of the suggestion, > which isn't useful in itself. So the patch series should either drop > this patch or consolidate the FDT allocation between the arches. > > I just tested on

Re: [PATCH v15 09/10] arm64: Call kmalloc() to allocate DTB buffer

2021-01-27 Thread Lakshmi Ramasubramanian
On 1/27/21 8:14 PM, Thiago Jung Bauermann wrote: Lakshmi Ramasubramanian writes: On 1/27/21 7:52 PM, Thiago Jung Bauermann wrote: Will Deacon writes: On Wed, Jan 27, 2021 at 09:59:38AM -0800, Lakshmi Ramasubramanian wrote: On 1/27/21 8:52 AM, Will Deacon wrote: Hi Will, On Fri, Jan

Re: [PATCH v15 09/10] arm64: Call kmalloc() to allocate DTB buffer

2021-01-27 Thread Thiago Jung Bauermann
Lakshmi Ramasubramanian writes: > On 1/27/21 7:52 PM, Thiago Jung Bauermann wrote: >> Will Deacon writes: >> >>> On Wed, Jan 27, 2021 at 09:59:38AM -0800, Lakshmi Ramasubramanian wrote: On 1/27/21 8:52 AM, Will Deacon wrote: Hi Will, > On Fri, Jan 15, 2021 at

Re: [PATCH 1/2] PCI/AER: Disable AER interrupt during suspend

2021-01-27 Thread Kai-Heng Feng
On Thu, Jan 28, 2021 at 4:51 AM Bjorn Helgaas wrote: > > On Thu, Jan 28, 2021 at 01:31:00AM +0800, Kai-Heng Feng wrote: > > Commit 50310600ebda ("iommu/vt-d: Enable PCI ACS for platform opt in > > hint") enables ACS, and some platforms lose its NVMe after resume from > > firmware: > > [

Re: [PATCH v15 10/10] arm64: Add IMA log information in kimage used for kexec

2021-01-27 Thread Lakshmi Ramasubramanian
On 1/27/21 3:13 PM, Will Deacon wrote: On Wed, Jan 27, 2021 at 01:31:02PM -0500, Mimi Zohar wrote: On Wed, 2021-01-27 at 10:24 -0800, Lakshmi Ramasubramanian wrote: On 1/27/21 10:02 AM, Will Deacon wrote: On Wed, Jan 27, 2021 at 09:56:53AM -0800, Lakshmi Ramasubramanian wrote: On 1/27/21

[PATCH v4 07/10] powerpc/signal64: Replace restore_sigcontext() w/ unsafe_restore_sigcontext()

2021-01-27 Thread Christopher M. Riedl
Previously restore_sigcontext() performed a costly KUAP switch on every uaccess operation. These repeated uaccess switches cause a significant drop in signal handling performance. Rewrite restore_sigcontext() to assume that a userspace read access window is open. Replace all uaccess functions

[PATCH v4 03/10] powerpc/signal64: Move non-inline functions out of setup_sigcontext()

2021-01-27 Thread Christopher M. Riedl
There are non-inline functions which get called in setup_sigcontext() to save register state to the thread struct. Move these functions into a separate prepare_setup_sigcontext() function so that setup_sigcontext() can be refactored later into an "unsafe" version which assumes an open uaccess

[PATCH v4 08/10] powerpc/signal64: Rewrite handle_rt_signal64() to minimise uaccess switches

2021-01-27 Thread Christopher M. Riedl
From: Daniel Axtens Add uaccess blocks and use the 'unsafe' versions of functions doing user access where possible to reduce the number of times uaccess has to be opened/closed. There is no 'unsafe' version of copy_siginfo_to_user, so move it slightly to allow for a "longer" uaccess block.

[PATCH v4 06/10] powerpc/signal64: Replace setup_sigcontext() w/ unsafe_setup_sigcontext()

2021-01-27 Thread Christopher M. Riedl
Previously setup_sigcontext() performed a costly KUAP switch on every uaccess operation. These repeated uaccess switches cause a significant drop in signal handling performance. Rewrite setup_sigcontext() to assume that a userspace write access window is open. Replace all uaccess functions with

[PATCH v4 05/10] powerpc/signal64: Remove TM ifdefery in middle of if/else block

2021-01-27 Thread Christopher M. Riedl
Rework the messy ifdef breaking up the if-else for TM similar to commit f1cf4f93de2f ("powerpc/signal32: Remove ifdefery in middle of if/else"). Unlike that commit for ppc32, the ifdef can't be removed entirely since uc_transact in sigframe depends on CONFIG_PPC_TRANSACTIONAL_MEM. Signed-off-by:

[PATCH v4 00/10] Improve signal performance on PPC64 with KUAP

2021-01-27 Thread Christopher M. Riedl
As reported by Anton, there is a large penalty to signal handling performance on radix systems using KUAP. The signal handling code performs many user access operations, each of which needs to switch the KUAP permissions bit to open and then close user access. This involves a costly 'mtspr'

[PATCH v4 01/10] powerpc/uaccess: Add unsafe_copy_from_user

2021-01-27 Thread Christopher M. Riedl
Just wrap __copy_tofrom_user() for the usual 'unsafe' pattern which takes in a label to goto on error. Signed-off-by: Christopher M. Riedl --- arch/powerpc/include/asm/uaccess.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/powerpc/include/asm/uaccess.h

[PATCH v4 02/10] powerpc/signal: Add unsafe_copy_{vsx, fpr}_from_user()

2021-01-27 Thread Christopher M. Riedl
Reuse the "safe" implementation from signal.c except for calling unsafe_copy_from_user() to copy into a local buffer. Signed-off-by: Christopher M. Riedl --- arch/powerpc/kernel/signal.h | 33 + 1 file changed, 33 insertions(+) diff --git

[PATCH v4 09/10] powerpc/signal64: Rewrite rt_sigreturn() to minimise uaccess switches

2021-01-27 Thread Christopher M. Riedl
From: Daniel Axtens Add uaccess blocks and use the 'unsafe' versions of functions doing user access where possible to reduce the number of times uaccess has to be opened/closed. Signed-off-by: Daniel Axtens Co-developed-by: Christopher M. Riedl Signed-off-by: Christopher M. Riedl ---

[PATCH v4 04/10] powerpc: Reference param in MSR_TM_ACTIVE() macro

2021-01-27 Thread Christopher M. Riedl
Unlike the other MSR_TM_* macros, MSR_TM_ACTIVE does not reference or use its parameter unless CONFIG_PPC_TRANSACTIONAL_MEM is defined. This causes an 'unused variable' compile warning unless the variable is also guarded with CONFIG_PPC_TRANSACTIONAL_MEM. Reference but do nothing with the

[PATCH v4 10/10] powerpc/signal64: Use __get_user() to copy sigset_t

2021-01-27 Thread Christopher M. Riedl
Usually sigset_t is exactly 8B which is a "trivial" size and does not warrant using __copy_from_user(). Use __get_user() directly in anticipation of future work to remove the trivial size optimizations from __copy_from_user(). Calling __get_user() also results in a small boost to signal handling

Re: [PATCH 2/2] powerpc/vdso64: remove meaningless vgettimeofday.o build rule

2021-01-27 Thread Masahiro Yamada
On Thu, Dec 24, 2020 at 2:12 AM Masahiro Yamada wrote: > > VDSO64 is only built for the 64-bit kernel, hence vgettimeofday.o is > built by the generic rule in scripts/Makefile.build. > > This line does not provide anything useful. > > Signed-off-by: Masahiro Yamada Michael, please take a look

Re: [PATCH 1/2] powerpc/vdso: fix unnecessary rebuilds of vgettimeofday.o

2021-01-27 Thread Masahiro Yamada
On Thu, Dec 24, 2020 at 2:12 AM Masahiro Yamada wrote: > > vgettimeofday.o is unnecessarily rebuilt. Adding it to 'targets' is not > enough to fix the issue. Kbuild is correctly rebuilding it because the > command line is changed. > > PowerPC builds each vdso directory twice; first in

Re: [PATCH v15 09/10] arm64: Call kmalloc() to allocate DTB buffer

2021-01-27 Thread Lakshmi Ramasubramanian
On 1/27/21 7:52 PM, Thiago Jung Bauermann wrote: Will Deacon writes: On Wed, Jan 27, 2021 at 09:59:38AM -0800, Lakshmi Ramasubramanian wrote: On 1/27/21 8:52 AM, Will Deacon wrote: Hi Will, On Fri, Jan 15, 2021 at 09:30:16AM -0800, Lakshmi Ramasubramanian wrote: create_dtb() function

Re: [PATCH v15 09/10] arm64: Call kmalloc() to allocate DTB buffer

2021-01-27 Thread Thiago Jung Bauermann
Will Deacon writes: > On Wed, Jan 27, 2021 at 09:59:38AM -0800, Lakshmi Ramasubramanian wrote: >> On 1/27/21 8:52 AM, Will Deacon wrote: >> >> Hi Will, >> >> > On Fri, Jan 15, 2021 at 09:30:16AM -0800, Lakshmi Ramasubramanian wrote: >> > > create_dtb() function allocates kernel virtual

Re: [PATCH v11 01/13] mm/vmalloc: fix HUGE_VMAP regression by enabling huge pages in vmalloc_to_page

2021-01-27 Thread Ding Tianhong
On 2021/1/26 12:44, Nicholas Piggin wrote: > vmalloc_to_page returns NULL for addresses mapped by larger pages[*]. > Whether or not a vmap is huge depends on the architecture details, > alignments, boot options, etc., which the caller can not be expected > to know. Therefore HUGE_VMAP is a

Re: [PATCH] powerpc/fault: fix wrong KUAP fault for IO_URING

2021-01-27 Thread Jens Axboe
On 1/27/21 8:13 PM, Zorro Lang wrote: > On Thu, Jan 28, 2021 at 10:18:07AM +1000, Nicholas Piggin wrote: >> Excerpts from Jens Axboe's message of January 28, 2021 5:29 am: >>> On 1/27/21 9:38 AM, Christophe Leroy wrote: Le 27/01/2021 à 15:56, Zorro Lang a écrit : > On powerpc,

Re: [PATCH] powerpc/fault: fix wrong KUAP fault for IO_URING

2021-01-27 Thread Zorro Lang
On Thu, Jan 28, 2021 at 10:18:07AM +1000, Nicholas Piggin wrote: > Excerpts from Jens Axboe's message of January 28, 2021 5:29 am: > > On 1/27/21 9:38 AM, Christophe Leroy wrote: > >> > >> > >> Le 27/01/2021 à 15:56, Zorro Lang a écrit : > >>> On powerpc, io_uring test hit below KUAP fault on

Re: [PATCH v11 04/13] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-01-27 Thread Miaohe Lin
Hi: On 2021/1/26 12:45, Nicholas Piggin wrote: > This will be used as a generic kernel virtual mapping function, so > re-name it in preparation. > Looks good to me. Thanks. Reviewed-by: Miaohe Lin > Signed-off-by: Nicholas Piggin > --- > mm/ioremap.c | 64

Re: [PATCH 01/27] scripts: add generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
On Thu, Jan 28, 2021 at 9:51 AM Masahiro Yamada wrote: > > Most of architectures generate syscall headers at the compile time > in the almost same way. > > The syscall table has the same format for all architectures. Each line > has 3, 4 or 5 fields; syscall number, ABI, syscall name, native

Re: [PATCH 02/27] x86/syscalls: fix -Wmissing-prototypes warnings from COND_SYSCALL()

2021-01-27 Thread Masahiro Yamada
On Thu, Jan 28, 2021 at 9:52 AM Masahiro Yamada wrote: > > Building kernel/sys_ni.c with W=1 omits tons of -Wmissing-prototypes This is a typo. "omits" -> "emits" > warnings. > > $ make W=1 kernel/sys_ni.o > [ snip ] > CC kernel/sys_ni.o > In file included from kernel/sys_ni.c:10:

[PATCH 20/27] sh: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts sh to use scripts/syscalltbl.sh. Signed-off-by: Masahiro Yamada ---

[PATCH 16/27] mips: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts mips to use scripts/syscalltbl.sh. This also unifies syscall_table_32_o32.h and syscall_table_64_o32.h

[PATCH 15/27] mips: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 25/27] powerpc: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts powerpc to use scripts/syscalltbl.sh. Signed-off-by: Masahiro Yamada ---

[PATCH 22/27] sparc: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 26/27] xtensa: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 21/27] sparc: remove wrong comment from arch/sparc/include/asm/Kbuild

2021-01-27 Thread Masahiro Yamada
These are NOT exported to userspace. The headers listed in arch/sparc/include/uapi/asm/Kbuild are exported. Signed-off-by: Masahiro Yamada --- arch/sparc/include/asm/Kbuild | 2 -- 1 file changed, 2 deletions(-) diff --git a/arch/sparc/include/asm/Kbuild b/arch/sparc/include/asm/Kbuild index

[PATCH 19/27] sh: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 13/27] microblaze: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 24/27] powerpc: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 14/27] microblaze: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts microblaze to use scripts/syscalltbl.sh. Signed-off-by: Masahiro Yamada ---

[PATCH 11/27] m68k: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 18/27] parisc: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts parisc to use scripts/syscalltbl.sh. This also unifies syscall_table_64.h and syscall_table_c32.h.

[PATCH 12/27] m68k: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts m68k to use scripts/syscalltbl.sh. Signed-off-by: Masahiro Yamada ---

[PATCH 17/27] parisc: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 10/27] ia64: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts ia64 to use scripts/syscalltbl.sh. Signed-off-by: Masahiro Yamada --- arch/ia64/kernel/entry.S

[PATCH 27/27] xtensa: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts xtensa to use scripts/syscalltbl.sh. Signed-off-by: Masahiro Yamada ---

[PATCH 08/27] alpha: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts alpha to use scripts/syscalltbl.sh. Signed-off-by: Masahiro Yamada ---

[PATCH 23/27] sparc: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts sparc to use scripts/syscalltbl.sh. This also unifies syscall_table_64.h and syscall_table_c32.h.

[PATCH 09/27] ia64: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 07/27] alpha: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 03/27] x86/build: add missing FORCE and fix 'targets' to make if_changed work

2021-01-27 Thread Masahiro Yamada
The rules in this Makefile cannot detect the command line change because the prerequisite 'FORCE' is missing. Adding 'FORCE' will result in the headers being rebuilt every time because the 'targets' addition is also wrong; the file paths in 'targets' must be relative to the current Makefile. Fix

[PATCH 02/27] x86/syscalls: fix -Wmissing-prototypes warnings from COND_SYSCALL()

2021-01-27 Thread Masahiro Yamada
Building kernel/sys_ni.c with W=1 omits tons of -Wmissing-prototypes warnings. $ make W=1 kernel/sys_ni.o [ snip ] CC kernel/sys_ni.o In file included from kernel/sys_ni.c:10: ./arch/x86/include/asm/syscall_wrapper.h:83:14: warning: no previous prototype for '__x64_sys_io_setup'

[PATCH 06/27] ARM: syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts ARM to use scripts/syscalltbl.sh. Signed-off-by: Masahiro Yamada ---

[PATCH 05/27] x86/syscalls: switch to generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts in order to generate syscall table headers. My goal is to unify them into the single scripts/syscalltbl.sh. This commit converts x86 and UML to use scripts/syscalltbl.sh. Currently, syscall_64.h mixes up x86_64 and x32 syscalls.

[PATCH 04/27] x86/entry/x32: rename __x32_compat_sys_* to __x64_compat_sys_*

2021-01-27 Thread Masahiro Yamada
In arch/x86/entry/syscall_x32.c, the macros are mapped to symbols as follows: __SYSCALL_COMMON(nr, sym) --> __x64_ __SYSCALL_X32(nr, sym) --> __x32_ Originally, the syscalls in the x32 special range (512-547) were all compat. This assumption is now broken after the following commits:

[PATCH 00/27] arch: syscalls: unifiy all syscalltbl.sh into scripts/syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
As of v5.11-rc1, 12 architectures duplicate similar shell scripts: $ find arch -name syscalltbl.sh | sort arch/alpha/kernel/syscalls/syscalltbl.sh arch/arm/tools/syscalltbl.sh arch/ia64/kernel/syscalls/syscalltbl.sh arch/m68k/kernel/syscalls/syscalltbl.sh

[PATCH 01/27] scripts: add generic syscalltbl.sh

2021-01-27 Thread Masahiro Yamada
Most of architectures generate syscall headers at the compile time in the almost same way. The syscall table has the same format for all architectures. Each line has 3, 4 or 5 fields; syscall number, ABI, syscall name, native entry point, and compat entry point. The syscall table is processed by

Re: [PATCH] powerpc/fault: fix wrong KUAP fault for IO_URING

2021-01-27 Thread Nicholas Piggin
Excerpts from Jens Axboe's message of January 28, 2021 5:29 am: > On 1/27/21 9:38 AM, Christophe Leroy wrote: >> >> >> Le 27/01/2021 à 15:56, Zorro Lang a écrit : >>> On powerpc, io_uring test hit below KUAP fault on __do_page_fault. >>> The fail source line is: >>> >>>if (unlikely(!is_user

Re: [PATCH v3 28/32] powerpc/64s: interrupt implement exit logic in C

2021-01-27 Thread Nicholas Piggin
Excerpts from Christophe Leroy's message of January 27, 2021 6:54 pm: > > > Le 25/02/2020 à 18:35, Nicholas Piggin a écrit : >> Implement the bulk of interrupt return logic in C. The asm return code >> must handle a few cases: restoring full GPRs, and emulating stack store. >> >> The stack

Re: [PATCH v6 05/39] powerpc: remove arguments from fault handler functions

2021-01-27 Thread Nicholas Piggin
Excerpts from Christophe Leroy's message of January 27, 2021 4:38 pm: > > > Le 15/01/2021 à 17:49, Nicholas Piggin a écrit : >> Make mm fault handlers all just take the pt_regs * argument and load >> DAR/DSISR from that. Make those that return a value return long. >> >> This is done to make the

RE: [PATCH v4 11/23] powerpc/syscall: Rename syscall_64.c into syscall.c

2021-01-27 Thread Nicholas Piggin
Excerpts from David Laight's message of January 26, 2021 8:28 pm: > From: Nicholas Piggin >> Sent: 26 January 2021 10:21 >> >> Excerpts from Christophe Leroy's message of January 26, 2021 12:48 am: >> > syscall_64.c will be reused almost as is for PPC32. >> > >> > Rename it syscall.c >> >> Could

Re: [PATCH v15 10/10] arm64: Add IMA log information in kimage used for kexec

2021-01-27 Thread Will Deacon
On Wed, Jan 27, 2021 at 01:31:02PM -0500, Mimi Zohar wrote: > On Wed, 2021-01-27 at 10:24 -0800, Lakshmi Ramasubramanian wrote: > > On 1/27/21 10:02 AM, Will Deacon wrote: > > > On Wed, Jan 27, 2021 at 09:56:53AM -0800, Lakshmi Ramasubramanian wrote: > > >> On 1/27/21 8:54 AM, Will Deacon wrote: >

[PATCH] vio: make remove callback return void

2021-01-27 Thread Uwe Kleine-König
The driver core ignores the return value of struct bus_type::remove() because there is only little that can be done. To simplify the quest to make this function return void, let struct vio_driver::remove() return void, too. All users already unconditionally return 0, this commit makes it obvious

Re: [PATCH 1/2] PCI/AER: Disable AER interrupt during suspend

2021-01-27 Thread Bjorn Helgaas
On Thu, Jan 28, 2021 at 01:31:00AM +0800, Kai-Heng Feng wrote: > Commit 50310600ebda ("iommu/vt-d: Enable PCI ACS for platform opt in > hint") enables ACS, and some platforms lose its NVMe after resume from > firmware: > [ 50.947816] pcieport :00:1b.0: DPC: containment event, status:0x1f01

[PATCH 2/2] PCI/DPC: Disable DPC interrupt during suspend

2021-01-27 Thread Kai-Heng Feng
Commit 50310600ebda ("iommu/vt-d: Enable PCI ACS for platform opt in hint") enables ACS, and some platforms lose its NVMe after resume from firmware: [ 50.947816] pcieport :00:1b.0: DPC: containment event, status:0x1f01 source:0x [ 50.947817] pcieport :00:1b.0: DPC: unmasked

[PATCH 1/2] PCI/AER: Disable AER interrupt during suspend

2021-01-27 Thread Kai-Heng Feng
Commit 50310600ebda ("iommu/vt-d: Enable PCI ACS for platform opt in hint") enables ACS, and some platforms lose its NVMe after resume from firmware: [ 50.947816] pcieport :00:1b.0: DPC: containment event, status:0x1f01 source:0x [ 50.947817] pcieport :00:1b.0: DPC: unmasked

Re: [PATCH] powerpc/fault: fix wrong KUAP fault for IO_URING

2021-01-27 Thread Jens Axboe
On 1/27/21 9:38 AM, Christophe Leroy wrote: > > > Le 27/01/2021 à 15:56, Zorro Lang a écrit : >> On powerpc, io_uring test hit below KUAP fault on __do_page_fault. >> The fail source line is: >> >>if (unlikely(!is_user && bad_kernel_fault(regs, error_code, address, >> is_write))) >>

Re: [PATCH v15 09/10] arm64: Call kmalloc() to allocate DTB buffer

2021-01-27 Thread Will Deacon
On Wed, Jan 27, 2021 at 09:59:38AM -0800, Lakshmi Ramasubramanian wrote: > On 1/27/21 8:52 AM, Will Deacon wrote: > > Hi Will, > > > On Fri, Jan 15, 2021 at 09:30:16AM -0800, Lakshmi Ramasubramanian wrote: > > > create_dtb() function allocates kernel virtual memory for > > > the device tree blob

Re: [PATCH v15 10/10] arm64: Add IMA log information in kimage used for kexec

2021-01-27 Thread Mimi Zohar
On Wed, 2021-01-27 at 10:24 -0800, Lakshmi Ramasubramanian wrote: > On 1/27/21 10:02 AM, Will Deacon wrote: > > On Wed, Jan 27, 2021 at 09:56:53AM -0800, Lakshmi Ramasubramanian wrote: > >> On 1/27/21 8:54 AM, Will Deacon wrote: > >>> On Fri, Jan 15, 2021 at 09:30:17AM -0800, Lakshmi

Re: [PATCH v15 10/10] arm64: Add IMA log information in kimage used for kexec

2021-01-27 Thread Lakshmi Ramasubramanian
On 1/27/21 10:02 AM, Will Deacon wrote: On Wed, Jan 27, 2021 at 09:56:53AM -0800, Lakshmi Ramasubramanian wrote: On 1/27/21 8:54 AM, Will Deacon wrote: On Fri, Jan 15, 2021 at 09:30:17AM -0800, Lakshmi Ramasubramanian wrote: Address and size of the buffer containing the IMA measurement log

Re: [PATCH v15 10/10] arm64: Add IMA log information in kimage used for kexec

2021-01-27 Thread Will Deacon
On Wed, Jan 27, 2021 at 09:56:53AM -0800, Lakshmi Ramasubramanian wrote: > On 1/27/21 8:54 AM, Will Deacon wrote: > > On Fri, Jan 15, 2021 at 09:30:17AM -0800, Lakshmi Ramasubramanian wrote: > > > Address and size of the buffer containing the IMA measurement log need > > > to be passed from the

Re: [PATCH v15 10/10] arm64: Add IMA log information in kimage used for kexec

2021-01-27 Thread Lakshmi Ramasubramanian
On 1/27/21 8:54 AM, Will Deacon wrote: Hi Will, On Fri, Jan 15, 2021 at 09:30:17AM -0800, Lakshmi Ramasubramanian wrote: Address and size of the buffer containing the IMA measurement log need to be passed from the current kernel to the next kernel on kexec. Add address and size fields to

Re: [PATCH] PCI: dwc: layerscape: convert to builtin_platform_driver()

2021-01-27 Thread Geert Uytterhoeven
Hi Saravana, On Wed, Jan 27, 2021 at 5:42 PM Saravana Kannan wrote: > On Tue, Jan 26, 2021 at 11:43 PM Geert Uytterhoeven > wrote: > > On Wed, Jan 27, 2021 at 1:44 AM Saravana Kannan > > wrote: > > > On Tue, Jan 26, 2021 at 12:50 AM Geert Uytterhoeven > > > wrote: > > > > On Mon, Jan 25,

Re: [PATCH v15 10/10] arm64: Add IMA log information in kimage used for kexec

2021-01-27 Thread Will Deacon
On Fri, Jan 15, 2021 at 09:30:17AM -0800, Lakshmi Ramasubramanian wrote: > Address and size of the buffer containing the IMA measurement log need > to be passed from the current kernel to the next kernel on kexec. > > Add address and size fields to "struct kimage_arch" for ARM64 platform > to

Re: [PATCH] powerpc/fault: fix wrong KUAP fault for IO_URING

2021-01-27 Thread Christophe Leroy
Le 27/01/2021 à 15:56, Zorro Lang a écrit : On powerpc, io_uring test hit below KUAP fault on __do_page_fault. The fail source line is: if (unlikely(!is_user && bad_kernel_fault(regs, error_code, address, is_write))) return SIGSEGV; The is_user() is based on user_mod(regs) only.

[PATCH] powerpc/fault: fix wrong KUAP fault for IO_URING

2021-01-27 Thread Zorro Lang
On powerpc, io_uring test hit below KUAP fault on __do_page_fault. The fail source line is: if (unlikely(!is_user && bad_kernel_fault(regs, error_code, address, is_write))) return SIGSEGV; The is_user() is based on user_mod(regs) only. This's not suit for io_uring, where the helper

Re: [PATCH v11 13/13] powerpc/64s/radix: Enable huge vmalloc mappings

2021-01-27 Thread Michael Ellerman
Nicholas Piggin writes: > Cc: linuxppc-dev@lists.ozlabs.org > Signed-off-by: Nicholas Piggin > --- Acked-by: Michael Ellerman cheers > .../admin-guide/kernel-parameters.txt | 2 ++ > arch/powerpc/Kconfig | 1 + > arch/powerpc/kernel/module.c