[PATCH v6 0/2] KVM: PPC: Add FWNMI support for KVM guests on POWER

2017-02-05 Thread Mahesh J Salgaonkar
From: Aravinda Prasad This series of patches add FWNMI support for KVM guests on POWER. Memory errors such as bit flips that cannot be corrected by hardware is passed on to the kernel for handling by raising machine check exception (an NMI). Upon such machine check exceptions, if the address in

[PATCH v6 1/2] KVM: PPC: Add new capability to control MCE behaviour

2017-02-05 Thread Mahesh J Salgaonkar
From: Aravinda Prasad This patch introduces a new KVM capability to control how KVM behaves on machine check exception (MCE). Without this capability, KVM redirects machine check exceptions to guest's 0x200 vector, if the address in error belongs to the guest. With this capability KVM causes a gu

[PATCH v6 2/2] KVM: PPC: Exit guest upon MCE when FWNMI capability is enabled

2017-02-05 Thread Mahesh J Salgaonkar
From: Aravinda Prasad Enhance KVM to cause a guest exit with KVM_EXIT_NMI exit reason upon a machine check exception (MCE) in the guest address space if the KVM_CAP_PPC_FWNMI capability is enabled (instead of delivering a 0x200 interrupt to guest). This enables QEMU to build error log and deliver

Re: Timekeeping oddities on MacMini G4s

2017-02-05 Thread Frank Nicholas
I’ve had mine apart many times (for memory upgrade, sensors for use in a vehicle, etc. - http://mt.nfshost.com ) Tell me what to look for, and I’ll take as many hi-res pictures as you want. Thanks, Frank > On Feb 4, 2017, at 10:32 PM, Hal Murray wrote: > > Mumble. If it were easier to take a

Re: Timekeeping oddities on MacMini G4s

2017-02-05 Thread Benjamin Herrenschmidt
On Sat, 2017-02-04 at 16:19 -0800, Fred Wright wrote: > On Tue, 31 Jan 2017, Hal Murray wrote: > > > > b...@kernel.crashing.org said: > > > Right, we just use the value provided by Open Firmware. Any chance you can > > That seems inconsistent with the following comment in > arch/powerpc/kernel/ti

[PATCH] powerpc/mm: Fix typo in set_pte_at()

2017-02-05 Thread Gavin Shan
This fixes the typo about the _PAGE_PTE in set_pte_at() by changing "tryint" to "trying to". Fixes: 6a119eae942 ("powerpc/mm: Add a _PAGE_PTE bit") Signed-off-by: Gavin Shan --- arch/powerpc/mm/pgtable.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/arch/powerpc/mm/pgtab

[PATCH] cxl: fix nested locking hang during EEH hotplug

2017-02-05 Thread Andrew Donnellan
Commit 14a3ae34bfd0 ("cxl: Prevent read/write to AFU config space while AFU not configured") introduced a rwsem to fix an invalid memory access that occurred when someone attempts to access the config space of an AFU on a vPHB whilst the AFU is deconfigured, such as during EEH recovery. It turns o

Re: [v2] cxl: prevent read/write to AFU config space while AFU not configured

2017-02-05 Thread Andrew Donnellan
On 27/01/17 11:57, Andrew Donnellan wrote: On 27/01/17 11:40, Michael Ellerman wrote: Applied to powerpc next, thanks. https://git.kernel.org/powerpc/c/14a3ae34bfd0bcb1cc12d55b06a858 Will fix the remaining locking issue in a follow up patch... Stable team - please make sure this doesn't go

[PATCH] powerpc: Fix holes in DD1 TLB workarounds

2017-02-05 Thread Benjamin Herrenschmidt
This patch gets rid of the the TLB multihits observed in the lab. Sadly it does disable whatever remaining optimizations we had for TLB invalidations. It fixes 2 problems: - We do sadly need to invalidate in radix__pte_update() even when the new pte is clear because what might happen otherwise i

[PATCH] powerpc/mm/radix: Update ERAT flushes when invalidating TLB

2017-02-05 Thread Benjamin Herrenschmidt
Three tiny changes to the ERAT flushing logic: First don't make it depend on DD1. It hasn't been decided yet but we might run DD2 in a mode that also requires explicit flushes for performance reasons so make it unconditional. We also add a missing isync, and finally remove the flush from _tlbiel_va

Re: Timekeeping oddities on MacMini G4s

2017-02-05 Thread Segher Boessenkool
On Mon, Feb 06, 2017 at 10:22:01AM +1100, Benjamin Herrenschmidt wrote: > >   On the plus side, that means that the values are guaranteed not > > to be core-specific.  On the minus side, it means that its count rate is > > lower, and it's sufficiently "distant" that accessing it is somewhat more >

Re: [PATCH] powerpc/mm: Fix typo in set_pte_at()

2017-02-05 Thread Aneesh Kumar K.V
Gavin Shan writes: > This fixes the typo about the _PAGE_PTE in set_pte_at() by changing > "tryint" to "trying to". > > Fixes: 6a119eae942 ("powerpc/mm: Add a _PAGE_PTE bit") I guess this is not needed. We add that when we want to hint whether the patch needs backporting. > Signed-off-by: Gav

Re: [PATCH] powerpc/mm: fix a hardcode on memory boundary checking

2017-02-05 Thread Rui Teng
On 31/01/2017 5:11 PM, Michael Ellerman wrote: Rui Teng writes: The offset of hugepage block will not be 16G, if the expected page is more than one. Calculate the totol size instead of the hardcode value. I assume you found this by code inspection and not by triggering an actual bug? Yes,

[PATCH 1/2] powerpc/powernv: Add XHCI and USB storage to defconfig

2017-02-05 Thread Michael Neuling
These are common on bare metal machines, so put them in the defconfig. This adds 216KB to the vmlinux size Signed-off-by: Michael Neuling --- arch/powerpc/configs/powernv_defconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/powerpc/configs/powernv_defconfig b/ar

[PATCH 2/2] powerpc/powernv: Add more BPF in defconfig

2017-02-05 Thread Michael Neuling
This enables BCC (https://github.com/iovisor/bcc) on powernv. This adds 225KB to the vmlinux size. Signed-off-by: Michael Neuling --- arch/powerpc/configs/powernv_defconfig | 5 + 1 file changed, 5 insertions(+) diff --git a/arch/powerpc/configs/powernv_defconfig b/arch/powerpc/configs/po

Re: [PATCH] powerpc/mm: Fix typo in set_pte_at()

2017-02-05 Thread Gavin Shan
On Mon, Feb 06, 2017 at 08:03:57AM +0530, Aneesh Kumar K.V wrote: >Gavin Shan writes: > >> This fixes the typo about the _PAGE_PTE in set_pte_at() by changing >> "tryint" to "trying to". >> >> Fixes: 6a119eae942 ("powerpc/mm: Add a _PAGE_PTE bit") > >I guess this is not needed. We add that when we

[PATCH] powerpc/opal-irqchip: Use interrupt names if present

2017-02-05 Thread Benjamin Herrenschmidt
Recent versions of OPAL can provide names for the various OPAL interrupts, so let's use them. This also modernises the code that fetches the interrupt array to use the helpers provided by the generic code instead of hand-parsing the property. Signed-off-by: Benjamin Herrenschmidt --- arch/powerp

Re: Timekeeping oddities on MacMini G4s

2017-02-05 Thread Hal Murray
> Tell me what to look for, and I’ll take as many hi-res pictures as you want. I'm looking for the frequency printed on the oscillator/crystal. Here is a picture with several examples: https://en.wikipedia.org/wiki/File:Crystal_Packages.jpg The row of Oscillators is most likely. They also c

RE: [PATCH v3 2/2] cpufreq: qoriq: Don't look at clock implementation details

2017-02-05 Thread Y.T. Tang
> -Original Message- > From: Leo Li [mailto:pku@gmail.com] > Sent: Friday, February 03, 2017 2:12 AM > To: Y.T. Tang > Cc: Scott Wood ; Michael Turquette > ; Russell King ; > Stephen Boyd ; Viresh Kumar > ; Rafael J. Wysocki ; linux- > c...@vger.kernel.org; linux...@vger.kernel.org; li

Re: [tip:sched/core] sched/core: Add debugging code to catch missing update_rq_clock() calls

2017-02-05 Thread Sachin Sant
>>> I've seen it on tip. It looks like hot unplug goes really slow when >>> there's running tasks on the CPU being taken down. >>> >>> What I did was something like: >>> >>> taskset -p $((1<<1)) $$ >>> for ((i=0; i<20; i++)) do while :; do :; done & done >>> >>> taskset -p $((1<<0)) $$ >>>