Re: [PATCH] tpm: of: avoid __va() translation for event log address

2020-09-27 Thread Christophe Leroy
Le 28/09/2020 à 01:44, Jarkko Sakkinen a écrit : On Fri, Sep 25, 2020 at 09:00:18AM -0300, Jason Gunthorpe wrote: On Fri, Sep 25, 2020 at 01:29:20PM +0300, Jarkko Sakkinen wrote: On Fri, Sep 25, 2020 at 09:00:56AM +0200, Ard Biesheuvel wrote: On Fri, 25 Sep 2020 at 07:56, Jarkko Sakkinen

Re: [PATCH -next] ocxl: simplify the return expression of free_function_dev()

2020-09-27 Thread Andrew Donnellan
On 21/9/20 11:10 pm, Qinglang Miao wrote: Simplify the return expression. Signed-off-by: Qinglang Miao Looks good Acked-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [PATCH] tpm: of: avoid __va() translation for event log address

2020-09-27 Thread Jarkko Sakkinen
On Fri, Sep 25, 2020 at 09:00:18AM -0300, Jason Gunthorpe wrote: > On Fri, Sep 25, 2020 at 01:29:20PM +0300, Jarkko Sakkinen wrote: > > On Fri, Sep 25, 2020 at 09:00:56AM +0200, Ard Biesheuvel wrote: > > > On Fri, 25 Sep 2020 at 07:56, Jarkko Sakkinen > > > wrote: > > > > > > > > On Tue, Sep 22,

Re: [PATCH] rpadlpar_io:Add MODULE_DESCRIPTION entries to kernel modules

2020-09-27 Thread Oliver O'Halloran
On Sat, Sep 26, 2020 at 5:43 AM Bjorn Helgaas wrote: > > On Thu, Sep 24, 2020 at 04:41:39PM +1000, Oliver O'Halloran wrote: > > On Thu, Sep 24, 2020 at 3:15 PM Mamatha Inamdar > > wrote: > > > > > > This patch adds a brief MODULE_DESCRIPTION to rpadlpar_io kernel modules > > > (descriptions

Re: [PATCH v3 2/5] powerpc: apm82181: create shared dtsi for APM bluestone

2020-09-27 Thread Christian Lamparter
On Tue, Sep 22, 2020 at 9:14 PM Rob Herring wrote: > > On Sat, Sep 19, 2020 at 2:23 PM Christian Lamparter > wrote: > > > > On 2020-09-15 03:05, Rob Herring wrote: > > > On Sun, Sep 06, 2020 at 12:06:12AM +0200, Christian Lamparter wrote: > > >> This patch adds an DTSI-File that can be used by

Re: [PATCH v2] i2c: cpm: Fix i2c_ram structure

2020-09-27 Thread Wolfram Sang
On Wed, Sep 23, 2020 at 04:08:40PM +0200, nico.vi...@gmail.com wrote: > From: Nicolas VINCENT > > the i2c_ram structure is missing the sdmatmp field mentionned in > datasheet for MPC8272 at paragraph 36.5. With this field missing, the > hardware would write past the allocated memory done through

[PATCH v1 30/30] powerpc/vdso: Cleanup vdso.h

2020-09-27 Thread Christophe Leroy
Rename the guard define to _ASM_POWERPC_VDSO_H And remove useless #ifdef __KERNEL__ Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/vdso.h | 10 +++--- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/arch/powerpc/include/asm/vdso.h

[PATCH v1 29/30] powerpc/vdso: Remove VDSO32_LBASE and VDSO64_LBASE

2020-09-27 Thread Christophe Leroy
VDSO32_LBASE and VDSO64_LBASE are 0. Remove them to simplify code. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/vdso.h | 4 arch/powerpc/kernel/vdso32/vdso32.lds.S | 2 +- arch/powerpc/kernel/vdso64/vdso64.lds.S | 2 +- 3 files changed, 2 insertions(+), 6

[PATCH v1 28/30] powerpc/vdso: Remove DBG()

2020-09-27 Thread Christophe Leroy
DBG() is not used anymore. Remove it. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 8 1 file changed, 8 deletions(-) diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c index e5a9b60274ba..4e3858bb2b24 100644 --- a/arch/powerpc/kernel/vdso.c +++

[PATCH v1 27/30] powerpc/vdso: Remove vdso_ready

2020-09-27 Thread Christophe Leroy
There is no way to get out of vdso_init() prematuraly anymore. Remove vdso_ready as it will always be 1. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c index

[PATCH v1 26/30] powerpc/vdso: Remove vdso_setup()

2020-09-27 Thread Christophe Leroy
vdso_fixup_features() cannot fail anymore and that's the only function called by vdso_setup(). vdso_setup() has become trivial and can be removed. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 21 ++--- 1 file changed, 2 insertions(+), 19 deletions(-) diff

[PATCH v1 24/30] powerpc/vdso: Remove symbol section information in struct lib32/64_elfinfo

2020-09-27 Thread Christophe Leroy
The members related to the symbol section in struct lib32_elfinfo and struct lib64_elfinfo are not used anymore, removed them. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 90 -- 1 file changed, 90 deletions(-) diff --git

[PATCH v1 25/30] powerpc/vdso: Remove lib32_elfinfo and lib64_elfinfo

2020-09-27 Thread Christophe Leroy
lib32_elfinfo and lib64_elfinfo are not used anymore, remove them. Also remove vdso32_kbase and vdso64_kbase while removing the last use. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 29 ++--- 1 file changed, 2 insertions(+), 27 deletions(-) diff

[PATCH v1 23/30] powerpc/vdso: Remove unused text member in struct lib32/64_elfinfo

2020-09-27 Thread Christophe Leroy
The text member in struct lib32_elfinfo and struct lib64_elfinfo is not used, remove it. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 16 1 file changed, 16 deletions(-) diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c index

[PATCH v1 20/30] powerpc/vdso: Remove __kernel_datapage_offset

2020-09-27 Thread Christophe Leroy
__kernel_datapage_offset is not used anymore, remove it. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 39 - arch/powerpc/kernel/vdso32/datapage.S | 3 -- arch/powerpc/kernel/vdso32/vdso32.lds.S | 5

[PATCH v1 22/30] powerpc/vdso: Remove vdso_patches[] and associated functions

2020-09-27 Thread Christophe Leroy
vdso_patches[] is now empty, remove it and remove all functions that depends on it. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 161 - 1 file changed, 161 deletions(-) diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c

[PATCH v1 21/30] powerpc/vdso: Remove runtime generated sigtramp offsets

2020-09-27 Thread Christophe Leroy
Signal trampoline offsets are now generated at buildtime. Runtime generated offsets are not used anymore, remove them. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/vdso.h | 5 --- arch/powerpc/kernel/vdso.c | 59 - 2 files changed, 64

[PATCH v1 18/30] powerpc/vdso: Merge __kernel_sync_dicache_p5() into __kernel_sync_dicache()

2020-09-27 Thread Christophe Leroy
__kernel_sync_dicache_p5() is an alternative to __kernel_sync_dicache() when cpu has CPU_FTR_COHERENT_ICACHE Remove this alternative function and merge __kernel_sync_dicache_p5() into __kernel_sync_dicache() using standard CPU feature fixup. Signed-off-by: Christophe Leroy ---

[PATCH v1 17/30] powerpc/vdso: Use builtin symbols to locate fixup section

2020-09-27 Thread Christophe Leroy
Add builtin symbols to locate fixup section and use them instead of locating sections through elf headers at runtime. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 55 +++-- arch/powerpc/kernel/vdso32/vdso32.lds.S | 8

[PATCH v1 19/30] powerpc/vdso: Remove vdso32_pages and vdso64_pages

2020-09-27 Thread Christophe Leroy
vdso32_pages and vdso64_pages are not used anymore. Remove them. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 16 1 file changed, 16 deletions(-) diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c index 3a4fbcc0d1be..e732776bac0a 100644

[PATCH v1 16/30] powerpc/vdso: Retrieve sigtramp offsets at buildtime

2020-09-27 Thread Christophe Leroy
This is copied from arm64. Instead of using runtime generated signal trampoline offsets, get offsets at buildtime. If the said trampoline doesn't exist, build will fail. So no need to check whether the trampoline exists or not in the VDSO. Signed-off-by: Christophe Leroy ---

[PATCH v1 15/30] powerpc/vdso: Remove unused \tmp param in __get_datapage()

2020-09-27 Thread Christophe Leroy
The \tmp param is not used anymore, remove it. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/vdso/gettimeofday.h | 4 ++-- arch/powerpc/include/asm/vdso_datapage.h | 2 +- arch/powerpc/kernel/vdso32/cacheflush.S | 2 +- arch/powerpc/kernel/vdso32/datapage.S| 4

[PATCH v1 14/30] powerpc/vdso: Simplify __get_datapage()

2020-09-27 Thread Christophe Leroy
The VDSO datapage and the text pages are always located immediately next to each other, so it can be hardcoded without an indirection through __kernel_datapage_offset Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/vdso_datapage.h | 8 +---

[PATCH v1 13/30] powerpc/vdso: Move vdso datapage up front

2020-09-27 Thread Christophe Leroy
Move the vdso datapage in front of the VDSO area, before vdso test. This will allow to remove the __kernel_datapage_offset symbol and simplify __get_datapage() in following patches. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/mmu_context.h | 2 +- arch/powerpc/kernel/vdso.c

[PATCH v1 12/30] powerpc/vdso: Replace vdso_base by vdso

2020-09-27 Thread Christophe Leroy
All other architectures but s390 use a void pointer named 'vdso' to reference the VDSO mapping. In a following patch, the VDSO data page will be put in front of text, vdso_base will then not anymore point to VDSO text. To avoid confusion between vdso_base and VDSO text, rename vdso_base into

[PATCH v1 11/30] powerpc/vdso: Provide vdso_remap()

2020-09-27 Thread Christophe Leroy
Provide vdso_remap() through _install_special_mapping() and drop arch_remap(). This adds a test of the size and returns -EINVAL if the size is not correct. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/mm-arch-hooks.h | 25 arch/powerpc/kernel/vdso.c

[PATCH v1 10/30] powerpc/vdso: Move to _install_special_mapping() and remove arch_vma_name()

2020-09-27 Thread Christophe Leroy
Copied from commit 2fea7f6c98f5 ("arm64: vdso: move to _install_special_mapping and remove arch_vma_name"). Use the new _install_special_mapping() API added by commit a62c34bd2a8a ("x86, mm: Improve _install_special_mapping and fix x86 vdso naming") which obsolete install_special_mapping(). And

[PATCH v1 08/30] powerpc/vdso: Use VDSO size in arch_setup_additional_pages()

2020-09-27 Thread Christophe Leroy
In arch_setup_additional_pages(), instead of using number of VDSO pages and recalculate VDSO size, directly use the VDSO size. As vdso_ready is set, vdso_pages can't be 0 so just remove the test. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 18 ++ 1 file

[PATCH v1 07/30] powerpc/vdso: Remove unnecessary ifdefs in vdso_pagelist initialization

2020-09-27 Thread Christophe Leroy
No need of all those #ifdefs around the pagelist initialisation, use IS_ENABLED(), GCC will kick out unused static variables. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 31 ++- 1 file changed, 6 insertions(+), 25 deletions(-) diff --git

[PATCH v1 06/30] powerpc/vdso: Refactor 32 bits and 64 bits pages setup

2020-09-27 Thread Christophe Leroy
The setup of VDSO pages is identical for 32 bits VDSO and 64 bits VDSO. Refactor that setup. And use _start which is synonym of vdsoXX_kbase. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 39 +++--- 1 file changed, 19 insertions(+), 20

[PATCH v1 09/30] powerpc/vdso: Simplify arch_setup_additional_pages() exit

2020-09-27 Thread Christophe Leroy
To simplify arch_setup_additional_pages() exit, rename it __arch_setup_additional_pages() and create a caller arch_setup_additional_pages() which does the locking. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 40 -- 1 file changed, 21

[PATCH v1 05/30] powerpc/vdso: Remove NULL termination element in vdso_pagelist

2020-09-27 Thread Christophe Leroy
No need of a NULL last element in pagelists, install_special_mapping() knows how long the list is. Remove that element. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/arch/powerpc/kernel/vdso.c

[PATCH v1 01/30] powerpc/vdso: Stripped VDSO is not needed, don't build it

2020-09-27 Thread Christophe Leroy
Since commit 24b659a13866 ("powerpc: Use unstripped VDSO image for more accurate profiling data"), only the unstripped VDSO image has been used. Partially revert commit 8150caad0226 ("[POWERPC] powerpc vDSO: install unstripped copies on disk") to avoid building the stripped version. And the

[PATCH v1 03/30] powerpc/vdso: Rename syscall_map_32/64 to simplify vdso_setup_syscall_map()

2020-09-27 Thread Christophe Leroy
Today vdso_data structure has: - syscall_map_32[] and syscall_map_64[] on PPC64 - syscall_map_32[] on PPC32 On PPC32, syscall_map_32[] is populated using sys_call_table[]. On PPC64, syscall_map_64[] is populated using sys_call_table[] and syscal_map_32[] is populated using

[PATCH v1 00/30] Modernise VDSO setup

2020-09-27 Thread Christophe Leroy
This series modernises the setup of VDSO: - Switch to using _install_special_mapping() which has replaced install_special_mapping() - Move datapage in front of text like most other architectures to simplify its localisation - Perform link time symbol resolution instead of runtime This leads to

[PATCH v1 02/30] powerpc/vdso: Add missing includes and clean vdso_setup_syscall_map()

2020-09-27 Thread Christophe Leroy
Instead of including extern references locally in vdso_setup_syscall_map(), add the missing headers. sys_ni_syscall() being a function, cast its address to an unsigned long instead of declaring it as a fake unsigned long object. At the same time, remove a comment which paraphrases the function

[PATCH v1 04/30] powerpc/vdso: Remove get_page() in vdso_pagelist initialization

2020-09-27 Thread Christophe Leroy
Partly copied from commit 16fb1a9bec61 ("arm64: vdso: clean up vdso_pagelist initialization"). No need to get_page() the vdso text/data - these are part of the kernel image. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vdso.c | 6 ++ 1 file changed, 2 insertions(+), 4

Re: [PATCH v8 2/8] powerpc/vdso: Remove __kernel_datapage_offset and simplify __get_datapage()

2020-09-27 Thread Christophe Leroy
Le 21/09/2020 à 13:26, Will Deacon a écrit : On Fri, Aug 28, 2020 at 12:14:28PM +1000, Michael Ellerman wrote: Dmitry Safonov <0x7f454...@gmail.com> writes: On Wed, 26 Aug 2020 at 15:39, Michael Ellerman wrote: Christophe Leroy writes: We added a test for vdso unmap recently because it

Re: [RFC PATCH 18/18] powerpc/powermac: Move PHB discovery

2020-09-27 Thread Christophe Leroy
Le 24/09/2020 à 08:38, Oliver O'Halloran a écrit : Signed-off-by: Oliver O'Halloran Tested-by: Christophe Leroy This series is a really good step forward to the elimination of early support for ioremap(), thanks. Tested with pmac32_defconfig on QEMU MAC99. Before the series we have

RE: [PATCH 1/5] Documentation: dt: binding: fsl: Add 'fsl,ippdexpcr1-alt-addr' property

2020-09-27 Thread Ran Wang
Hi Rob Not sure whether you have missed this mail with my query. Regards, Ran On Wednesday, September 23, 2020 2:44 PM Ran Wang wrote: > > Hi Rob, > > On Wednesday, September 23, 2020 10:33 AM, Rob Herring wrote: > > > > On Wed, Sep 16, 2020 at 04:18:27PM +0800, Ran Wang wrote: > > > From: