Re: [PATCH v2 1/5] powerpc/64s/hash: Fix 128TB-512TB virtual address boundary case allocation

2017-11-12 Thread Nicholas Piggin
On Mon, 13 Nov 2017 10:29:19 +0530 "Aneesh Kumar K.V" wrote: > Nicholas Piggin writes: > > > When allocating VA space with a hint that crosses 128TB, the SLB addr_limit > > variable is not expanded if addr is not > 128TB, but the slice allocation > > looks at task_size, which is 512TB. This res

Re: [PATCHv4 3/6] powerpc64: Add .opd based function descriptor dereference

2017-11-12 Thread Santosh Sivaraj
* Sergey Senozhatsky wrote (on 2017-11-10 08:48:27 +0900): > We are moving towards separate kernel and module function descriptor > dereference callbacks. This patch enables it for powerpc64. > > For pointers that belong to the kernel > - Added __start_opd and __end_opd pointers, to track the

[PATCH] powerpc/perf: Add debugfs interface for imc-mode and imc-command

2017-11-12 Thread Anju T Sudhakar
In memory Collection (IMC) counter pmu driver controls the ucode's execution state. At the system boot, IMC perf driver pause the ucode. Ucode state is changed to "running" only when any of the nest units are monitored or profiled using perf tool.

[PATCH] selftest/mm: Add test for checking mmap across 128TB boundary

2017-11-12 Thread Aneesh Kumar K.V
Signed-off-by: Aneesh Kumar K.V --- tools/testing/selftests/vm/Makefile | 1 + tools/testing/selftests/vm/run_vmtests | 11 ++ tools/testing/selftests/vm/va_128TBswitch.c | 152 3 files changed, 164 insertions(+) create mode 100644 tools/testing/selft

Re: [PATCH] powerpc/perf: Add debugfs interface for imc run-mode and run-status

2017-11-12 Thread Anju T Sudhakar
Hi, Kindly ignore this version Thanks, Anju On Monday 13 November 2017 11:06 AM, Anju T Sudhakar wrote: In memory Collection (IMC) counter pmu driver controls the ucode's execution state. At the system boot, IMC perf driver pause the ucode. Ucode state is changed to "running" only when any of

Re: linux-next: manual merge of the powerpc tree with Linus' tree

2017-11-12 Thread Stephen Rothwell
Hi all, On Mon, 30 Oct 2017 12:51:33 + Mark Brown wrote: > > Hi all, > > Today's linux-next merge of the powerpc tree got a conflict in: > > arch/powerpc/kvm/powerpc.c > > between commit: > > ac64115a66c1 ("KVM: PPC: Fix oops when checking KVM_CAP_PPC_HTM") > > from Linus' tree and c

[PATCH] powerpc/perf: Add debugfs interface for imc run-mode and run-status

2017-11-12 Thread Anju T Sudhakar
In memory Collection (IMC) counter pmu driver controls the ucode's execution state. At the system boot, IMC perf driver pause the ucode. Ucode state is changed to "running" only when any of the nest units are monitored or profiled using perf tool.

Re: [PATCH v2 5/5] powerpc/64s: mm_context.addr_limit is only used on hash

2017-11-12 Thread Aneesh Kumar K.V
Nicholas Piggin writes: > Radix keeps no meaningful state in addr_limit, so remove it from > radix code and rename to slb_addr_limit to make it clear it applies > to hash only. > Reviewed-by: Aneesh Kumar K.V > Signed-off-by: Nicholas Piggin > --- > arch/powerpc/include/asm/book3s/64/mmu-has

Re: [PATCH v2 4/5] powerpc/64s/radix: Fix 128TB-512TB virtual address boundary case allocation

2017-11-12 Thread Aneesh Kumar K.V
Nicholas Piggin writes: > Radix VA space allocations test addresses against mm->task_size which is > 512TB, even in cases where the intention is to limit allocation to below > 128TB. > > This results in mmap with a hint address below 128TB but address + length > above 128TB succeeding when it sho

Re: [PATCH v2 3/5] powerpc/64s/hash: Allow MAP_FIXED allocations to cross 128TB boundary

2017-11-12 Thread Aneesh Kumar K.V
Nicholas Piggin writes: > While mapping hints with a length that cross 128TB are disallowed, > MAP_FIXED allocations that cross 128TB are allowed. These are failing > on hash (on radix they succeed). Add an additional case for fixed > mappings to expand the addr_limit when crossing 128TB. > Revi

Re: [PATCH v2 2/5] powerpc/64s/hash: Fix fork() with 512TB process address space

2017-11-12 Thread Aneesh Kumar K.V
Nicholas Piggin writes: > Hash unconditionally resets the addr_limit to default (128TB) when > the mm context is initialised. If a process has > 128TB mappings when > it forks, the child will not get the 512TB addr_limit, so accesses to > valid > 128TB mappings will fail in the child. > > Fix thi

Re: [PATCH v2 1/5] powerpc/64s/hash: Fix 128TB-512TB virtual address boundary case allocation

2017-11-12 Thread Aneesh Kumar K.V
Nicholas Piggin writes: > When allocating VA space with a hint that crosses 128TB, the SLB addr_limit > variable is not expanded if addr is not > 128TB, but the slice allocation > looks at task_size, which is 512TB. This results in slice_check_fit() > incorrectly succeeding because the slice_coun

Re: [PATCH v2] powerpc/powernv: Add pci_reset_phbs parameter to issue a PHB reset

2017-11-12 Thread Michael Ellerman
"Guilherme G. Piccoli" writes: > During a kdump kernel boot in PowerPC, we request a reset of the PHBs > to the FW. It makes sense, since if we are booting a kdump kernel it > means we had some trouble before and we cannot rely in the adapters' > health; they could be in a bad state, hence the re

RE: [PATCHv4 2/3] ARMv8: layerscape: add the pcie ep function support

2017-11-12 Thread Xiaowei Bao
> -Original Message- > From: Kishon Vijay Abraham I [mailto:kis...@ti.com] > Sent: Friday, November 10, 2017 2:32 PM > To: Xiaowei Bao ; robh...@kernel.org; > mark.rutl...@arm.com; catalin.mari...@arm.com; will.dea...@arm.com; > bhelg...@google.com; shawn...@kernel.org; Madalin-cristian B

RE: [PATCHv4 1/3] ARMv8: dts: ls1046a: add the property of IB and OB

2017-11-12 Thread M.h. Lian
> -Original Message- > From: Leo Li > Sent: Saturday, November 11, 2017 5:21 AM > To: Kishon Vijay Abraham I ; Xiaowei Bao > ; robh...@kernel.org; mark.rutl...@arm.com; > catalin.mari...@arm.com; will.dea...@arm.com; bhelg...@google.com; > shawn...@kernel.org; Madalin-cristian Bucur ; > S

Re: [PATCH v9 23/51] powerpc: Enable pkey subsystem

2017-11-12 Thread Ram Pai
On Mon, Nov 06, 2017 at 12:57:15AM -0800, Ram Pai wrote: > PAPR defines 'ibm,processor-storage-keys' property. It exports two > values. The first value holds the number of data-access keys and the > second holds the number of instruction-access keys. Due to a bug in > the firmware, instruction-ac

Re: [PATCH v9 00/51] powerpc, mm: Memory Protection Keys

2017-11-12 Thread Ram Pai
On Fri, Nov 10, 2017 at 07:10:31PM +0100, Christophe LEROY wrote: > Hi > > Le 06/11/2017 à 09:56, Ram Pai a écrit : > >Memory protection keys enable applications to protect its > >address space from inadvertent access from or corruption > >by itself. > > > >These patches along with the pte-bit fre

Re: [PATCH 2/2] powerpc/fadump: use kstrtoint to handle sysfs store

2017-11-12 Thread Hari Bathini
Thanks for the patch, Michal. On Monday 26 June 2017 07:36 PM, Michal Suchanek wrote: Currently sysfs store handlers in fadump use if buf[0] == 'char'. This means input "100foo" is interpreted as '1' and "01" as '0'. Change to kstrtoint so leading zeroes and the like is handled in expected wa

Re: [PATCH v2 3/8] powerpc/mm: Separate ibm, dynamic-memory data from DT format

2017-11-12 Thread Michael Ellerman
Hi Nathan, Nathan Fontenot writes: > diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c > index f83056297441..917184c13890 100644 > --- a/arch/powerpc/kernel/prom.c > +++ b/arch/powerpc/kernel/prom.c > @@ -454,92 +455,93 @@ static int __init > early_init_dt_scan_chosen_ppc(unsi

Re: [PATCH v2 1/3] powerpc/powernv: Always stop secondaries before reboot/shutdown

2017-11-12 Thread Michael Ellerman
Nicholas Piggin writes: > On Fri, 10 Nov 2017 22:08:32 +1100 > Michael Ellerman wrote: > >> Nicholas Piggin writes: >> >> > Currently powernv reboot and shutdown requests just leave secondaries >> > to do their own things. This is undesirable because they can trigger >> > any number of watchdo