Re: [PATCH] crypto: vmx - fix copy-paste error in CTR mode

2019-05-14 Thread Daniel Axtens
Michael Ellerman writes: > Herbert Xu writes: >> On Mon, May 06, 2019 at 08:53:17AM -0700, Eric Biggers wrote: >>> >>> Any progress on this? Someone just reported this again here: >>> https://bugzilla.kernel.org/show_bug.cgi?id=203515 >> >> Guys if I don't get a fix for this soon I'll have to

Patch "cpu/speculation: Add 'mitigations=' cmdline option" has been added to the 4.4-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled cpu/speculation: Add 'mitigations=' cmdline option to the 4.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is:

Patch "[PATCH 70/76] x86/speculation: Support 'mitigations=' cmdline option" has been added to the 4.9-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 70/76] x86/speculation: Support 'mitigations=' cmdline option to the 4.9-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 22/27] powerpc/speculation: Support 'mitigations=' cmdline" has been added to the 5.1-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 22/27] powerpc/speculation: Support 'mitigations=' cmdline to the 5.1-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 21/27] x86/speculation: Support 'mitigations=' cmdline option" has been added to the 5.0-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 21/27] x86/speculation: Support 'mitigations=' cmdline option to the 5.0-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 22/27] powerpc/speculation: Support 'mitigations=' cmdline" has been added to the 5.0-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 22/27] powerpc/speculation: Support 'mitigations=' cmdline to the 5.0-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 69/76] cpu/speculation: Add 'mitigations=' cmdline option" has been added to the 4.9-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 69/76] cpu/speculation: Add 'mitigations=' cmdline option to the 4.9-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 25/30] powerpc/speculation: Support 'mitigations=' cmdline" has been added to the 4.19-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 25/30] powerpc/speculation: Support 'mitigations=' cmdline to the 4.19-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 23/27] s390/speculation: Support 'mitigations=' cmdline option" has been added to the 5.1-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 23/27] s390/speculation: Support 'mitigations=' cmdline option to the 5.1-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 26/32] x86/speculation: Support 'mitigations=' cmdline option" has been added to the 4.14-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 26/32] x86/speculation: Support 'mitigations=' cmdline option to the 4.14-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 20/27] cpu/speculation: Add 'mitigations=' cmdline option" has been added to the 5.0-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 20/27] cpu/speculation: Add 'mitigations=' cmdline option to the 5.0-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 23/27] s390/speculation: Support 'mitigations=' cmdline option" has been added to the 5.0-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 23/27] s390/speculation: Support 'mitigations=' cmdline option to the 5.0-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Re: [PATCH] vsprintf: Do not break early boot with probing addresses

2019-05-14 Thread Steven Rostedt
[ Purple is a nice shade on the bike shed. ;-) ] On Tue, 14 May 2019 11:02:17 +0200 Geert Uytterhoeven wrote: > On Tue, May 14, 2019 at 10:29 AM David Laight wrote: > > > And I like Steven's "(fault)" idea. > > > How about this: > > > > > > if ptr < PAGE_SIZE -> "(null)" >

Patch "x86/speculation: Support 'mitigations=' cmdline option" has been added to the 4.4-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled x86/speculation: Support 'mitigations=' cmdline option to the 4.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is:

Re: [PATCH] vsprintf: Do not break early boot with probing addresses

2019-05-14 Thread Geert Uytterhoeven
Hi Steve, On Tue, May 14, 2019 at 8:37 PM Steven Rostedt wrote: > On Tue, 14 May 2019 11:02:17 +0200 > Geert Uytterhoeven wrote: > > On Tue, May 14, 2019 at 10:29 AM David Laight > > wrote: > > > > And I like Steven's "(fault)" idea. > > > > How about this: > > > > > > > > if ptr <

Patch "[PATCH 24/30] x86/speculation: Support 'mitigations=' cmdline option" has been added to the 4.19-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 24/30] x86/speculation: Support 'mitigations=' cmdline option to the 4.19-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 21/27] x86/speculation: Support 'mitigations=' cmdline option" has been added to the 5.1-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 21/27] x86/speculation: Support 'mitigations=' cmdline option to the 5.1-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Re: [PATCH] vsprintf: Do not break early boot with probing addresses

2019-05-14 Thread Steven Rostedt
On Tue, 14 May 2019 21:13:06 +0200 Geert Uytterhoeven wrote: > > > Do we care about the value? "(-E%u)"? > > > > That too could be confusing. What would (-E22) be considered by a user > > doing an sprintf() on some string. I know that would confuse me, or I > > would think that it was what the

Patch "[PATCH 25/32] cpu/speculation: Add 'mitigations=' cmdline option" has been added to the 4.14-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 25/32] cpu/speculation: Add 'mitigations=' cmdline option to the 4.14-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 26/30] s390/speculation: Support 'mitigations=' cmdline option" has been added to the 4.19-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 26/30] s390/speculation: Support 'mitigations=' cmdline option to the 4.19-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of

Patch "[PATCH 27/32] powerpc/speculation: Support 'mitigations=' cmdline" has been added to the 4.14-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 27/32] powerpc/speculation: Support 'mitigations=' cmdline to the 4.14-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

[PATCH 1/3] powerpc/book3s: Use config independent helpers for page table walk

2019-05-14 Thread Aneesh Kumar K.V
Even when we have HugeTLB and THP disabled, kernel linear map can still be mapped with hugepages. This is only an issue with radix translation because hash MMU doesn't map kernel linear range in linux page table and other kernel map areas are not mapped using hugepage. Add config independent

Re: [PATCH] EDAC, mpc85xx: Prevent building as a module

2019-05-14 Thread Michael Ellerman
Borislav Petkov writes: > On Fri, May 10, 2019 at 04:13:20PM +0200, Borislav Petkov wrote: >> On Fri, May 10, 2019 at 08:50:52PM +1000, Michael Ellerman wrote: >> > Yeah that looks better to me. I didn't think about the case where EDAC >> > core is modular. >> > >> > Do you want me to send a new

Re: [Bug 203597] New: kernel 4.9.175 fails to boot on a PowerMac G4 3,6 at early stage

2019-05-14 Thread Greg KH
On Tue, May 14, 2019 at 06:56:03AM +0200, Christophe Leroy wrote: > Hi Greg, > > Could you please apply b45ba4a51cde29b2939365ef0c07ad34c8321789 to 4.9 since > 51c3c62b58b357e8d35e4cc32f7b4ec907426fe3 was applied allthought marked for > #4.13+ It does not apply there (nor to the 4.4.y queue,

RE: [PATCH] vsprintf: Do not break early boot with probing addresses

2019-05-14 Thread David Laight
> And I like Steven's "(fault)" idea. > How about this: > > if ptr < PAGE_SIZE -> "(null)" > if IS_ERR_VALUE(ptr)-> "(fault)" > > -ss Or: if (ptr < PAGE_SIZE) return ptr ? "(null+)" : "(null)"; if IS_ERR_VALUE(ptr)

Re: [RFC PATCH] powerpc/64/ftrace: mprofile-kernel patch out mflr

2019-05-14 Thread Naveen N. Rao
Michael Ellerman wrote: "Naveen N. Rao" writes: Michael Ellerman wrote: Nicholas Piggin writes: The new mprofile-kernel mcount sequence is mflr r0 bl_mcount Dynamic ftrace patches the branch instruction with a noop, but leaves the mflr. mflr is executed by the branch unit that

Re: [PATCH 2/2] powerpc/8xx: Add microcode patch to move SMC parameter RAM.

2019-05-14 Thread Christophe Leroy
Le 14/05/2019 à 10:31, Christophe Leroy a écrit : Le 14/05/2019 à 08:56, Michael Ellerman a écrit : Christophe Leroy writes: Some SCC functions like the QMC requires an extended parameter RAM. On modern 8xx (ie 866 and 885), SPI area can already be relocated, allowing the use of those

Re: Kernel OOPS followed by a panic on next20190507 with 4K page size

2019-05-14 Thread Sachin Sant
> On 14-May-2019, at 7:00 AM, Aneesh Kumar K.V > wrote: > > On 5/8/19 4:30 PM, Sachin Sant wrote: >> While running LTP tests (specifically futex_wake04) against next-20199597 >> build with 4K page size on a POWER8 LPAR following crash is observed. >> [ 4233.214876] BUG: Kernel NULL pointer

[PATCH 2/4] powerpc/32: activate ARCH_HAS_PMEM_API and ARCH_HAS_UACCESS_FLUSHCACHE

2019-05-14 Thread Christophe Leroy
PPC32 also have flush_dcache_range() so it can also support ARCH_HAS_PMEM_API and ARCH_HAS_UACCESS_FLUSHCACHE without changes. Signed-off-by: Christophe Leroy --- arch/powerpc/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/Kconfig

[PATCH 2/3] powerpc/mm: pmd_devmap implies pmd_large().

2019-05-14 Thread Aneesh Kumar K.V
large devmap usage is dependent on THP. Hence once check is sufficient. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/mm/book3s64/pgtable.c | 2 +- arch/powerpc/mm/pgtable_64.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/mm/book3s64/pgtable.c

Re: [PATCH 2/2] powerpc/8xx: Add microcode patch to move SMC parameter RAM.

2019-05-14 Thread Michael Ellerman
Christophe Leroy writes: > Some SCC functions like the QMC requires an extended parameter RAM. > On modern 8xx (ie 866 and 885), SPI area can already be relocated, > allowing the use of those functions on SCC2. But SCC3 and SCC4 > parameter RAM collide with SMC1 and SMC2 parameter RAMs. > > This

Re: [PATCH v2] powerpc: Fix compile issue with force DAWR

2019-05-14 Thread Christophe Leroy
Le 14/05/2019 à 08:55, Michael Neuling a écrit : [...] + +static ssize_t dawr_write_file_bool(struct file *file, + const char __user *user_buf, + size_t count, loff_t *ppos) +{ + struct arch_hw_breakpoint

Re: Build failure in v4.4.y.queue (ppc:allmodconfig)

2019-05-14 Thread Michael Ellerman
Guenter Roeck writes: > On Fri, May 10, 2019 at 12:31:05AM +1000, Michael Ellerman wrote: >> Greg Kroah-Hartman writes: >> > On Wed, May 08, 2019 at 01:26:42PM -0700, Guenter Roeck wrote: >> >> I see multiple instances of: >> >> >> >> arch/powerpc/kernel/exceptions-64s.S:839: Error: >> >>

[PATCH] powerpc/book3s/mm: Clear MMU_FTR_HPTE_TABLE when radix is enabled.

2019-05-14 Thread Aneesh Kumar K.V
Avoids confusion when printing Oops message like below Faulting instruction address: 0xc008bdb4 Oops: Kernel access of bad area, sig: 11 [#1] LE PAGE_SIZE=64K MMU=Radix MMU=Hash SMP NR_CPUS=2048 NUMA PowerNV Either ibm,pa-features or ibm,powerpc-cpu-features can be used to enable the

Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock acquisition in resize_hpt

2019-05-14 Thread Michael Ellerman
"Gautham R. Shenoy" writes: > From: "Gautham R. Shenoy" > > Subject: Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock acquisition > in resize_hpt ps. A "RESEND" implies the patch is unchanged and you're just resending it because it was ignored. In this case it should have just been

Re: [PATCH 2/2] powerpc/8xx: Add microcode patch to move SMC parameter RAM.

2019-05-14 Thread Christophe Leroy
Le 14/05/2019 à 08:56, Michael Ellerman a écrit : Christophe Leroy writes: Some SCC functions like the QMC requires an extended parameter RAM. On modern 8xx (ie 866 and 885), SPI area can already be relocated, allowing the use of those functions on SCC2. But SCC3 and SCC4 parameter RAM

Re: [PATCH] vsprintf: Do not break early boot with probing addresses

2019-05-14 Thread Geert Uytterhoeven
On Tue, May 14, 2019 at 10:29 AM David Laight wrote: > > And I like Steven's "(fault)" idea. > > How about this: > > > > if ptr < PAGE_SIZE -> "(null)" > > if IS_ERR_VALUE(ptr)-> "(fault)" > > > > -ss > > Or: > if (ptr < PAGE_SIZE) >

Re: [PATCH] powerpc/mm: Handle page table allocation failures

2019-05-14 Thread Michael Ellerman
"Aneesh Kumar K.V" writes: > This fix the below crash that arise due to not handling page table allocation > failures while allocating hugetlb page table. > > BUG: Kernel NULL pointer dereference at 0x001c > Faulting instruction address: 0xc1d1e58c > Oops: Kernel access of bad

Re: [PATCH v2] powerpc: Fix compile issue with force DAWR

2019-05-14 Thread Michael Neuling
> > > > -- > > > > v2: > > > > Fixes based on Christophe Leroy's comments: > > > > - Fix commit message formatting > > > > - Move more DAWR code into dawr.c > > > > --- > > > >arch/powerpc/Kconfig | 5 ++ > > > >arch/powerpc/include/asm/hw_breakpoint.h |

[PATCH 1/4] powerpc/64: flush_inval_dcache_range() becomes flush_dcache_range()

2019-05-14 Thread Christophe Leroy
On most arches having function flush_dcache_range(), including PPC32, this function does a writeback and invalidation of the cache bloc. On PPC64, flush_dcache_range() only does a writeback while flush_inval_dcache_range() does the invalidation in addition. In addition it looks like within

[PATCH 3/3] powerpc/mm: Remove radix dependency on HugeTLB page

2019-05-14 Thread Aneesh Kumar K.V
Now that we have switched the page table walk to use pmd_is_leaf we can now revert commit 8adddf349fda ("powerpc/mm/radix: Make Radix require HUGETLB_PAGE") Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/platforms/Kconfig.cputype | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock acquisition in resize_hpt

2019-05-14 Thread Michael Ellerman
"Gautham R. Shenoy" writes: > From: "Gautham R. Shenoy" > > During a memory hotplug operations involving resizing of the HPT, we > invoke a stop_machine() to perform the resizing. In this code path, we > end up recursively taking the cpu_hotplug_lock, first in > memory_hotplug_begin() and then

Re: [v2 2/2] [PowerPC] Allow use of SIMD in interrupts from kernel code

2019-05-14 Thread Russell Currey
On Mon, 2019-05-13 at 23:23 -0300, Shawn Landden wrote: > This second patch is separate because it could be wrong, > like I am not sure about how kernel thread migration works, > and it is even allowing simd in preemptible kernel code. > > Signed-off-by: Shawn Landden > --- Hi Shawn, This

Re: [PATCH] EDAC, mpc85xx: Prevent building as a module

2019-05-14 Thread Borislav Petkov
On Tue, May 14, 2019 at 04:50:49PM +1000, Michael Ellerman wrote: > Looks good. I even booted it :) Cool, thanks! -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.

[PATCH 3/4] powerpc/32: define helpers to get L1 cache sizes.

2019-05-14 Thread Christophe Leroy
This patch defines C helpers to retrieve the size of cache blocks and uses them in the cacheflush functions. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/cache.h | 16 ++-- arch/powerpc/include/asm/cacheflush.h | 24 +++- 2 files changed, 29

[PATCH 4/4] powerpc/64: reuse PPC32 static inline flush_dcache_range()

2019-05-14 Thread Christophe Leroy
This patch drops the assembly PPC64 version of flush_dcache_range() and re-uses the PPC32 static inline version. With GCC 8.1, the following code is generated: void flush_test(unsigned long start, unsigned long stop) { flush_dcache_range(start, stop); } 0130 <.flush_test>:

Re: [PATCH] powerpc/boot: fix broken way to pass CONFIG options

2019-05-14 Thread Masahiro Yamada
On Mon, May 13, 2019 at 11:24 PM Oliver wrote: > > On Mon, May 13, 2019 at 9:23 PM Masahiro Yamada > wrote: > > > > Commit 5e9dcb6188a4 ("powerpc/boot: Expose Kconfig symbols to wrapper") > > was wrong, but commit e41b93a6be57 ("powerpc/boot: Fix build failures > > with -j 1") was also wrong. >

Re: [PATCH 1/2] [PowerPC] Add simd.h implementation

2019-05-14 Thread Shawn Landden
On Tue, May 14, 2019 at 12:43 AM Benjamin Herrenschmidt wrote: > > On Mon, 2019-05-13 at 22:44 -0300, Shawn Landden wrote: > > + > > +/* > > + * Were we in user mode when we were > > + * interrupted? > > + * > > + * Doing kernel_altivec/vsx_begin/end() is ok if we are running > > + * in an

Re: [PATCH] powerpc: Allow may_use_simd() to function as feature detection

2019-05-14 Thread Shawn Landden
Wireguard is not in the kernel (yet) and uses these symbols. (It is IS_ENABLED so doesn't need it, but I think it is reasonable) I think these enable/disable symbols should not be marked GPL-only. El mar., 14 may. 2019 13:06, Segher Boessenkool escribió: > On Tue, May 14, 2019 at 09:49:18AM

[PATCH] powerpc/security: Fix build break

2019-05-14 Thread Joel Stanley
This fixes a build break introduced in with the recent round of CPU bug patches. arch/powerpc/kernel/security.c: In function ‘setup_barrier_nospec’: arch/powerpc/kernel/security.c:59:21: error: implicit declaration of function ‘cpu_mitigations_off’ [-Werror=implicit-function-declaration]

Re: [PATCH] powerpc/security: Fix build break

2019-05-14 Thread Greg Kroah-Hartman
On Wed, May 15, 2019 at 02:22:06PM +0930, Joel Stanley wrote: > This fixes a build break introduced in with the recent round of CPU > bug patches. > > arch/powerpc/kernel/security.c: In function ‘setup_barrier_nospec’: > arch/powerpc/kernel/security.c:59:21: error: implicit declaration of >

Re: [PATCH] crypto: vmx - fix copy-paste error in CTR mode

2019-05-14 Thread Herbert Xu
On Wed, May 15, 2019 at 03:35:51AM +1000, Daniel Axtens wrote: > > By all means disable vmx ctr if I don't get an answer to you in a > timeframe you are comfortable with, but I am going to at least try to > have a look. I'm happy to give you guys more time. How much time do you think you will

Re: [RFC PATCH 1/3] powerpc/mm: Handle page table allocation failures

2019-05-14 Thread Tyrel Datwyler
On 05/14/2019 07:50 AM, Aneesh Kumar K.V wrote: > This fixes the below crash that arises due to not handling page table > allocation > failures while allocating hugetlb page table. Was there supposed to be a oops stack trace attached here in the commit log? -Tyrel > > Fixes: e2b3d202d1db

[PATCH] powerpc/mm/book3s64: Implement STRICT_MODULE_RWX

2019-05-14 Thread Russell Currey
Strict module RWX is just like strict kernel RWX, but for modules - so loadable modules aren't marked both writable and executable at the same time. This is handled by the generic code in kernel/module.c, and simply requires the architecture to implement the set_memory() set of functions,

Re: [v3 2/2] [PowerPC] Allow use of SIMD in interrupts from kernel code

2019-05-14 Thread kbuild test robot
Hi Shawn, Thank you for the patch! Yet something to improve: [auto build test ERROR on powerpc/next] [also build test ERROR on v5.1 next-20190514] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux

Re: [v2 2/2] [PowerPC] Allow use of SIMD in interrupts from kernel code

2019-05-14 Thread Shawn Landden
On Tue, May 14, 2019 at 2:22 AM Russell Currey wrote: > > On Mon, 2019-05-13 at 23:23 -0300, Shawn Landden wrote: > > This second patch is separate because it could be wrong, > > like I am not sure about how kernel thread migration works, > > and it is even allowing simd in preemptible kernel

[PATCH 1/2] [PowerPC] Add simd.h implementation

2019-05-14 Thread Shawn Landden
Based off the x86 one. WireGuard really wants to be able to do SIMD in interrupts, so it can accelerate its in-bound path. Signed-off-by: Shawn Landden --- arch/powerpc/include/asm/simd.h | 17 + arch/powerpc/kernel/process.c | 30 ++ 2 files

[v4 PATCH 1/2] [PowerPC] Add simd.h implementation

2019-05-14 Thread Shawn Landden
Based off the x86 one. WireGuard really wants to be able to do SIMD in interrupts, so it can accelerate its in-bound path. Signed-off-by: Shawn Landden --- arch/powerpc/include/asm/simd.h | 17 + arch/powerpc/kernel/process.c | 30 ++ 2 files

[v4 PATCH 2/2] [PowerPC] Allow use of SIMD in interrupts from kernel code

2019-05-14 Thread Shawn Landden
This second patch is separate because it could be wrong, like I am not sure about how kernel thread migration works, and it is even allowing simd in preemptible kernel code. v4: fix build without CONFIG_AVX Signed-off-by: Shawn Landden --- arch/powerpc/include/asm/switch_to.h | 15 +---

Re: [PATCH] powerpc/mm: Handle page table allocation failures

2019-05-14 Thread Sachin Sant
> On 14-May-2019, at 12:10 PM, Michael Ellerman wrote: > > "Aneesh Kumar K.V" writes: >> This fix the below crash that arise due to not handling page table allocation >> failures while allocating hugetlb page table. >> >> BUG: Kernel NULL pointer dereference at 0x001c >> Faulting

[PATCH stable 4.9] powerpc/lib: fix code patching during early init on PPC32

2019-05-14 Thread Christophe Leroy
[Backport of upstream commit b45ba4a51cde29b2939365ef0c07ad34c8321789] On powerpc32, patch_instruction() is called by apply_feature_fixups() which is called from early_init() There is the following note in front of early_init(): * Note that the kernel may be running at an address which is

Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock acquisition in resize_hpt

2019-05-14 Thread Gautham R Shenoy
Hi Michael, On Tue, May 14, 2019 at 05:00:19PM +1000, Michael Ellerman wrote: > "Gautham R. Shenoy" writes: > > From: "Gautham R. Shenoy" > > > > During a memory hotplug operations involving resizing of the HPT, we > > invoke a stop_machine() to perform the resizing. In this code path, we > >

Re: [PATCH stable 4.9] powerpc/lib: fix code patching during early init on PPC32

2019-05-14 Thread Michael Ellerman
Christophe Leroy writes: > [Backport of upstream commit b45ba4a51cde29b2939365ef0c07ad34c8321789] > > On powerpc32, patch_instruction() is called by apply_feature_fixups() > which is called from early_init() > > There is the following note in front of early_init(): > * Note that the kernel may

Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock acquisition in resize_hpt

2019-05-14 Thread Gautham R Shenoy
On Tue, May 14, 2019 at 05:02:16PM +1000, Michael Ellerman wrote: > "Gautham R. Shenoy" writes: > > From: "Gautham R. Shenoy" > > > > Subject: Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock > > acquisition in resize_hpt > > ps. A "RESEND" implies the patch is unchanged and you're

Re: [PATCH] powerpc/powernv/npu: Fix reference leak

2019-05-14 Thread Michael Ellerman
Greg Kurz writes: > Michael, > > Any comments on this patch ? Should I repost with a shorter comment > as suggested by Alexey ? No the longer comment seems fine to me. I'm not a big fan of the patch, it's basically a hack :) But for a backportable fix I guess it is OK. I would be happier

Re: Kernel OOPS followed by a panic on next20190507 with 4K page size

2019-05-14 Thread Christophe Leroy
Le 14/05/2019 à 10:57, Sachin Sant a écrit : On 14-May-2019, at 7:00 AM, Aneesh Kumar K.V wrote: On 5/8/19 4:30 PM, Sachin Sant wrote: While running LTP tests (specifically futex_wake04) against next-20199597 build with 4K page size on a POWER8 LPAR following crash is observed. [

Re: Kernel OOPS followed by a panic on next20190507 with 4K page size

2019-05-14 Thread Michael Ellerman
Sachin Sant writes: >> On 14-May-2019, at 7:00 AM, Aneesh Kumar K.V >> wrote: >> >> On 5/8/19 4:30 PM, Sachin Sant wrote: >>> While running LTP tests (specifically futex_wake04) against next-20199597 >>> build with 4K page size on a POWER8 LPAR following crash is observed. >>> [ 4233.214876]

Re: Kernel OOPS followed by a panic on next20190507 with 4K page size

2019-05-14 Thread Sachin Sant
> On 14-May-2019, at 4:35 PM, Christophe Leroy wrote: > > > > Le 14/05/2019 à 10:57, Sachin Sant a écrit : >>> On 14-May-2019, at 7:00 AM, Aneesh Kumar K.V >>> wrote: >>> >>> On 5/8/19 4:30 PM, Sachin Sant wrote: While running LTP tests (specifically futex_wake04) against

Patch "[PATCH 23/30] cpu/speculation: Add 'mitigations=' cmdline option" has been added to the 4.19-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 23/30] cpu/speculation: Add 'mitigations=' cmdline option to the 4.19-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "[PATCH 28/32] s390/speculation: Support 'mitigations=' cmdline option" has been added to the 4.14-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 28/32] s390/speculation: Support 'mitigations=' cmdline option to the 4.14-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of

Patch "[PATCH 20/27] cpu/speculation: Add 'mitigations=' cmdline option" has been added to the 5.1-stable tree

2019-05-14 Thread gregkh
This is a note to let you know that I've just added the patch titled [PATCH 20/27] cpu/speculation: Add 'mitigations=' cmdline option to the 5.1-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Re: [PATCH] powerpc: Allow may_use_simd() to function as feature detection

2019-05-14 Thread Segher Boessenkool
On Tue, May 14, 2019 at 09:49:18AM -0300, Shawn Landden wrote: > ARM does this, so we might as well too. > I am a bit confused however as CONFIG_ALTIVEC does not select > CONFIG_PPC_FPU. Would you ever have altivec without a fpu? There is no hardware like that, none supported anyway. It does not

Re: Kernel OOPS followed by a panic on next20190507 with 4K page size

2019-05-14 Thread Michael Ellerman
Christophe Leroy writes: > Le 14/05/2019 à 10:57, Sachin Sant a écrit : >>> On 14-May-2019, at 7:00 AM, Aneesh Kumar K.V >>> wrote: >>> On 5/8/19 4:30 PM, Sachin Sant wrote: While running LTP tests (specifically futex_wake04) against next-20199597 build with 4K page size on a POWER8

Re: Kernel OOPS followed by a panic on next20190507 with 4K page size

2019-05-14 Thread Christophe Leroy
Le 14/05/2019 à 15:06, Michael Ellerman a écrit : Christophe Leroy writes: Le 14/05/2019 à 10:57, Sachin Sant a écrit : On 14-May-2019, at 7:00 AM, Aneesh Kumar K.V wrote: On 5/8/19 4:30 PM, Sachin Sant wrote: While running LTP tests (specifically futex_wake04) against next-20199597

Re: [PATCH] powerpc/powernv/npu: Fix reference leak

2019-05-14 Thread Greg Kurz
On Tue, 14 May 2019 21:13:40 +1000 Michael Ellerman wrote: > Greg Kurz writes: > > Michael, > > > > Any comments on this patch ? Should I repost with a shorter comment > > as suggested by Alexey ? > > No the longer comment seems fine to me. > > I'm not a big fan of the patch, it's basically

[PATCH] powerpc: Allow may_use_simd() to function as feature detection

2019-05-14 Thread Shawn Landden
ARM does this, so we might as well too. I am a bit confused however as CONFIG_ALTIVEC does not select CONFIG_PPC_FPU. Would you ever have altivec without a fpu? Signed-off-by: Shawn Landden --- arch/powerpc/include/asm/simd.h | 7 +++ 1 file changed, 7 insertions(+) diff --git

[Bug 203161] ppc64 started failing to build: error: 'MAX_PHYSMEM_BITS' undeclared

2019-05-14 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=203161 Michael Ellerman (mich...@ellerman.id.au) changed: What|Removed |Added Status|RESOLVED|CLOSED

[PATCH] powerpc/mm: Fix crashes with hugepages & 4K pages

2019-05-14 Thread Michael Ellerman
The recent commit to cleanup ifdefs in the hugepage initialisation led to crashes when using 4K pages as reported by Sachin: BUG: Kernel NULL pointer dereference at 0x001c Faulting instruction address: 0xc1d1e58c Oops: Kernel access of bad area, sig: 11 [#1] LE PAGE_SIZE=4K

Re: [PATCH v10 09/12] ima: Implement support for module-style appended signatures

2019-05-14 Thread Mimi Zohar
Hi Thiago, On Thu, 2019-04-18 at 00:51 -0300, Thiago Jung Bauermann wrote: > > @@ -326,6 +356,10 @@ int ima_appraise_measurement(enum ima_hooks func, > case INTEGRITY_UNKNOWN: > break; > case INTEGRITY_NOXATTRS:/* No EVM protected xattrs. */ > +

[v3 1/2] [PowerPC] Add simd.h implementation

2019-05-14 Thread Shawn Landden
Based off the x86 one. WireGuard really wants to be able to do SIMD in interrupts, so it can accelerate its in-bound path. Signed-off-by: Shawn Landden --- arch/powerpc/include/asm/simd.h | 17 + arch/powerpc/kernel/process.c | 30 ++ 2 files

[v3 2/2] [PowerPC] Allow use of SIMD in interrupts from kernel code

2019-05-14 Thread Shawn Landden
This second patch is separate because it could be wrong, like I am not sure about how kernel thread migration works, and it is even allowing simd in preemptible kernel code. Signed-off-by: Shawn Landden --- arch/powerpc/include/asm/switch_to.h | 15 ++- arch/powerpc/kernel/process.c

Re: [PATCH] powerpc/mm: Fix crashes with hugepages & 4K pages

2019-05-14 Thread Christophe Leroy
Le 14/05/2019 à 15:43, Michael Ellerman a écrit : The recent commit to cleanup ifdefs in the hugepage initialisation led to crashes when using 4K pages as reported by Sachin: BUG: Kernel NULL pointer dereference at 0x001c Faulting instruction address: 0xc1d1e58c Oops:

[RFC PATCH v3 08/21] watchdog/hardlockup: Decouple the hardlockup detector from perf

2019-05-14 Thread Ricardo Neri
The current default implementation of the hardlockup detector assumes that it is implemented using perf events. However, the hardlockup detector can be driven by other sources of non-maskable interrupts (e.g., a properly configured timer). Group and wrap in #ifdef CONFIG_HARDLOCKUP_DETECTOR_PERF

[RFC PATCH v3 10/21] watchdog/hardlockup: Add function to enable NMI watchdog on all allowed CPUs at once

2019-05-14 Thread Ricardo Neri
When there are more than one implementation of the NMI watchdog, there may be situations in which switching from one to another is needed (e.g., if the time-stamp counter becomes unstable, the HPET-based NMI watchdog can no longer be used. The perf-based implementation of the hardlockup detector

Re: [PATCH v5 5/8] powerpc/pci/IOV: Add support for runtime enabling the VFs

2019-05-14 Thread Sergey Miroshnichenko
On 4/30/19 9:00 AM, Oliver O'Halloran wrote: > On Mon, 2019-03-11 at 14:52 +0300, Sergey Miroshnichenko wrote: > >> When called within pcibios_sriov_enable(), the pci_sriov_get_totalvfs(pdev) >> returns zero, because the device is yet preparing to enable the VFs. > > I don't think this is

[RFC PATCH 1/3] powerpc/mm: Handle page table allocation failures

2019-05-14 Thread Aneesh Kumar K.V
This fixes the below crash that arises due to not handling page table allocation failures while allocating hugetlb page table. Fixes: e2b3d202d1db ("powerpc: Switch 16GB and 16MB explicit hugepages to a different page table format") Signed-off-by: Aneesh Kumar K.V ---

Re: [PATCH] powerpc/mm: Fix crashes with hugepages & 4K pages

2019-05-14 Thread Aneesh Kumar K.V
Michael Ellerman writes: > The recent commit to cleanup ifdefs in the hugepage initialisation led > to crashes when using 4K pages as reported by Sachin: > > BUG: Kernel NULL pointer dereference at 0x001c > Faulting instruction address: 0xc1d1e58c > Oops: Kernel access of bad

[RFC PATCH v3 07/21] watchdog/hardlockup: Define a generic function to detect hardlockups

2019-05-14 Thread Ricardo Neri
The procedure to detect hardlockups is independent of the underlying mechanism that generates the non-maskable interrupt used to drive the detector. Thus, it can be put in a separate, generic function. In this manner, it can be invoked by various implementations of the NMI watchdog. For this

[RFC PATCH 2/3] powerpc/mm/hugetlb: Fix kernel crash if we fail to allocate page table caches

2019-05-14 Thread Aneesh Kumar K.V
We only check for hugetlb allocations, because with hugetlb we do conditional registration. For PGD/PUD/PMD levels we register them always in pgtable_cache_init. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/mm/hugetlbpage.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff

[RFC PATCH 3/3] powerpc/mm/hugetlb: Don't enable HugeTLB if we don't have a page table cache

2019-05-14 Thread Aneesh Kumar K.V
This makes sure we don't enable HugeTLB if the cache is not configured. I am still not sure about this. IMHO hugetlb support should be a hardware support derivative and any cache allocation failure should be handled as I did in the earlier patch. But then if we were not able to create hugetlb page