Re: [PATCH 0/2] powerpc: Remove support for ppc405/440 Xilinx platforms

2020-03-31 Thread Michal Simek
On 31. 03. 20 8:56, Christophe Leroy wrote: > > > Le 31/03/2020 à 07:30, Michael Ellerman a écrit : >> Christophe Leroy writes: >>> Le 27/03/2020 à 15:14, Andy Shevchenko a écrit : On Fri, Mar 27, 2020 at 02:22:55PM +0100, Arnd Bergmann wrote: > On Fri, Mar 27, 2020 at 2:15 PM Andy Shev

Re: [PATCH 0/2] powerpc: Remove support for ppc405/440 Xilinx platforms

2020-03-31 Thread Christophe Leroy
Le 31/03/2020 à 08:59, Michal Simek a écrit : On 31. 03. 20 8:56, Christophe Leroy wrote: Le 31/03/2020 à 07:30, Michael Ellerman a écrit : Christophe Leroy writes: Le 27/03/2020 à 15:14, Andy Shevchenko a écrit : On Fri, Mar 27, 2020 at 02:22:55PM +0100, Arnd Bergmann wrote: On Fri, M

[PATCH v2 01/11] powerpc: Mark 4xx as Orphan in MAINTAINERS

2020-03-31 Thread Christophe Leroy
From: Michael Ellerman The 4xx platforms are no longer maintained. Cc: Alistair Popple Cc: Matt Porter Signed-off-by: Michael Ellerman Acked-by: Alistair Popple Signed-off-by: Christophe Leroy --- MAINTAINERS | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/MAINTAINE

[PATCH v2 03/11] powerpc/40x: Remove 40x platforms.

2020-03-31 Thread Christophe Leroy
40x platforms have been orphaned for many years. Remove them. Signed-off-by: Christophe Leroy --- MAINTAINERS | 1 - arch/powerpc/configs/40x/acadia_defconfig | 62 -- arch/powerpc/configs/40x/ep405_defconfig| 62 -- arch/powerpc/configs

[PATCH v2 02/11] powerpc: Remove Xilinx PPC405/PPC440 support

2020-03-31 Thread Christophe Leroy
From: Michal Simek The latest Xilinx design tools called ISE and EDK has been released in October 2013. New tool doesn't support any PPC405/PPC440 new designs. These platforms are no longer supported and tested. PowerPC 405/440 port is orphan from 2013 by commit cdeb89943bfc ("MAINTAINERS: Fix i

[PATCH v2 04/11] powerpc/boot: Remove all 40x platforms

2020-03-31 Thread Christophe Leroy
Remove 40x platforms from the boot directory. Signed-off-by: Christophe Leroy --- arch/powerpc/boot/4xx.c | 266 - arch/powerpc/boot/4xx.h | 4 - arch/powerpc/boot/Makefile | 14 - arch/powerpc/boot/cuboot-acadia.c | 171 --- arch/pow

[PATCH v2 06/11] powerpc: Remove IBM405 Erratum #77

2020-03-31 Thread Christophe Leroy
This erratum is dedicated to IBM405 which was part of 40x platforms. Now that 40x platforms are gone, this erratum can be removed. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/asm-405.h | 19 --- arch/powerpc/include/asm/atomic.h| 11 ---

[PATCH v2 05/11] powerpc: Remove support for 40x

2020-03-31 Thread Christophe Leroy
Now that 40x platforms have gone, remove support for 40x in the core of powerpc arch. Signed-off-by: Christophe Leroy --- arch/powerpc/Kconfig | 8 +- arch/powerpc/Kconfig.debug | 13 - arch/powerpc/Makefile| 1 - arch/powerp

[PATCH v2 08/11] powerpc/4xx: Remove CONFIG_4xx

2020-03-31 Thread Christophe Leroy
CONFIG_4xx was corresponding to CONFIG_40x | CONFIG_44x. As CONFIG_40x is gone, CONFIG_4xx and CONFIG_44x are now equivalent. And CONFIG_BOOKE is also set when CONFIG_44x is set. Replace (CONFIG_4xx | CONFIG_BOOKE) by CONFIG_BOOKE Replace other CONFIG_4xx by CONFIG_44x Remove CONFIG_4xx. Signed-

[PATCH v2 07/11] powerpc/xmon: Remove PPC403 and PPC405

2020-03-31 Thread Christophe Leroy
xmon has special support for PPC403 and PPC405 which were part of 40x platforms. 40x platforms are gone, remove support of PPC403 and PPC405 in xmon. Signed-off-by: Christophe Leroy --- arch/powerpc/xmon/ppc-opc.c | 277 +++- arch/powerpc/xmon/ppc.h | 6 -

[PATCH v2 09/11] powerpc/platforms: Move files from 4xx to 44x

2020-03-31 Thread Christophe Leroy
Only 44x uses 4xx now, so only keep one directory. Signed-off-by: Christophe Leroy --- arch/powerpc/platforms/44x/Makefile | 9 +++- arch/powerpc/platforms/{4xx => 44x}/cpm.c | 0 arch/powerpc/platforms/{4xx => 44x}/gpio.c| 0 .../powerpc/platforms/{4xx => 44x}/hsta_msi.

[PATCH v2 10/11] powerpc/pgtable: Drop PTE_ATOMIC_UPDATES

2020-03-31 Thread Christophe Leroy
40x was the last user of PTE_ATOMIC_UPDATES. Drop everything related to PTE_ATOMIC_UPDATES. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/nohash/32/pgtable.h | 30 arch/powerpc/include/asm/nohash/64/pgtable.h | 27 -- 2 files changed, 57 delet

[PATCH v2 11/11] powerpc/32: Replace RFI by rfi

2020-03-31 Thread Christophe Leroy
RFI was a macro waving the rfi instruction for the 40x. Now that 40x is gone, rfi can be used directly. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/entry_32.S | 18 +- arch/powerpc/kernel/head_32.S | 18 +- 2 files changed, 18 insertions(+), 18 delet

Re: [PATCH v3 0/5] mm: Enable CONFIG_NODES_SPAN_OTHER_NODES by default for NUMA

2020-03-31 Thread Mike Rapoport
On Mon, Mar 30, 2020 at 08:23:01PM +0200, Michal Hocko wrote: > On Mon 30-03-20 20:51:00, Mike Rapoport wrote: > > On Mon, Mar 30, 2020 at 09:42:46AM +0200, Michal Hocko wrote: > > > On Sat 28-03-20 11:31:17, Hoan Tran wrote: > > > > In NUMA layout which nodes have memory ranges that span across ot

Re: [PATCH v3 0/5] mm: Enable CONFIG_NODES_SPAN_OTHER_NODES by default for NUMA

2020-03-31 Thread Michal Hocko
On Tue 31-03-20 11:14:23, Mike Rapoport wrote: > On Mon, Mar 30, 2020 at 08:23:01PM +0200, Michal Hocko wrote: > > On Mon 30-03-20 20:51:00, Mike Rapoport wrote: > > > On Mon, Mar 30, 2020 at 09:42:46AM +0200, Michal Hocko wrote: > > > > On Sat 28-03-20 11:31:17, Hoan Tran wrote: > > > > > In NUMA

[PATCH v4 19/25] nvdimm/ocxl: Forward events to userspace

2020-03-31 Thread Alastair D'Silva
Some of the interrupts that the card generates are better handled by the userspace daemon, in particular: Controller Hardware/Firmware Fatal Controller Dump Available Error Log available This patch allows a userspace application to register an eventfd with the driver via SCM_IOCTL_EVENTFD to recei

[PATCH v4 23/25] nvdimm/ocxl: Expose SMART data via ndctl

2020-03-31 Thread Alastair D'Silva
This patch retrieves proprietary formatted SMART data and makes it available via ndctl. A later contribution will be made to ndctl to parse this data. Signed-off-by: Alastair D'Silva --- drivers/nvdimm/ocxl/main.c | 113 + drivers/nvdimm/ocxl/ocxlpmem.h | 18

[PATCH v4 18/25] nvdimm/ocxl: Add an IOCTL to report controller statistics

2020-03-31 Thread Alastair D'Silva
The controller can report a number of statistics that are useful in evaluating the performance and reliability of the card. This patch exposes this information via an IOCTL. Signed-off-by: Alastair D'Silva --- drivers/nvdimm/ocxl/main.c | 220 + include/uapi/

[PATCH v4 16/25] nvdimm/ocxl: Implement the Read Error Log command

2020-03-31 Thread Alastair D'Silva
The read error log command extracts information from the controller's internal error log. This patch exposes this information in 2 ways: - During probe, if an error occurs & a log is available, print it to the console - After probe, make the error log available to userspace via an IOCTL. Users

[PATCH v4 17/25] nvdimm/ocxl: Add controller dump IOCTLs

2020-03-31 Thread Alastair D'Silva
This patch adds IOCTLs to allow userspace to request & fetch dumps of the internal controller state. This is useful during debugging or when a fatal error on the controller has occurred. The expected flow of operations are: 1. IOCTL_OCXL_PMEM_CONTROLLER_DUMP to request the controller to take a

[PATCH v4 22/25] nvdimm/ocxl: Add debug IOCTLs

2020-03-31 Thread Alastair D'Silva
These IOCTLs provide low level access to the card to aid in debugging controller/FPGA firmware. Signed-off-by: Alastair D'Silva --- drivers/nvdimm/ocxl/Kconfig| 6 + drivers/nvdimm/ocxl/main.c | 198 + drivers/nvdimm/ocxl/ocxlpmem.h | 2 +- include/uap

[PATCH] powerpc: Add new HWCAP bits

2020-03-31 Thread Alistair Popple
Two new future architectural features requiring HWCAP bits are being developed. Once allocated in the kernel firmware can enable these via device tree cpu features. Signed-off-by: Alistair Popple --- arch/powerpc/include/uapi/asm/cputable.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/a

Re: [PATCH 0/2] powerpc: Remove support for ppc405/440 Xilinx platforms

2020-03-31 Thread Christophe Leroy
Le 31/03/2020 à 09:19, Christophe Leroy a écrit : Le 31/03/2020 à 08:59, Michal Simek a écrit : On 31. 03. 20 8:56, Christophe Leroy wrote: Le 31/03/2020 à 07:30, Michael Ellerman a écrit : Christophe Leroy writes: Le 27/03/2020 à 15:14, Andy Shevchenko a écrit : On Fri, Mar 27, 2020

Re: [PATCH v5 1/7] ASoC: dt-bindings: fsl_asrc: Add new property fsl,asrc-format

2020-03-31 Thread Nicolin Chen
On Tue, Mar 31, 2020 at 10:28:25AM +0800, Shengjiu Wang wrote: > Hi > > On Tue, Mar 24, 2020 at 5:22 AM Nicolin Chen wrote: > > > > On Fri, Mar 20, 2020 at 11:32:13AM -0600, Rob Herring wrote: > > > On Mon, Mar 09, 2020 at 02:19:44PM -0700, Nicolin Chen wrote: > > > > On Mon, Mar 09, 2020 at 11:5

Emulate ppc64le builds on x86/x64 machine

2020-03-31 Thread shivakanth k
Hi , Could you please help me to set up ppc64le 0n liunux machine

Re: [PATCH v7 7/7] powerpc/32: use set_memory_attr()

2020-03-31 Thread Christophe Leroy
Le 31/03/2020 à 06:48, Russell Currey a écrit : From: Christophe Leroy Use set_memory_attr() instead of the PPC32 specific change_page_attr() change_page_attr() was checking that the address was not mapped by blocks and was handling highmem, but that's unneeded because the affected pages ca

[PATCH v19 00/24] selftests, powerpc, x86: Memory Protection Keys

2020-03-31 Thread Sandipan Das
Memory protection keys enables an application to protect its address space from inadvertent access by its own code. This feature is now enabled on powerpc and has been available since 4.16-rc1. The patches move the selftests to arch neutral directory and enhance their test coverage. Tested on pow

[PATCH v19 02/24] selftests/vm/pkeys: Rename all references to pkru to a generic name

2020-03-31 Thread Sandipan Das
From: Ram Pai This renames PKRU references to "pkey_reg" or "pkey" based on the usage. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: Thiago Jung Bauermann Reviewed-by: Dave Hansen Signed-off-by: Sandipan Das --- tools/testing/selftests/vm/pkey-helpers.h| 85

[PATCH v19 01/24] selftests/x86/pkeys: Move selftests to arch-neutral directory

2020-03-31 Thread Sandipan Das
From: Ram Pai cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: Thiago Jung Bauermann Acked-by: Ingo Molnar Acked-by: Dave Hansen Signed-off-by: Sandipan Das --- tools/testing/selftests/vm/.gitignore | 1 + tools/testing/selftests/vm/Makefile

[PATCH v19 04/24] selftests/vm/pkeys: Move some definitions to arch-specific header

2020-03-31 Thread Sandipan Das
From: Thiago Jung Bauermann In preparation for multi-arch support, move definitions which have arch-specific values to x86-specific header. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: Thiago Jung Bauermann Acked-by: Dave Hansen Signed-off-by: Sandipan Das ---

[PATCH v19 03/24] selftests/vm/pkeys: Move generic definitions to header file

2020-03-31 Thread Sandipan Das
From: Ram Pai Moved all the generic definition and helper functions to the header file. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: Thiago Jung Bauermann Acked-by: Dave Hansen Signed-off-by: Sandipan Das --- tools/testing/selftests/vm/pkey-helpers.h| 35 ++

[PATCH v19 05/24] selftests/vm/pkeys: Make gcc check arguments of sigsafe_printf()

2020-03-31 Thread Sandipan Das
From: Thiago Jung Bauermann This will help us ensure we print pkey_reg_t values correctly in different architectures. Signed-off-by: Thiago Jung Bauermann Signed-off-by: Sandipan Das Acked-by: Dave Hansen --- tools/testing/selftests/vm/pkey-helpers.h | 4 1 file changed, 4 insertions(+)

[PATCH v19 06/24] selftests: vm: pkeys: Use sane types for pkey register

2020-03-31 Thread Sandipan Das
The size of the pkey register can vary across architectures. This converts the data type of all its references to u64 in preparation for multi-arch support. To keep the definition of the u64 type consistent and remove format specifier related warnings, __SANE_USERSPACE_TYPES__ is defined as sugges

[PATCH v19 07/24] selftests: vm: pkeys: Add helpers for pkey bits

2020-03-31 Thread Sandipan Das
This introduces some functions that help with setting or clearing bits of a particular pkey. This also adds an abstraction for getting a pkey's bit position in the pkey register as this may vary across architectures. Signed-off-by: Sandipan Das Acked-by: Dave Hansen --- tools/testing/selftests/

[PATCH v19 08/24] selftests/vm/pkeys: Fix pkey_disable_clear()

2020-03-31 Thread Sandipan Das
From: Ram Pai Currently, pkey_disable_clear() sets the specified bits instead clearing them. This has been dead code up to now because its only callers i.e. pkey_access/write_allow() are also unused. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Acked-by: Dave Hansen Signed-off-b

[PATCH v19 09/24] selftests/vm/pkeys: Fix assertion in pkey_disable_set/clear()

2020-03-31 Thread Sandipan Das
From: Ram Pai In some cases, a pkey's bits need not necessarily change in a way that the value of the pkey register increases when performing a pkey_disable_set() or decreases when performing a pkey_disable_clear(). For example, on powerpc, if a pkey's current state is PKEY_DISABLE_ACCESS and we

[PATCH v19 11/24] selftests: vm: pkeys: Use the correct huge page size

2020-03-31 Thread Sandipan Das
The huge page size can vary across architectures. This will ensure that the correct huge page size is used when accessing the hugetlb controls under sysfs. Instead of using a hardcoded page size (i.e. 2MB), this now uses the HPAGE_SIZE macro which is arch-specific. Signed-off-by: Sandipan Das Ack

[PATCH v19 10/24] selftests/vm/pkeys: Fix alloc_random_pkey() to make it really random

2020-03-31 Thread Sandipan Das
From: Ram Pai alloc_random_pkey() was allocating the same pkey every time. Not all pkeys were geting tested. This fixes it. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Acked-by: Dave Hansen Signed-off-by: Sandipan Das --- tools/testing/selftests/vm/protection_keys.c | 3 ++-

[PATCH v19 12/24] selftests/vm/pkeys: Introduce generic pkey abstractions

2020-03-31 Thread Sandipan Das
From: Ram Pai This introduces some generic abstractions and provides the corresponding architecture-specfic implementations for these abstractions. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: Thiago Jung Bauermann Signed-off-by: Sandipan Das Acked-by: Dave Hanse

[PATCH v19 13/24] selftests/vm/pkeys: Introduce powerpc support

2020-03-31 Thread Sandipan Das
From: Ram Pai This makes use of the abstractions added earlier and introduces support for powerpc. For powerpc, after receiving the SIGSEGV, the signal handler must explicitly restore access permissions for the faulting pkey to allow the test to continue. As this makes use of pkey_access_allow()

[PATCH v19 14/24] selftests/vm/pkeys: Fix number of reserved powerpc pkeys

2020-03-31 Thread Sandipan Das
From: "Desnes A. Nunes do Rosario" The number of reserved pkeys in a PowerNV environment is different from that on PowerVM or KVM. Tested on PowerVM and PowerNV environments. Signed-off-by: "Desnes A. Nunes do Rosario" Signed-off-by: Ram Pai Signed-off-by: Sandipan Das Acked-by: Dave Hansen

[PATCH v19 15/24] selftests/vm/pkeys: Fix assertion in test_pkey_alloc_exhaust()

2020-03-31 Thread Sandipan Das
From: Ram Pai Some pkeys which are valid on the hardware are reserved and not available for application use. These keys cannot be allocated. test_pkey_alloc_exhaust() tries to account for these and has an assertion which validates if all available pkeys have been exahaustively allocated. However

[PATCH v19 16/24] selftests/vm/pkeys: Improve checks to determine pkey support

2020-03-31 Thread Sandipan Das
From: Ram Pai For the pkeys subsystem to work, both the CPU and the kernel need to have support. So, additionally check if the kernel supports pkeys apart from the CPU feature checks. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: Sandipan Das Acked-by: Dave Hansen

[PATCH v19 17/24] selftests/vm/pkeys: Associate key on a mapped page and detect access violation

2020-03-31 Thread Sandipan Das
From: Ram Pai Detect access-violation on a page to which access-disabled key is associated much after the page is mapped. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Acked-by: Dave Hansen Signed-off: Sandipan Das --- tools/testing/selftests/vm/protection_keys.c | 19 +

[PATCH v19 18/24] selftests/vm/pkeys: Associate key on a mapped page and detect write violation

2020-03-31 Thread Sandipan Das
From: Ram Pai Detect write-violation on a page to which write-disabled key is associated much after the page is mapped. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Acked-by: Dave Hansen Signed-off-by: Sandipan Das --- tools/testing/selftests/vm/protection_keys.c | 12

[PATCH v19 19/24] selftests/vm/pkeys: Detect write violation on a mapped access-denied-key page

2020-03-31 Thread Sandipan Das
From: Ram Pai Detect write-violation on a page to which access-disabled key is associated much after the page is mapped. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Acked-by: Dave Hansen Signed-off-by: Sandipan Das --- tools/testing/selftests/vm/protection_keys.c | 13 +++

[PATCH v19 20/24] selftests/vm/pkeys: Introduce a sub-page allocator

2020-03-31 Thread Sandipan Das
From: Ram Pai This introduces a new allocator that allocates 4K hardware pages to back 64K linux pages. This allocator is available only on powerpc. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: Thiago Jung Bauermann Signed-off-by: Sandipan Das Acked-by: Dave Hans

[PATCH v19 21/24] selftests/vm/pkeys: Test correct behaviour of pkey-0

2020-03-31 Thread Sandipan Das
From: Ram Pai Ensure that pkey-0 is allocated on start and that it can be attached dynamically in various modes, without failures. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: Sandipan Das Acked-by: Dave Hansen --- tools/testing/selftests/vm/protection_keys.c |

[PATCH v19 22/24] selftests/vm/pkeys: Override access right definitions on powerpc

2020-03-31 Thread Sandipan Das
From: Ram Pai Some platforms hardcode the x86 values for PKEY_DISABLE_ACCESS and PKEY_DISABLE_WRITE such as those in: /usr/include/bits/mman-shared.h. This overrides the definitions with correct values for powerpc. cc: Dave Hansen cc: Florian Weimer Signed-off-by: Ram Pai Signed-off-by: San

[PATCH v19 23/24] selftests: vm: pkeys: Use the correct page size on powerpc

2020-03-31 Thread Sandipan Das
Both 4K and 64K pages are supported on powerpc. Parts of the selftest code perform alignment computations based on the PAGE_SIZE macro which is currently hardcoded to 64K for powerpc. This causes some test failures on kernels configured with 4K page size. In some cases, we need to enforce function

[PATCH v19 24/24] selftests: vm: pkeys: Fix multilib builds for x86

2020-03-31 Thread Sandipan Das
This ensures that both 32-bit and 64-bit binaries are generated when this is built on a x86_64 system. Most of the changes have been borrowed from tools/testing/selftests/x86/Makefile. Signed-off-by: Sandipan Das Acked-by: Dave Hansen Tested-by: Dave Hansen --- tools/testing/selftests/vm/Makef

Re: [PATCH 0/2] powerpc: Remove support for ppc405/440 Xilinx platforms

2020-03-31 Thread Michal Simek
On 31. 03. 20 11:49, Christophe Leroy wrote: > > > Le 31/03/2020 à 09:19, Christophe Leroy a écrit : >> >> >> Le 31/03/2020 à 08:59, Michal Simek a écrit : >>> On 31. 03. 20 8:56, Christophe Leroy wrote: Le 31/03/2020 à 07:30, Michael Ellerman a écrit : > Christophe Leroy writ

Re: [PATCH 0/2] powerpc: Remove support for ppc405/440 Xilinx platforms

2020-03-31 Thread Christophe Leroy
Le 31/03/2020 à 12:04, Michal Simek a écrit : On 31. 03. 20 11:49, Christophe Leroy wrote: Le 31/03/2020 à 09:19, Christophe Leroy a écrit : Le 31/03/2020 à 08:59, Michal Simek a écrit : On 31. 03. 20 8:56, Christophe Leroy wrote: Le 31/03/2020 à 07:30, Michael Ellerman a écrit : Ch

[PATCH v4 0/4] powerpc/papr_scm: Add support for reporting nvdimm health

2020-03-31 Thread Vaibhav Jain
The PAPR standard[1][3] provides mechanisms to query the health and performance stats of an NVDIMM via various hcalls as described in Ref[2]. Until now these stats were never available nor exposed to the user-space tools like 'ndctl'. This is partly due to PAPR platform not having support for ACPI

[PATCH v4 1/4] powerpc/papr_scm: Fetch nvdimm health information from PHYP

2020-03-31 Thread Vaibhav Jain
Implement support for fetching nvdimm health information via H_SCM_HEALTH hcall as documented in Ref[1]. The hcall returns a pair of 64-bit big-endian integers which are then stored in 'struct papr_scm_priv' and subsequently partially exposed to user-space via newly introduced dimm specific attribu

[PATCH v4 2/4] ndctl/uapi: Introduce NVDIMM_FAMILY_PAPR_SCM as a new NVDIMM DSM family

2020-03-31 Thread Vaibhav Jain
Add PAPR-scm family of DSM command-set to the white list of NVDIMM command sets. Signed-off-by: Vaibhav Jain --- Changelog: v3..v4 : None v2..v3 : Updated the patch prefix to 'ndctl/uapi' [Aneesh] v1..v2 : None --- include/uapi/linux/ndctl.h | 1 + 1 file changed, 1 insertion(+) diff --git a

[PATCH v4 3/4] powerpc/papr_scm, uapi: Add support for handling PAPR DSM commands

2020-03-31 Thread Vaibhav Jain
Implement support for handling PAPR DSM commands in papr_scm module. We advertise support for ND_CMD_CALL for the dimm command mask and implement necessary scaffolding in the module to handle ND_CMD_CALL ioctl and DSM commands that we receive. The layout of the DSM commands as we expect from libnv

[PATCH v4 4/4] powerpc/papr_scm: Implement support for DSM_PAPR_SCM_HEALTH

2020-03-31 Thread Vaibhav Jain
This patch implements support for papr_scm command 'DSM_PAPR_SCM_HEALTH' that returns a newly introduced 'struct nd_papr_scm_dimm_health_stat' instance containing dimm health information back to user space in response to ND_CMD_CALL. This functionality is implemented in newly introduced papr_scm_ge

Re: [PATCH v2 2/2] powerpc: Remove Xilinx PPC405/PPC440 support

2020-03-31 Thread Bartlomiej Zolnierkiewicz
On 3/30/20 3:32 PM, Michal Simek wrote: > The latest Xilinx design tools called ISE and EDK has been released in > October 2013. New tool doesn't support any PPC405/PPC440 new designs. > These platforms are no longer supported and tested. > > PowerPC 405/440 port is orphan from 2013 by > commit

[RFC/PATCH 1/3] powerpc/kvm: Handle H_FAC_UNAVAIL when guest executes stop.

2020-03-31 Thread Gautham R. Shenoy
From: "Gautham R. Shenoy" If a guest executes a stop instruction when the hypervisor has set the PSSCR[ESL|EC] bits, the processor will throw an Hypervisor Facility Unavailable exception. Currently when we receive this exception, we only check if the exeception is generated due to a doorbell inst

[RFC/PATCH 2/3] pseries/kvm: Clear PSSCR[ESL|EC] bits before guest entry

2020-03-31 Thread Gautham R. Shenoy
From: "Gautham R. Shenoy" ISA v3.0 allows the guest to execute a stop instruction. For this, the PSSCR[ESL|EC] bits need to be cleared by the hypervisor before scheduling in the guest vCPU. Currently we always schedule in a vCPU with PSSCR[ESL|EC] bits set. This patch changes the behaviour to en

[RFC/PATCH 0/3] Add support for stop instruction inside KVM guest

2020-03-31 Thread Gautham R. Shenoy
From: "Gautham R. Shenoy" *** RFC Only. Not intended for inclusion Motivation ~~~ The POWER ISA v3.0 allows stop instruction to be executed from a Guest Kernel (HV=0,PR=0) context. If the hypervisor has cleared PSSCR[ESL|EC] bits, then the stop instruction thus execu

[RFC/PATCH 3/3] cpuidle/pseries: Add stop0lite state

2020-03-31 Thread Gautham R. Shenoy
From: "Gautham R. Shenoy" The POWER ISA v3.0 allows stop instruction to be executed from a HV=0,PR=0 context. If the PSSCR[ESL|EC] bits are cleared, then the stop instruction thus executed will cause the thread to pause, thereby donating its cycles to the other threads in the core until the pause

Re: [RFC/PATCH 0/3] Add support for stop instruction inside KVM guest

2020-03-31 Thread Gautham R Shenoy
On Tue, Mar 31, 2020 at 05:40:55PM +0530, Gautham R. Shenoy wrote: > From: "Gautham R. Shenoy" > > > *** RFC Only. Not intended for inclusion > > Motivation > ~~~ > > The POWER ISA v3.0 allows stop instruction to be executed from a Guest > Kernel (HV=0,PR=0) context.

Re: [PATCH V2 0/3] mm/debug: Add more arch page table helper tests

2020-03-31 Thread Gerald Schaefer
On Tue, 24 Mar 2020 10:52:52 +0530 Anshuman Khandual wrote: > This series adds more arch page table helper tests. The new tests here are > either related to core memory functions and advanced arch pgtable helpers. > This also creates a documentation file enlisting all expected semantics as > sugg

Re: [PATCH] powerpc/perf: Add documentation around use of "ppc_set_pmu_inuse" in PMU core-book3s

2020-03-31 Thread Athira Rajeev
Hi, Please ignore this version as I messed up with the author information. I am sending a V2 with the proper author name. Thanks Athira > On 30-Mar-2020, at 5:08 PM, Athira Rajeev wrote: > > "pmcregs_in_use" flag is part of lppaca (Virtual Process Area), > which is used to indicate whether P

[PATCH v2] powerpc/perf: Add documentation around use of "ppc_set_pmu_inuse" in PMU core-book3s

2020-03-31 Thread Athira Rajeev
From: Madhavan Srinivasan "pmcregs_in_use" flag is part of lppaca (Virtual Process Area), which is used to indicate whether Performance Monitoring Unit (PMU) and PMU sprs are in-use and whether should it be saved/restored by hypervisor. ppc_set_pmu_inuse() is used to set/unset the VPA flag "pmcre

Re: [PATCH v3 0/5] mm: Enable CONFIG_NODES_SPAN_OTHER_NODES by default for NUMA

2020-03-31 Thread Baoquan He
Hi Michal, On 03/31/20 at 10:55am, Michal Hocko wrote: > On Tue 31-03-20 11:14:23, Mike Rapoport wrote: > > Maybe I mis-read the code, but I don't see how this could happen. In the > > HAVE_MEMBLOCK_NODE_MAP=y case, free_area_init_node() calls > > calculate_node_totalpages() that ensures that node

Re: [PATCH v3 0/5] mm: Enable CONFIG_NODES_SPAN_OTHER_NODES by default for NUMA

2020-03-31 Thread Michal Hocko
On Tue 31-03-20 22:03:32, Baoquan He wrote: > Hi Michal, > > On 03/31/20 at 10:55am, Michal Hocko wrote: > > On Tue 31-03-20 11:14:23, Mike Rapoport wrote: > > > Maybe I mis-read the code, but I don't see how this could happen. In the > > > HAVE_MEMBLOCK_NODE_MAP=y case, free_area_init_node() call

Re: [PATCH v3 0/5] mm: Enable CONFIG_NODES_SPAN_OTHER_NODES by default for NUMA

2020-03-31 Thread Baoquan He
On 03/31/20 at 04:21pm, Michal Hocko wrote: > On Tue 31-03-20 22:03:32, Baoquan He wrote: > > Hi Michal, > > > > On 03/31/20 at 10:55am, Michal Hocko wrote: > > > On Tue 31-03-20 11:14:23, Mike Rapoport wrote: > > > > Maybe I mis-read the code, but I don't see how this could happen. In the > > > >

[PATCH v5 1/4] powerpc/papr_scm: Fetch nvdimm health information from PHYP

2020-03-31 Thread Vaibhav Jain
Implement support for fetching nvdimm health information via H_SCM_HEALTH hcall as documented in Ref[1]. The hcall returns a pair of 64-bit big-endian integers which are then stored in 'struct papr_scm_priv' and subsequently partially exposed to user-space via newly introduced dimm specific attribu

[PATCH v5 0/4] powerpc/papr_scm: Add support for reporting nvdimm health

2020-03-31 Thread Vaibhav Jain
The PAPR standard[1][3] provides mechanisms to query the health and performance stats of an NVDIMM via various hcalls as described in Ref[2]. Until now these stats were never available nor exposed to the user-space tools like 'ndctl'. This is partly due to PAPR platform not having support for ACPI

[PATCH v5 2/4] ndctl/uapi: Introduce NVDIMM_FAMILY_PAPR_SCM as a new NVDIMM DSM family

2020-03-31 Thread Vaibhav Jain
Add PAPR-scm family of DSM command-set to the white list of NVDIMM command sets. Signed-off-by: Vaibhav Jain --- Changelog: v4..v5 : None v3..v4 : None v2..v3 : Updated the patch prefix to 'ndctl/uapi' [Aneesh] v1..v2 : None --- include/uapi/linux/ndctl.h | 1 + 1 file changed, 1 insertion(+

[PATCH v5 4/4] powerpc/papr_scm: Implement support for DSM_PAPR_SCM_HEALTH

2020-03-31 Thread Vaibhav Jain
This patch implements support for papr_scm command 'DSM_PAPR_SCM_HEALTH' that returns a newly introduced 'struct nd_papr_scm_dimm_health_stat' instance containing dimm health information back to user space in response to ND_CMD_CALL. This functionality is implemented in newly introduced papr_scm_ge

[PATCH v5 3/4] powerpc/papr_scm, uapi: Add support for handling PAPR DSM commands

2020-03-31 Thread Vaibhav Jain
Implement support for handling PAPR DSM commands in papr_scm module. We advertise support for ND_CMD_CALL for the dimm command mask and implement necessary scaffolding in the module to handle ND_CMD_CALL ioctl and DSM commands that we receive. The layout of the DSM commands as we expect from libnv

Re: [PATCH 0/2] selftests: vm: Build fixes for powerpc64

2020-03-31 Thread Shuah Khan
On 1/30/20 12:01 AM, Sandipan Das wrote: The second patch was already posted independently but because of the changes in the first patch, the second one now depends on it. Hence posting it now as a part of this series. The last version (v2) of the second patch can be found at: https://patchwork.

Re: [PATCH v2 07/11] powerpc/xmon: Remove PPC403 and PPC405

2020-03-31 Thread Arnd Bergmann
On Tue, Mar 31, 2020 at 9:49 AM Christophe Leroy wrote: > > xmon has special support for PPC403 and PPC405 which were part > of 40x platforms. > > 40x platforms are gone, remove support of PPC403 and PPC405 in xmon. > > Signed-off-by: Christophe Leroy > --- > arch/powerpc/xmon/ppc-opc.c | 277 ++

Re: [PATCH v2 09/11] powerpc/platforms: Move files from 4xx to 44x

2020-03-31 Thread Arnd Bergmann
On Tue, Mar 31, 2020 at 9:49 AM Christophe Leroy wrote: > > Only 44x uses 4xx now, so only keep one directory. > > Signed-off-by: Christophe Leroy > --- > arch/powerpc/platforms/44x/Makefile | 9 +++- > arch/powerpc/platforms/{4xx => 44x}/cpm.c | 0 No objections to moving ev

Re: [PATCH] powerpc: Add new HWCAP bits

2020-03-31 Thread Tulio Magno Quites Machado Filho
Alistair Popple writes: > diff --git a/arch/powerpc/include/uapi/asm/cputable.h > b/arch/powerpc/include/uapi/asm/cputable.h > index 540592034740..c6fe10b2 100644 > --- a/arch/powerpc/include/uapi/asm/cputable.h > +++ b/arch/powerpc/include/uapi/asm/cputable.h > @@ -50,6 +50,8 @@ > #define

[RFC WIP PATCH] powerpc/32: system call implement entry/exit logic in C

2020-03-31 Thread Christophe Leroy
That's first try to port PPC64 syscall entry/exit logic in C to PPC32. I've do the minimum to get it work. I have not reworked calls to sys_fork() and friends for instance. For the time being, it seems to work more or less but: - ping reports EINVAL on recvfrom - strace shows NULL instead of strin

Re: [PATCH v2 09/11] powerpc/platforms: Move files from 4xx to 44x

2020-03-31 Thread Christophe Leroy
Le 31/03/2020 à 17:14, Arnd Bergmann a écrit : On Tue, Mar 31, 2020 at 9:49 AM Christophe Leroy wrote: Only 44x uses 4xx now, so only keep one directory. Signed-off-by: Christophe Leroy --- arch/powerpc/platforms/44x/Makefile | 9 +++- arch/powerpc/platforms/{4xx => 44x}

Re: [PATCH v2] macintosh: convert to i2c_new_scanned_device

2020-03-31 Thread Wolfram Sang
On Thu, Mar 26, 2020 at 12:38:19PM +0100, Wolfram Sang wrote: > Move from the deprecated i2c_new_probed_device() to the new > i2c_new_scanned_device(). No functional change for this driver because > it doesn't check the return code anyhow. > > Signed-off-by: Wolfram Sang > Acked-by: Michael Eller

[PATCH v2 01/12] powerpc/52xx: Blacklist functions running with MMU disabled for kprobe

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode, all functions running with MMU disabled have to be blacklisted. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/platforms/52xx/lite5200_sleep.S | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/powerpc/platf

[PATCH v2 02/12] powerpc/82xx: Blacklist pq2_restart() for kprobe

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode, all functions running with MMU disabled have to be blacklisted. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/platforms/82xx/pq2.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/powerpc/platforms/82xx/

[PATCH v2 03/12] powerpc/83xx: Blacklist mpc83xx_deep_resume() for kprobe

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode, all functions running with MMU disabled have to be blacklisted. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/platforms/83xx/suspend-asm.S | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/powerpc/platforms/

[PATCH v2 04/12] powerpc/powermac: Blacklist functions running with MMU disabled for kprobe

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode, all functions running with MMU disabled have to be blacklisted. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/platforms/powermac/cache.S | 2 ++ arch/powerpc/platforms/powermac/sleep.S | 5 - 2 files changed, 6

[PATCH v2 05/12] powerpc/mem: Blacklist flush_dcache_icache_phys() for kprobe

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode, all functions running with MMU disabled have to be blacklisted. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/mm/mem.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/m

[PATCH v2 06/12] powerpc/32s: Make local symbols non visible in hash_low.

2020-03-31 Thread Christophe Leroy
In hash_low.S, a lot of named local symbols are used instead of numbers to ease code readability. However, they don't need to be visible. In order to ease blacklisting of functions running with MMU disabled for kprobe, rename the symbols to .Lsymbols in order to hide them as if they were numbered

[PATCH v2 07/12] powerpc/32s: Blacklist functions running with MMU disabled for kprobe

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode, all functions running with MMU disabled have to be blacklisted. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/mm/book3s32/hash_low.S | 6 ++ 1 file changed, 6 insertions(+) diff --git a/arch/powerpc/mm/book3s3

[PATCH v2 08/12] powerpc/rtas: Remove machine_check_in_rtas()

2020-03-31 Thread Christophe Leroy
machine_check_in_rtas() is just a trap. Do the trap directly in the machine check exception handler. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/kernel/entry_32.S | 6 -- arch/powerpc/kernel/head_32.S | 2 +- 2 files changed, 1 insertion(+), 7 deletions(-) di

[PATCH v2 09/12] powerpc/32: Blacklist functions running with MMU disabled for kprobe

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode, all functions running with MMU disabled have to be blacklisted. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/kernel/cpu_setup_6xx.S | 2 ++ arch/powerpc/kernel/entry_32.S | 3 +++ arch/powerpc/kernel/fpu.S

[PATCH v2 10/12] powerpc/entry32: Blacklist exception entry points for kprobe.

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode. As exception entry points are running with MMU disabled, blacklist them. The handling of TLF_NAPPING and TLF_SLEEPING is moved before the CONFIG_TRACE_IRQFLAGS which contains 'reenable_mmu' because from there kprobe will be possible as the ker

[PATCH v2 11/12] powerpc/entry32: Blacklist syscall exit points for kprobe.

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode. The very last part of syscall cannot support a trap. Add a symbol syscall_exit_finish to identify that part and blacklist it from kprobe. Signed-off-by: Christophe Leroy Acked-by: Naveen N. Rao --- arch/powerpc/kernel/entry_32.S | 3 +++ 1

[PATCH v2 12/12] powerpc/entry32: Blacklist exception exit points for kprobe.

2020-03-31 Thread Christophe Leroy
kprobe does not handle events happening in real mode. The very last part of exception exits cannot support a trap. Blacklist them from kprobe. While we are at it, remove exc_exit_start symbol which is not used to avoid having to blacklist it. Signed-off-by: Christophe Leroy Acked-by: Naveen N.

Re: [PATCH v2 09/11] powerpc/platforms: Move files from 4xx to 44x

2020-03-31 Thread Arnd Bergmann
On Tue, Mar 31, 2020 at 5:26 PM Christophe Leroy wrote: > Le 31/03/2020 à 17:14, Arnd Bergmann a écrit : > > On Tue, Mar 31, 2020 at 9:49 AM Christophe Leroy > > wrote: > >> > >> Only 44x uses 4xx now, so only keep one directory. > >> > >> Signed-off-by: Christophe Leroy > >> --- > >> arch/pow

Re: [PATCH v2 09/11] powerpc/platforms: Move files from 4xx to 44x

2020-03-31 Thread Christophe Leroy
Le 31/03/2020 à 18:04, Arnd Bergmann a écrit : On Tue, Mar 31, 2020 at 5:26 PM Christophe Leroy wrote: Le 31/03/2020 à 17:14, Arnd Bergmann a écrit : On Tue, Mar 31, 2020 at 9:49 AM Christophe Leroy wrote: Only 44x uses 4xx now, so only keep one directory. Signed-off-by: Christophe Lero

Re: [PATCH] powerpc/44x: Make AKEBONO depends on NET

2020-03-31 Thread Christoph Hellwig
Why would a board select a network driver? That is what defconfig files are for! I thin kthe select should just go away.

Re: [PATCH v2 10/12] powerpc/entry32: Blacklist exception entry points for kprobe.

2020-03-31 Thread Naveen N. Rao
Christophe Leroy wrote: kprobe does not handle events happening in real mode. As exception entry points are running with MMU disabled, blacklist them. The handling of TLF_NAPPING and TLF_SLEEPING is moved before the CONFIG_TRACE_IRQFLAGS which contains 'reenable_mmu' because from there kprobe w

Re: [PATCH 0/2] powerpc: Remove support for ppc405/440 Xilinx platforms

2020-03-31 Thread Segher Boessenkool
On Tue, Mar 31, 2020 at 08:56:23AM +0200, Christophe Leroy wrote: > While we are at it, can we also remove the 601 ? This one is also full > of workarounds and diverges a bit from other 6xx. > > I'm unable to find its end of life date, but it was on the market in > 1994, so I guess it must be ou

Re: [PATCH v2 09/11] powerpc/platforms: Move files from 4xx to 44x

2020-03-31 Thread Arnd Bergmann
On Tue, Mar 31, 2020 at 6:19 PM Christophe Leroy wrote: > Le 31/03/2020 à 18:04, Arnd Bergmann a écrit : > > That has the risk of breaking user's defconfig files, but given the > > small number of users, it may be nicer for consistency. In either > > case, the two symbols should probably hang arou

  1   2   >