Re: [PATCH] powerpc/xics: Set the IRQ chip data for the ICS native backend

2021-09-13 Thread Gustavo Romero
+0x1f4/0x238 [c1033db0] c000e51c kernel_init+0x28/0x138 [c1033e10] c000b114 ret_from_kernel_thread+0x5c/0x64 mon> Thanks for fixing it Cédric. Tested-by: Gustavo Romero Cheers, Gustavo

Re: [PATCH] powerpc/xics: Set the IRQ chip data for the ICS native backend

2021-09-13 Thread Gustavo Romero
+0x1f4/0x238 [c1033db0] c000e51c kernel_init+0x28/0x138 [c1033e10] c000b114 ret_from_kernel_thread+0x5c/0x64 mon> Thanks for fixing it Cédric. Tested-by: Gustavo Romero Cheers, Gustavo

[PATCH] selftests/powerpc: Add test to check if TM is disabled when it must be

2020-12-14 Thread Gustavo Romero
Add a TM test to check that when TM is not advertised by the OS (is disabled) a transaction can not really be started and generates a SIGILL, which is the right behavior in that case. Signed-off-by: Gustavo Romero --- tools/testing/selftests/powerpc/tm/.gitignore | 1 + tools/testing/selftests

[PATCH v2] powerpc/tm: Save and restore AMR on treclaim and trechkpt

2020-09-19 Thread Gustavo Romero
ater, just before returning from tm_reclaim and __tm_recheckpoint. Is also fixes two nonrelated comments about CR and MSR. Signed-off-by: Gustavo Romero --- arch/powerpc/include/asm/processor.h | 1 + arch/powerpc/kernel/asm-offsets.c| 1 + arch/powerpc/kernel/tm.S

[PATCH] powerpc/tm: Save and restore AMR on treclaim and trechkpt

2020-09-17 Thread Gustavo Romero
ust before returning from tm_reclaim and __tm_recheckpoint. Is also fixes two nonrelated comments about CR and MSR. Signed-off-by: Gustavo Romero --- arch/powerpc/include/asm/paca.h | 1 + arch/powerpc/include/asm/processor.h | 1 + arch/powerpc/kernel/asm-offsets.c| 2 ++ arch/powerpc/k

Re: [PATCH] powerpc/fadump: Fix build error with CONFIG_PRESERVE_FA_DUMP=y

2020-07-29 Thread Gustavo Romero
static atomic_t cpus_in_fadump; static DEFINE_MUTEX(fadump_mutex); + struct fadump_mrange_info crash_mrange_info = { "crash", NULL, 0, 0, 0, false }; #define RESERVED_RNGS_SZ 16384 /* 16K - 128 entries */ Tested-by: Gustavo Romero Thanks, Gustavo

Re: [PATCH] powerpc/powernv/pci: Fix build of pci-ioda.o

2020-07-29 Thread Gustavo Romero
Hi Oliver, On 7/28/20 7:50 PM, Oliver O'Halloran wrote: On Wed, Jul 29, 2020 at 8:35 AM Gustavo Romero wrote: Currently pnv_ioda_setup_bus_dma() is outside of a CONFIG_IOMMU_API guard and if CONFIG_IOMMU_API=n the build can fail if the compiler sets -Werror=unused-function, be

[PATCH] powerpc/powernv/pci: Fix build of pci-ioda.o

2020-07-28 Thread Gustavo Romero
U_API guard, so when CONFIG_IOMMU_API is disabled that function is not defined. Signed-off-by: Gustavo Romero --- arch/powerpc/platforms/powernv/pci-ioda.c | 26 +++ 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/arch/powerpc/platforms/powernv/pci-ioda.c b

Re: powerpc/pci: [PATCH 1/1 V2] PCIE PHB reset

2020-05-15 Thread Gustavo Romero
Hi Xiong, On 5/15/20 5:04 PM, wenxi...@linux.vnet.ibm.com wrote: From: Wen Xiong Several device drivers hit EEH(Extended Error handling) when triggering kdump on Pseries PowerVM. This patch implemented a reset of the PHBs in pci general code. PHB reset stop all PCI transactions from previous k

Re: [PATCH] selftests/powerpc: Always build the tm-poison test 64-bit

2020-04-06 Thread Gustavo Romero
On 04/06/2020 10:06 AM, Michael Ellerman wrote: On Fri, 2020-04-03 at 09:56:56 UTC, Michael Ellerman wrote: The tm-poison test includes inline asm which is 64-bit only, so the test must be built 64-bit in order to work. Otherwise it fails, eg: # file tm-poison tm-poison: ELF 32-bit MSB ex

Re: [PATCH] KVM: PPC: Book3S HV: Fix typos in comments

2020-03-05 Thread Gustavo Romero
Hi Gabriel, On 03/06/2020 01:06 PM, Gabriel Paubert wrote: On Fri, Mar 06, 2020 at 11:26:36AM +1100, Gustavo Romero wrote: Fix typos found in comments about the parameter passed through r5 to kvmppc_{save,restore}_tm_hv functions. Actually "iff" is a common shorthand in some fiel

[PATCH] KVM: PPC: Book3S HV: Fix typos in comments

2020-03-05 Thread Gustavo Romero
Fix typos found in comments about the parameter passed through r5 to kvmppc_{save,restore}_tm_hv functions. Signed-off-by: Gustavo Romero --- arch/powerpc/kvm/book3s_hv_rmhandlers.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/kvm/book3s_hv_rmhandlers.S

[PATCH v3] KVM: PPC: Book3S HV: Treat TM-related invalid form instructions on P9 like the valid ones

2020-02-21 Thread Gustavo Romero
described by treating the TM-related invalid forms that can generate a softpatch interrupt just like their valid forms (w/ bit 31 = 1) instead of as a 'nop' and by gently reporting any other unrecognized case to the host and treating it as illegal instruction instead of throwing a trace

Re: [PATCH] KVM: PPC: Book3S HV: Treat TM-related invalid form instructions on P9 like the valid ones

2020-02-20 Thread Gustavo Romero
Hi Leonardo, Thanks a lot for the review. On 02/20/2020 02:51 PM, Leonardo Bras wrote: +#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt + Could not see where is this used. This is used by pr_warn_ratelimited() below so the module name is printed before the message, for instance: [531454.670909

Re: [PATCH] KVM: PPC: Book3S HV: Treat unrecognized TM instructions as illegal

2020-02-18 Thread Gustavo Romero
Hi, On 02/17/2020 04:37 AM, Segher Boessenkool wrote: On Mon, Feb 17, 2020 at 05:23:07PM +1100, Michael Neuling wrote: Hence, we should NOP this, not generate an illegal. It is not a reserved bit. The IMC entry for it matches op1=01 op2=101110 presumably, which catches all TM instruc

[PATCH] KVM: PPC: Book3S HV: Treat TM-related invalid form instructions on P9 like the valid ones

2020-02-18 Thread Gustavo Romero
described by treating the TM-related invalid forms that can generate a softpatch interrupt just like their valid forms (w/ bit 31 = 1) instead of as a 'nop' and by gently reporting any other unrecognized case to the host and treating it as illegal instruction instead of throwing a

Re: [PATCH] KVM: PPC: Book3S HV: Treat unrecognized TM instructions as illegal

2020-02-13 Thread Gustavo Romero
Hi Segher, Thanks a lot for reviewing it. On 02/13/2020 08:31 PM, Segher Boessenkool wrote: --- arch/powerpc/kvm/book3s_hv_tm.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/arch/powerpc/kvm/book3s_hv_tm.c b/arch/powerpc/kvm/book3s_hv_tm.c index 0db937497169..d3

[PATCH] KVM: PPC: Book3S HV: Treat unrecognized TM instructions as illegal

2020-02-13 Thread Gustavo Romero
of as 'nop' and by gently reporting it to the host instead of throwing a trace. Signed-off-by: Gustavo Romero --- arch/powerpc/kvm/book3s_hv_tm.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/arch/powerpc/kvm/book3s_hv_tm.c b/arch/powerpc/kvm/book3s

Re: [PATCH 1/3] powerpc/tm: Clear the current thread's MSR[TS] after treclaim

2020-01-17 Thread Gustavo Romero
'handle_rt_signal32': /linux/arch/powerpc/kernel/signal_32.c:908:16: error: unused variable 'msr' [-Werror=unused-variable] 908 | unsigned long msr = regs->msr; | ^~~ /linux/arch/powerpc/kernel/signal_32.c: In function 'handle_signal32': /linux/arch/powerpc/kernel/signal_32.c:1367:16: error: unused variable 'msr' [-Werror=unused-variable] 1367 | unsigned long msr = regs->msr; | Feel free to send a v2 only after Mikey's review. Otherwise, LGTM. Reviewed-by: Gustavo Romero Best regards, Gustavo

Re: [PATCH 3/3] selftests/powerpc: Don't rely on segfault to rerun the test

2020-01-17 Thread Gustavo Romero
g_sa, NULL); - - raise(SIGUSR1); } int tm_signal_context_force_tm(void) @@ -169,11 +168,7 @@ int tm_signal_context_force_tm(void) */ SKIP_IF(!is_ppc64le()); - /* Will get back here after COUNT_MAX interactions */ - getcontext(&main_context); - - if (!first_time++) -

Re: [PATCH 2/3] selftests/powerpc: Add tm-signal-pagefault test

2020-01-17 Thread Gustavo Romero
"1: ;" + : : : "memory"); + + return EXIT_SUCCESS; +} + +int main(int argc, char **argv) +{ + /* +* Depending on kernel config, the TM Bad Thing might not result in a +* crash, instead the kernel never returns control back to userspace, so +* set a tight timeout. If the test passes it completes almost +* immediately. +*/ + test_harness_set_timeout(2); + return test_harness(tm_signal_pagefault, "tm_signal_pagefault"); +} Reviewed-by: Gustavo Romero Best regards, Gustavo

Re: [PATCH 3/3] powerpc/tm: Add tm-poison test

2019-09-03 Thread Gustavo Romero
Hi Michael, On 09/03/2019 08:46 AM, Michael Ellerman wrote: Michael Neuling writes: From: Gustavo Romero Add TM selftest to check if FP or VEC register values from one process can leak into another process when both run on the same CPU. This tests for CVE-2019-15030 and CVE-2019-15031

[PATCH] selftests/powerpc: Retry on host facility unavailable

2019-08-20 Thread Gustavo Romero
-off-by: Gustavo Romero --- tools/testing/selftests/powerpc/tm/tm.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/testing/selftests/powerpc/tm/tm.h b/tools/testing/selftests/powerpc/tm/tm.h index 97f9f49..c402464 100644 --- a/tools/testing/selftests/powerpc/tm/tm.h

[PATCH 2/2] selftests/powerpc: Ignore generated files

2019-08-15 Thread Gustavo Romero
ned-off-by: Gustavo Romero --- tools/testing/selftests/powerpc/copyloops/.gitignore | 8 tools/testing/selftests/powerpc/ptrace/.gitignore | 3 +++ tools/testing/selftests/powerpc/security/.gitignore| 1 + tools/testing/selftests/powerpc/stringloops/.gitignore | 5 - 4 fil

[PATCH 1/2] powerpc: Document xmon options

2019-08-15 Thread Gustavo Romero
Document all options currently supported by xmon debugger. Signed-off-by: Gustavo Romero --- .../admin-guide/kernel-parameters.txt | 19 +++ 1 file changed, 19 insertions(+) diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel

[PATCH] powerpc/selftests: Fix and enhance TM signal context tests

2019-08-15 Thread Gustavo Romero
ntext) == 0xfbfffafff9fff8ff instead of 0x0005000600070008 (expected) failure: tm_signal_context_chk_vsx Finally, this commit adds comments to the tests in the hope that it will help people not so familiar with TM understand the tests. Signed-off-by: Gustavo R

[PATCH] selftests/powerpc: Fix earlyclobber in tm-vmxcopy

2019-06-17 Thread Gustavo Romero
as an earlyclobber operand so it may not overlap an input operand ('vecoutptr'). Signed-off-by: Gustavo Romero --- tools/testing/selftests/powerpc/tm/tm-vmxcopy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/testing/selftests/powerpc/tm/tm-vmxcopy.c b/too

Re: It looks like that wild_bctr on powerpc/fixes is still not compiling

2018-11-14 Thread Gustavo Romero
Hi Michael, On 11/13/2018 10:58 PM, Michael Ellerman wrote: It looks like binutils 2.27 doesn't accept ULL but binutils 2.28 does. Ah yep, here: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commit;h=86b80085c889cd388fa677a5ae9053fd4be3776c The following trivial workaround c

[PATCH v2] selftests/powerpc: Adjust wild_bctr to build with old gcc

2018-11-14 Thread Gustavo Romero
the shifts on compilation but the UL suffix is absent on the stringification, so the inline asm code generated has no UL suffixes. Signed-off-by: Gustavo Romero --- tools/testing/selftests/powerpc/mm/wild_bctr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/test

[PATCH] selftests/powerpc: Adjust wild_bctr to build with old gcc

2018-11-14 Thread Gustavo Romero
ens but the UL suffix is absent on the stringification, so the inline asm code generated has no UL suffixes. Signed-off-by: Gustavo Romero --- tools/testing/selftests/powerpc/mm/wild_bctr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/testing/selftests/powerpc

It looks like that wild_bctr on powerpc/fixes is still not compiling

2018-11-13 Thread Gustavo Romero
Hi mpe, Even after the latest fix for the wild_bctr selftest I'm still getting the following compilation (actually, an assembling error) because UL is not understood by the assembler: BUILD_TARGET=/home/gromero/git/linux/tools/testing/selftests/powerpc/mm; mkdir -p $BUILD_TARGET; make OUTPUT=$B

Re: Looking for architecture papers

2018-10-08 Thread Gustavo Romero
Hi Raz, On 10/04/2018 04:41 AM, Raz wrote: Frankly, the more I read the more perplexed I get. For example, according to BOOK III-S, chapter 3, the MSR bits are differ from the ones described in arch/powerpc/include/asm/reg.h. Bit zero, is LE, but in the book it is 64-bit mode. Would someone be

Re: [PATCH] selftests/powerpc: Do not fail on TM_CAUSE_RESCHED

2018-08-28 Thread Gustavo Romero
itwise operator. Otherwise it LGTM. Reviewed-by: Gustavo Romero Best regards, Gustavo

Re: [PATCH 2/3] selftests/powerpc: Only run some tests on ppc64le

2018-07-30 Thread Gustavo Romero
Hi Michael, On 07/27/2018 02:51 AM, Michael Ellerman wrote: Gustavo Romero writes: Hi Michael, On 07/26/2018 09:24 AM, Michael Ellerman wrote: These tests are currently failing on (some) big endian systems. Until we can fix that, skip them unless we're on ppc64le. I can take a lo

Re: [PATCH 2/3] selftests/powerpc: Only run some tests on ppc64le

2018-07-26 Thread Gustavo Romero
Hi Michael, On 07/26/2018 09:24 AM, Michael Ellerman wrote: These tests are currently failing on (some) big endian systems. Until we can fix that, skip them unless we're on ppc64le. I can take a look at this. Is that the same issue related to the gcc version we discussed a month ago? If not,

Re: [PATCH 6/7] powerpc/traps: Print signal name for unhandled signals

2018-07-25 Thread Gustavo Romero
Hi Murilo, LGTM. Just a comment: On 07/24/2018 04:27 PM, Murilo Opsfelder Araujo wrote: This adds a human-readable name in the unhandled signal message. Before this patch, a page fault looked like: Jul 11 16:04:11 localhost kernel: pandafault[6303]: unhandled signal 11 at 1

Re: [PATCH] powerpc/64s: Fix NULL AT_BASE_PLATFORM when using DT CPU features

2018-03-23 Thread Gustavo Romero
Hi Yi, On 03/14/2018 05:34 AM, Li Yi (Adam) wrote: So set it in the DT CPU features code also. This results in eg: $ LD_SHOW_AUXV=1 /bin/true | grep "AT_.*PLATFORM" AT_PLATFORM: power9 AT_BASE_PLATFORM:power9 Is this issue related with DD2.2 CPU? I tested on a Boston system with

Re: [PATCH] selftests/powerpc: Skip tm-unavailable if TM is not enabled

2018-03-06 Thread Gustavo Romero
Hi Cyril, On 03/05/2018 08:49 PM, Cyril Bur wrote: > On Mon, 2018-03-05 at 15:48 -0500, Gustavo Romero wrote: >> Some processor revisions do not support transactional memory, and >> additionally kernel support can be disabled. In either case the >> tm-unavailable test should

[PATCH] selftests/powerpc: Skip tm-unavailable if TM is not enabled

2018-03-05 Thread Gustavo Romero
e for other TM selftests. Finally, it avoids using "ping" as a thread name since it's ambiguous and can be confusing when shown, for instance, in a kernel backtrace log. Fixes: 77fad8bfb1d2 ("selftests/powerpc: Check FP/VEC on exception in TM") Signed-off-by: Gustavo Rome

[PATCH] Fixes for selftest tm-unavailable

2018-03-05 Thread Gustavo Romero
commit/?id=192b2e742c06af399e8eecb4a17265 [2] https://lists.ozlabs.org/pipermail/linuxppc-dev/2018-February/169111.html Gustavo Romero (1): selftests/powerpc: Skip tm-unavailable if TM is not enabled .../testing/selftests/powerpc/tm/tm-unavailable.c | 24 ++ 1 file changed, 16 insertions(+), 8

Re: [PATCH 00/26] KVM: PPC: Book3S PR: Transaction memory support on PR KVM

2018-01-11 Thread Gustavo Romero
Hi Simon, On 01/11/2018 08:11 AM, wei.guo.si...@gmail.com wrote: > From: Simon Guo > > In current days, many OS distributions have utilized transaction > memory functionality. In PowerPC, HV KVM supports TM. But PR KVM > does not. > > The drive for the transaction memory support of PR KVM is th

[PATCH 2/2] powerpc/selftests: Check endianness on trap in TM

2017-12-31 Thread Gustavo Romero
Add a selftest to check if endianness is flipped inadvertently to BE (MSR.LE set to zero) on BE and LE machines when a trap is caught in transactional mode and load_fp and load_vec are zero, i.e. when MSR.FP and MSR.VEC are zeroed (disabled). Signed-off-by: Gustavo Romero --- tools/testing

[PATCH 1/2] powerpc/tm: Fix endianness flip on trap

2017-12-31 Thread Gustavo Romero
>msr. The fix was tested both on LE and BE machines and no regression regarding the powerpc/tm selftests was observed. Signed-off-by: Gustavo Romero --- arch/powerpc/kernel/signal_64.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/arch/powerpc/kernel/signal_64

Re: [PATCH 2/2] selftests/powerpc: Calculate spin time in tm-unavailable

2017-11-21 Thread Gustavo Romero
Hi Cyril, On 21-11-2017 05:17, Cyril Bur wrote: > Currently the tm-unavailable test spins for a fixed amount of time in > an attempt to ensure the FPU/VMX/VSX facilities are off. This value was > experimentally tested to be long enough. > > Problems may arise if kernel heuristics were to change.

Re: [PATCH 1/2] selftests/powerpc: Check for pthread errors in tm-unavailable

2017-11-21 Thread Gustavo Romero
Hi Cyril, Thanks for adding the checks! On 21-11-2017 05:17, Cyril Bur wrote: > Signed-off-by: Cyril Bur Signed-off-by: Gustavo Romero Cheers, Gustavo > --- > .../testing/selftests/powerpc/tm/tm-unavailable.c | 43 > +- > 1 file changed, 34 insertions(

Re: [PATCH] selftests/powerpc: Check FP/VEC on exception in TM

2017-11-03 Thread Gustavo Romero
re did not happen, like: Checking if FP/VEC registers are sane after a FP unavailable exception... If MSR.FP=0 MSR.VEC=0: Expecting the transaction to fail, but it didn't FP ok VEC ok ... So it won't let the hurting change pass fine silently :-) >> Signed-off-by: Gusta

[PATCH] selftests/powerpc: Check FP/VEC on exception in TM

2017-11-01 Thread Gustavo Romero
/VSX unavailable exception in transactional state, verifying if vs0 and vs32 registers, which are representatives of FP/VEC/VSX reg sets, are not corrupted. Signed-off-by: Gustavo Romero Signed-off-by: Breno Leitao Signed-off-by: Cyril Bur --- tools/testing/selftests/powerpc/tm/Makefile

Re: [PATCH 2/3] powerpc/tm: P9 disabled suspend mode workaround

2017-10-06 Thread Gustavo Romero
Hi Cyril, On 06-10-2017 04:46, Cyril Bur wrote: > [added by Cyril Bur] > As the no-suspend firmware change is novel and untested using it should > be opt in by users. Furthumore, currently the kernel has no method to I forgot to mention on my last reply, but should s/Furthumore/Furthermore/ ? Re

Re: [PATCH 3/3] powerpc/tm: P9 disable transactionally suspended sigcontexts

2017-10-06 Thread Gustavo Romero
Hi Cyril, On 06-10-2017 04:46, Cyril Bur wrote: > From: Michael Neuling > > Unfortunately userspace can construct a sigcontext which enables > suspend. Thus userspace can force Linux into a path where trechkpt is > executed. > > This patch blocks this from happening on POWER9 but sanity checkin

[PATCH v2] powerpc/tm: Flush TM only if CPU has TM feature

2017-09-13 Thread Gustavo Romero
d, like in vsr_get() and vsr_set(), is better because avoids the same problem cropping up elsewhere. Cc: sta...@vger.kernel.org # v4.13+ Fixes: cd63f3c ("powerpc/tm: Fix saving of TM SPRs in core dump") Signed-off-by: Gustavo Romero --- arch/powerpc/kernel/ptrace.c | 2 +- 1 file change

[PATCH] powerpc/tm: Flush TM only if CPU has TM feature

2017-09-13 Thread Gustavo Romero
d, like in vsr_get() and vsr_set(), is better because avoids the same problem cropping up elsewhere. Cc: sta...@vger.kernel.org # v4.13+ Fixes: cd63f3c ("powerpc/tm: Fix saving of TM SPRs in core dump") Signed-off-by: Gustavo Romero --- arch/powerpc/kernel/ptrace.c | 4 +++- 1 file c

[PATCH] powerpc/tm: fix TM SPRs in code dump file

2017-07-18 Thread Gustavo Romero
ssary. Signed-off-by: Gustavo Romero --- arch/powerpc/kernel/ptrace.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/kernel/ptrace.c b/arch/powerpc/kernel/ptrace.c index 925a4ef..660ed39 100644 --- a/arch/powerpc/kernel/ptrace.c +++ b/arch/powerpc/k

Re: Kernel build issues with upstream binutils

2017-07-17 Thread Gustavo Romero
No sure if in reply-to took correct effect, so I'm posting the thread ref explicit: https://lists.ozlabs.org/pipermail/linuxppc-dev/2016-November/151672.html On 17-07-2017 09:57, Gustavo Romero wrote: > Hi, > > On bissecting kernel on Debian (gcc version 6.3.0 20170516) I&#

Re: Kernel build issues with upstream binutils

2017-07-17 Thread Gustavo Romero
Hi, On bissecting kernel on Debian (gcc version 6.3.0 20170516) I've got the same error on linking kernels <= v4.9 as reported previously in this thread: ld: arch/powerpc/boot/zImage.pseries: Not enough room for program headers, try linking with -N ld: final link failed: Bad value arch/powerpc/b

Re: [bug] KVM: Unrecoverable TM Unavailable Exception f60

2017-07-13 Thread Gustavo Romero
Hi Jan On 13-07-2017 09:07, Jan Stancek wrote: >> [ 181.328511] Unrecoverable TM Unavailable Exception f60 at d0001e7d9980 >> [ 181.328605] Oops: Unrecoverable TM Unavailable Exception, sig: 6 [#1] >> [ 181.328613] SMP NR_CPUS=2048 >> [ 181.328613] NUMA >> [ 181.328618] PowerNV >> [ 181.

[PATCH] powerpc/tm: fix live state of vs0/32 in tm_reclaim

2017-07-04 Thread Gustavo Romero
to ckpt_regs.msr and so ckpt_regs.msr reflects exactly the MSR that the thread had when it came off the processor. No regression was observed on powerpc/tm selftests after this fix. Signed-off-by: Gustavo Romero Signed-off-by: Breno Leitao --- arch/powerpc/kernel/process.c | 9 +++-- a

[PATCH 2/2] powerpc/tm: test for regs sanity in VSX exception

2017-06-29 Thread Gustavo Romero
Add a test to check if FP/VSX registers are sane (restored correctly) after a VSX unavailable exception is caught in the middle of a transaction. Signed-off-by: Gustavo Romero Signed-off-by: Breno Leitao --- tools/testing/selftests/powerpc/tm/Makefile| 3 +- .../testing/selftests

[PATCH 1/2] powerpc/tm: fix live state of vs0/32 in tm_reclaim

2017-06-29 Thread Gustavo Romero
not reflect the MSR state in userspace. No regression was observed on powerpc/tm selftests after this fix. Signed-off-by: Gustavo Romero Signed-off-by: Breno Leitao --- arch/powerpc/kernel/process.c | 15 --- arch/powerpc/kernel/tm.S | 16 2 files changed,

[RFC] Fix si->si_code for guard page access on PowerPC

2016-01-22 Thread Gustavo Romero
ack has no permission to rd/wr and reaching the stack limit (stack ulimit), although indeed there is a difference. Signed-off-by: Gustavo Romero --- arch/powerpc/mm/fault.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/powerpc/mm/fault.c b/arch/powerpc/mm/fault.