Re: [PATCH 1/2] powerpc/64s: remove PROT_SAO support

2020-08-18 Thread Shawn Anastasio
On 8/18/20 2:11 AM, Nicholas Piggin wrote> Very reasonable point. The problem we're trying to get a handle on is live partition migration where a running guest might be using SAO then get migrated to a P10. I don't think we have a good way to handle this case. Potentially the hypervisor could re

Re: [PATCH v2 11/25] powerpc/signal: Refactor bad frame logging

2020-08-18 Thread Joe Perches
On Tue, 2020-08-18 at 17:19 +, Christophe Leroy wrote: > The logging of bad frame appears half a dozen of times > and is pretty similar. [] > diff --git a/arch/powerpc/kernel/signal.c b/arch/powerpc/kernel/signal.c [] > @@ -355,3 +355,14 @@ static unsigned long get_tm_stackpointer(struct > tas

[PATCH 3/3] powerpc/smp: Move ppc_md.cpu_die() to smp_ops.cpu_offline_self()

2020-08-18 Thread Michael Ellerman
We have smp_ops->cpu_die() and ppc_md.cpu_die(). One of them offlines the current CPU and one offlines another CPU, can you guess which is which? Also one is in smp_ops and one is in ppc_md? So rename ppc_md.cpu_die(), to cpu_offline_self(), because that's what it does. And move it into smp_ops wh

[PATCH 2/3] powerpc/smp: Fold cpu_die() into its only caller

2020-08-18 Thread Michael Ellerman
Avoid the eternal confusion between cpu_die() and __cpu_die() by removing the former, folding it into its only caller. Signed-off-by: Michael Ellerman --- arch/powerpc/include/asm/smp.h | 1 - arch/powerpc/kernel/smp.c | 4 2 files changed, 5 deletions(-) diff --git a/arch/powerpc/inc

[PATCH 1/3] powerpc: Move arch_cpu_idle_dead() into smp.c

2020-08-18 Thread Michael Ellerman
arch_cpu_idle_dead() is in idle.c, which makes sense, but it's inside a CONFIG_HOTPLUG_CPU block. It would be more at home in smp.c, inside the existing CONFIG_HOTPLUG_CPU block. Note that CONFIG_HOTPLUG_CPU depends on CONFIG_SMP so even though smp.c is not built for SMP=n builds, that's fine. Si

[PATCH] powerpc/64: Remove unused generic_secondary_thread_init()

2020-08-18 Thread Michael Ellerman
The last caller was removed in 2014 in commit fb5a515704d7 ("powerpc: Remove platforms/wsp and associated pieces"). As Jordan noticed even though there are no callers, the code above in fsl_secondary_thread_init() falls through into generic_secondary_thread_init(). So we can remove the _GLOBAL but

[PATCH 1/9] selftests/powerpc: Make using_hash_mmu() work on Cell & PowerMac

2020-08-18 Thread Michael Ellerman
These platforms don't show the MMU in /proc/cpuinfo, but they always use hash, so teach using_hash_mmu() that. Signed-off-by: Michael Ellerman --- tools/testing/selftests/powerpc/utils.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/testing/selftests/powerpc/utils.

[PATCH 2/9] selftests/powerpc: Give the bad_accesses test longer to run

2020-08-18 Thread Michael Ellerman
On older systems this test takes longer to run (duh), give it five minutes which is long enough on a G5 970FX @ 1.6GHz. Signed-off-by: Michael Ellerman --- tools/testing/selftests/powerpc/mm/bad_accesses.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/testing/selftests/powerpc/mm/bad

[PATCH 4/9] selftests/powerpc: Include asm/cputable.h from utils.h

2020-08-18 Thread Michael Ellerman
utils.h provides have_hwcap() and have_hwcap2() which check for a feature bit. Those bits are defined in asm/cputable.h, so include it in utils.h so users of utils.h don't have to do it manually. Signed-off-by: Michael Ellerman --- tools/testing/selftests/powerpc/alignment/alignment_handler.c |

[PATCH 3/9] selftests/powerpc: Move set_dscr() into rfi_flush.c

2020-08-18 Thread Michael Ellerman
This version of set_dscr() was added for the RFI flush test, and is fairly specific to it. It also clashes with the version of set_dscr() in dscr/dscr.h. So move it into the RFI flush test where it's used. Signed-off-by: Michael Ellerman --- .../testing/selftests/powerpc/include/utils.h | 1 -

[PATCH 5/9] selftests/powerpc: Don't run DSCR tests on old systems

2020-08-18 Thread Michael Ellerman
The DSCR tests fail on systems that don't have DSCR, so check for the DSCR in hwcap and skip if it's not present. Signed-off-by: Michael Ellerman --- tools/testing/selftests/powerpc/dscr/Makefile | 2 +- tools/testing/selftests/powerpc/dscr/dscr_default_test.c | 2 ++ tools/

[PATCH 6/9] selftests/powerpc: Skip security tests on older CPUs

2020-08-18 Thread Michael Ellerman
Both these tests use PMU events that only work on newer CPUs, so skip them on older CPUs. Signed-off-by: Michael Ellerman --- tools/testing/selftests/powerpc/security/rfi_flush.c | 3 +++ tools/testing/selftests/powerpc/security/spectre_v2.c | 3 +++ 2 files changed, 6 insertions(+) diff --git

[PATCH 7/9] selftests/powerpc: Skip L3 bank test on older CPUs

2020-08-18 Thread Michael Ellerman
This is a test of specific piece of logic in isa207-common.c, which is only used on Power8 or later. So skip it on older CPUs. Signed-off-by: Michael Ellerman --- tools/testing/selftests/powerpc/pmu/l3_bank_test.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/testing/selftests/pow

[PATCH 8/9] selftests/powerpc: Don't touch VMX/VSX on older CPUs

2020-08-18 Thread Michael Ellerman
If we're running on a CPU without VMX/VSX then don't touch them. This is fragile, the compiler could spill a VMX/VSX register and break the test anyway. But in practice it seems to work, ie. the test runs to completion on a system without VSX with this change. Signed-off-by: Michael Ellerman ---

[PATCH 9/9] selftests/powerpc: Properly handle failure in switch_endian_test

2020-08-18 Thread Michael Ellerman
On older CPUs the switch_endian() syscall doesn't work. Currently that causes the switch_endian_test to just crash. Instead detect the failure and properly exit with a failure message. Signed-off-by: Michael Ellerman --- .../switch_endian/switch_endian_test.S| 23 +++ 1 f

[PATCH v3] soc: fsl: enable acpi support

2020-08-18 Thread Ran Wang
From: Peng Ma This patch enables ACPI support in RCPM driver. Signed-off-by: Peng Ma Signed-off-by: Ran Wang --- Change in v3: - Add #ifdef CONFIG_ACPI for acpi_device_id - Rename rcpm_acpi_imx_ids to rcpm_acpi_ids Change in v2: - Update acpi_device_id to fix conflict with other driver d

Re: [Virtual ppce500] virtio_gpu virtio0: swiotlb buffer is full

2020-08-18 Thread Gerd Hoffmann
On Tue, Aug 18, 2020 at 04:41:38PM +0200, Christian Zigotzky wrote: > Hello Gerd, > > I compiled a new kernel with the latest DRM misc updates today. The patch is > included in these updates. > > This kernel works with the VirtIO-GPU in a virtual e5500 QEMU/KVM HV machine > on my X5000. > > Unfo

Re: [PATCH v3] powerpc/pseries/svm: Allocate SWIOTLB buffer anywhere in memory

2020-08-18 Thread Christoph Hellwig
On Tue, Aug 18, 2020 at 07:11:26PM -0300, Thiago Jung Bauermann wrote: > POWER secure guests (i.e., guests which use the Protection Execution > Facility) need to use SWIOTLB to be able to do I/O with the hypervisor, but > they don't need the SWIOTLB memory to be in low addresses since the > hypervi

Re: [PATCH] powerpc/pseries: Do not initiate shutdown when system is running on UPS

2020-08-18 Thread Vasant Hegde
On 8/19/20 1:05 AM, Tyrel Datwyler wrote: On 8/18/20 3:54 AM, Vasant Hegde wrote: As per PAPR specification whenever system is running on UPS we have to wait for predefined time (default 10mins) before initiating shutdown. The wording in PAPR seems a little unclear. It states for an EPOW_SYSTE

[PATCH net-next 0/5] refactoring of ibmvnic code

2020-08-18 Thread Lijun Pan
This patch series refactor reset_init and init functions, improve the debugging messages, and make some other cosmetic changes to make the code easier to read and debug. Lijun Pan (5): ibmvnic: print caller in several error messages ibmvnic: compare adapter->init_done_rc with more readable

[PATCH net-next 2/5] ibmvnic: compare adapter->init_done_rc with more readable ibmvnic_rc_codes

2020-08-18 Thread Lijun Pan
Instead of comparing (adapter->init_done_rc == 1), let it be (adapter->init_done_rc == PARTIALSUCCESS). Signed-off-by: Lijun Pan --- drivers/net/ethernet/ibm/ibmvnic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/i

[PATCH net-next 1/5] ibmvnic: print caller in several error messages

2020-08-18 Thread Lijun Pan
The error messages in the changed functions are exactly the same. In order to differentiate them and make debugging easier, we print the function names in the error messages. Signed-off-by: Lijun Pan --- drivers/net/ethernet/ibm/ibmvnic.c | 14 +++--- 1 file changed, 7 insertions(+), 7 d

[PATCH net-next 3/5] ibmvnic: improve ibmvnic_init and ibmvnic_reset_init

2020-08-18 Thread Lijun Pan
When H_SEND_CRQ command returns with H_CLOSED, it means the server's CRQ is not ready yet. Instead of resetting immediately, we wait for the server to launch passive init. ibmvnic_init() and ibmvnic_reset_init() should also return the error code from ibmvnic_send_crq_init() call. Signed-off-by: Li

[PATCH net-next 4/5] ibmvnic: remove never executed if statement

2020-08-18 Thread Lijun Pan
At the beginning of the function, from_passive_init is set false by "adapter->from_passive_init = false;", hence the if statement will never run. Signed-off-by: Lijun Pan --- drivers/net/ethernet/ibm/ibmvnic.c | 12 1 file changed, 12 deletions(-) diff --git a/drivers/net/ethernet/

[PATCH net-next 5/5] ibmvnic: merge ibmvnic_reset_init and ibmvnic_init

2020-08-18 Thread Lijun Pan
These two functions share the majority of the code, hence merge them together. In the meanwhile, add a reset pass-in parameter to differentiate them. Thus, the code is easier to read and to tell the difference between reset_init and regular init. Signed-off-by: Lijun Pan --- drivers/net/ethernet

Re: fsl_espi errors on v5.7.15

2020-08-18 Thread Heiner Kallweit
On 19.08.2020 00:44, Chris Packham wrote: > Hi Again, > > On 17/08/20 9:09 am, Chris Packham wrote: > >> >> On 14/08/20 6:19 pm, Heiner Kallweit wrote: >>> On 14.08.2020 04:48, Chris Packham wrote: Hi, I'm seeing a problem with accessing spi-nor after upgrading a T2081 based s

Re: [PATCH 3/3] powerpc/smp: Move ppc_md.cpu_die() to smp_ops.cpu_offline_self()

2020-08-18 Thread Christophe Leroy
Le 19/08/2020 à 03:56, Michael Ellerman a écrit : We have smp_ops->cpu_die() and ppc_md.cpu_die(). One of them offlines the current CPU and one offlines another CPU, can you guess which is which? Also one is in smp_ops and one is in ppc_md? So rename ppc_md.cpu_die(), to cpu_offline_self(), b

Re: [PATCH v3] soc: fsl: enable acpi support

2020-08-18 Thread Christophe Leroy
Le 19/08/2020 à 06:00, Ran Wang a écrit : From: Peng Ma This patch enables ACPI support in RCPM driver. Can you change the subject to "soc: fsl: enable acpi support in RCPM driver" ? Signed-off-by: Peng Ma Signed-off-by: Ran Wang --- Change in v3: - Add #ifdef CONFIG_ACPI for acpi

RE: [PATCH v3] soc: fsl: enable acpi support

2020-08-18 Thread Ran Wang
Hi Christophe On Wednesday, August 19, 2020 2:48 PM, Christophe Leroy wrote: > > > > Le 19/08/2020 à 06:00, Ran Wang a écrit : > > From: Peng Ma > > > > This patch enables ACPI support in RCPM driver. > > Can you change the subject to "soc: fsl: enable acpi support in RCPM driver" ? Sure. >

[powerpc:next-test] BUILD SUCCESS dc76919c80d7128cd46cfa0f1f356e4c12e50229

2020-08-18 Thread kernel test robot
i386 randconfig-a005-20200818 i386 randconfig-a002-20200818 i386 randconfig-a001-20200818 i386 randconfig-a006-20200818 i386 randconfig-a003-20200818 i386 randconfig-a004-20200818 x86_64

[powerpc:merge] BUILD SUCCESS d4ecce4dcc8f8820286cf4e0859850c555e89854

2020-08-18 Thread kernel test robot
allmodconfig powerpc allnoconfig i386 randconfig-a005-20200818 i386 randconfig-a002-20200818 i386 randconfig-a001-20200818 i386 randconfig-a006-20200818 i386 randconfig-a003-20200818 i386

<    1   2