Re: [PATCH v2 04/11] powerpc/powernv/ioda: Release opencapi device

2019-11-21 Thread Andrew Donnellan
device, but it's harmless, and only needs minor tuning. Also separate the undo of the PELT-V code in a separate function, it is not needed for NPU devices and it improves a bit the readability of the code. Signed-off-by: Frederic Barrat Reviewed-by: Andrew Donnellan -- Andrew Donn

Re: [PATCH 00/14] powerpc/vas: Page fault handling for user space NX requests

2019-11-26 Thread Andrew Donnellan
S instance after credits returned In future, please send the patches in reply to the cover letter (and for series that don't have a cover letter, send patch 2 onwards as a reply to patch 1). You may want to consider using git send-email which automates all this for you. Thanks, -- A

Re: [PATCH 00/18] Initial Prefixed Instruction support

2019-12-02 Thread Andrew Donnellan
/snowpatch/job/snowpatch-linux-sparse/14381//artifact/linux/report.txt (And a few minor checkpatch things too) -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [PATCH v2 02/27] nvdimm: remove prototypes for nonexistent functions

2019-12-02 Thread Andrew Donnellan
On 3/12/19 2:46 pm, Alastair D'Silva wrote: From: Alastair D'Silva These functions don't exist, so remove the prototypes for them. Signed-off-by: Alastair D'Silva Reviewed-by: Frederic Barrat Reviewed-by: Andrew Donnellan -- Andrew Donnellan Oz

Re: [PATCH v2 26/27] powerpc: Enable OpenCAPI Storage Class Memory driver on bare metal

2019-12-02 Thread Andrew Donnellan
arch/powerpc/configs/powernv_defconfig @@ -352,3 +352,7 @@ CONFIG_KVM_BOOK3S_64=m CONFIG_KVM_BOOK3S_64_HV=m CONFIG_VHOST_NET=m CONFIG_PRINTK_TIME=y +CONFIG_OCXL_SCM=m +CONFIG_DEV_DAX=m +CONFIG_DEV_DAX_PMEM=m +CONFIG_FS_DAX=m -- Andrew Donnellan OzLabs, ADL Canberr

[PATCH] powerpc: Fix __clear_user() with KUAP enabled

2019-12-09 Thread Andrew Donnellan
: Daniel Axtens Suggested-by: Michael Ellerman Cc: Christophe Leroy Cc: Russell Currey Fixes: de78a9c42a79 ("powerpc: Add a framework for Kernel Userspace Access Protection") Signed-off-by: Andrew Donnellan --- arch/powerpc/include/asm/uaccess.h | 9 +++-- arch/powerpc/lib/string_32.S

Re: [PATCH] powerpc: Fix __clear_user() with KUAP enabled

2019-12-09 Thread Andrew Donnellan
On 9/12/19 10:50 pm, Christophe Leroy wrote: Le 09/12/2019 à 11:59, Andrew Donnellan a écrit : The KUAP implementation adds calls in clear_user() to enable and disable access to userspace memory. However, it doesn't add these to __clear_user(), which is used in the ptrace regset code

[PATCH v2] powerpc: Fix __clear_user() with KUAP enabled

2019-12-09 Thread Andrew Donnellan
: Daniel Axtens Suggested-by: Michael Ellerman Cc: Christophe Leroy Cc: Russell Currey Fixes: de78a9c42a79 ("powerpc: Add a framework for Kernel Userspace Access Protection") Signed-off-by: Andrew Donnellan --- v1->v2: - fix checkpatch warnings (thanks snowpatch) --- arch/power

Re: [PATCH] powerpc: Fix __clear_user() with KUAP enabled

2019-12-09 Thread Andrew Donnellan
, I ran it past mpe privately and he suggested aliasing clear_user() -> __clear_user() instead, as there's not much point keeping a separate path around for a single user for a basically non-existent performance gain. -- Andrew Donnellan OzLabs, ADL Canberra a...@linux

Re: [PATCH v3] ocxl: Fix potential memory leak on context creation

2019-12-09 Thread Andrew Donnellan
On 9/12/19 9:55 pm, Frederic Barrat wrote: If we couldn't fully init a context, we were leaking memory. Fixes: b9721d275cc2 ("ocxl: Allow external drivers to use OpenCAPI contexts") Signed-off-by: Frederic Barrat Acked-by: Andrew Donnellan -- Andrew Donnellan

Re: [PATCH] cxl: Rework error message for incompatible slots

2020-04-07 Thread Andrew Donnellan
: Frederic Barrat Seems fine to me, not sure if it needs to go to stable but I suppose this could be causing actual confusion out in the field? Reviewed-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [PATCH 31/35] powerpc: docs: cxl.rst: mark two section titles as such

2020-04-08 Thread Andrew Donnellan
On 9/4/20 1:46 am, Mauro Carvalho Chehab wrote: The User API chapter contains two sub-chapters. Mark them as such. Signed-off-by: Mauro Carvalho Chehab Thanks. Though the other subsections in this file use - rather than ^, what's the difference? Acked-by: Andrew Donn

Re: [PATCH v2 25/33] docs: powerpc: cxl.rst: mark two section titles as such

2020-04-14 Thread Andrew Donnellan
On 15/4/20 2:48 am, Mauro Carvalho Chehab wrote: The User API chapter contains two sub-chapters. Mark them as such. Signed-off-by: Mauro Carvalho Chehab Acked-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

[PATCH 4.14] powerpc/powernv/idle: Restore AMR/UAMOR/AMOR after idle

2020-04-15 Thread Andrew Donnellan
Ellerman [ajd: Backport to 4.14 tree, CVE-2020-11669] Signed-off-by: Andrew Donnellan --- arch/powerpc/kernel/idle_book3s.S | 27 +++ 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/arch/powerpc/kernel/idle_book3s.S b/arch/powerpc/kernel/idle_book3s.S index

[PATCH 4.19] powerpc/powernv/idle: Restore AMR/UAMOR/AMOR after idle

2020-04-15 Thread Andrew Donnellan
Ellerman [ajd: Backport to 4.19 tree, CVE-2020-11669] Signed-off-by: Andrew Donnellan --- arch/powerpc/kernel/idle_book3s.S | 27 +++ 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/arch/powerpc/kernel/idle_book3s.S b/arch/powerpc/kernel/idle_book3s.S index

CVE-2020-11669: Linux kernel 4.10 to 5.1: powerpc: guest can cause DoS on POWER9 KVM hosts

2020-04-15 Thread Andrew Donnellan
/pipermail/linuxppc-dev/2020-April/208660.html [3] https://access.redhat.com/errata/RHSA-2019:3517 -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [PATCH AUTOSEL 5.5 73/75] ocxl: Add PCI hotplug dependency to Kconfig

2020-04-19 Thread Andrew Donnellan
On 19/4/20 12:09 am, Sasha Levin wrote: From: Frederic Barrat [ Upstream commit 49ce94b8677c7d7a15c4d7cbbb9ff1cd8387827b ] The PCI hotplug framework is used to update the devices when a new image is written to the FPGA. Reviewed-by: Alastair D'Silva Reviewed-by: Andrew Donnellan Signe

Re: [PATCH] ocxl: Fix access to the AFU Descriptor Data

2018-08-13 Thread Andrew Donnellan
v, fn, OCXL_DVSEC_TEMPL_VERSION, &val); if (rc) return rc; -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH V2] ocxl: Fix access to the AFU Descriptor Data

2018-08-13 Thread Andrew Donnellan
Descriptor Data indexed by the AFU Info Index field. Fixes: 5ef3166e8a32 ("ocxl: Driver code for 'generic' opencapi devices") Cc: stable # 4.16 Signed-off-by: Christophe Lombard Thanks Acked-by: Andrew Donnellan --- Changelog[v2] - Rebase to latest upstream. - Use p

Re: [PATCH v2 3/4] powerpc/mm: fix a warning when a cache is common to PGD and hugepages

2018-08-23 Thread Andrew Donnellan
;d keep logs indefinitely but they're several megs per build. I've kicked off another build for this series and the links in Patchwork should update to point to the new job when it's done (probably in the next couple of hours). -- Andrew Donnellan OzLabs, ADL Ca

Re: [PATCH] misc: Convert to using %pOFn instead of device_node.name

2018-08-27 Thread Andrew Donnellan
On 28/08/18 11:52, Rob Herring wrote: In preparation to remove the node name pointer from struct device_node, convert printf users to use the %pOFn format specifier. Cc: Frederic Barrat Cc: Andrew Donnellan Cc: Arnd Bergmann Cc: Greg Kroah-Hartman Cc: linuxppc-dev@lists.ozlabs.org Signed

Re: [PATCH] powerpc/powernv: Make possible for user to force a full ipl cec reboot

2018-09-02 Thread Andrew Donnellan
PAL_REBOOT_FULL_IPL, NULL); You might want to check for OPAL_UNSUPPORTED here just in case we're running on ancient firmware. + else + rc = opal_cec_reboot(); + if (rc == OPAL_BUSY_EVENT) opal_poll

Re: [PATCH v2] powerpc/powernv: Make possible for user to force a full ipl cec reboot

2018-09-03 Thread Andrew Donnellan
l_cec_reboot() is the normal case. But either way: Acked-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH v3] powerpc/powernv: Make possible for user to force a full ipl cec reboot

2018-09-07 Thread Andrew Donnellan
tes pnv_restart() to handle this cmd-arg and issues opal_cec_reboot2 with OPAL_REBOOT_FULL_IPL to force a full IPL reset. Signed-off-by: Vaibhav Jain This looks better! Acked-by: Andrew Donnellan --- Change-log: v3 -> Re-factored the code to make it more readable [Andrew]

Re: [PATCH v2 03/17] compat_ioctl: use correct compat_ptr() translation in drivers

2018-09-12 Thread Andrew Donnellan
other architectures, compat_ptr() does not do anything, but using the new generic_compat_ioctl_ptrarg helper makes it more correct in theory, and simplifies the code. Signed-off-by: Arnd Bergmann For cxl: Acked-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel..

Re: [PATCH kernel] cxl: Remove unused include

2018-09-28 Thread Andrew Donnellan
On 28/9/18 4:38 pm, Alexey Kardashevskiy wrote: The included opal.h gives a wrong idea that CXL makes PPC OPAL calls while it does not so let's remote it. Signed-off-by: Alexey Kardashevskiy Thanks for catching this Acked-by: Andrew Donnellan --- drivers/misc/cxl/pci.c | 1 - 1

Re: [PATCH] misc: cxl: Use device_type helpers to access the node type

2018-11-18 Thread Andrew Donnellan
're getting the device_type property directly. Cc: Frederic Barrat Cc: Andrew Donnellan Cc: Arnd Bergmann Cc: Greg Kroah-Hartman Cc: linuxppc-dev@lists.ozlabs.org Signed-off-by: Rob Herring Apart from that: Acked-by: Andrew Donnellan --- drivers/misc/cxl/pci.c | 4 +--- 1 file

Re: [PATCH] powerpc/tools/checkpatch: Ignore DT_SPLIT_BINDING_PATCH

2018-12-03 Thread Andrew Donnellan
On 4/12/18 4:11 pm, Russell Currey wrote: From what I've seen, every time this warning comes up it's bogus, so let's ignore it. Signed-off-by: Russell Currey Reviewed-by: Andrew Donnellan --- arch/powerpc/tools/checkpatch.sh | 1 + 1 file changed, 1 insertion(+) di

Re: [PATCH] ocxl: Fix endiannes bug in read_afu_name()

2018-12-10 Thread Andrew Donnellan
*/ return 0; -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH] ocxl/afu_irq: Don't include

2018-12-10 Thread Andrew Donnellan
Acked-by: Andrew Donnellan On 11/12/18 2:13 am, Greg Kurz wrote: The AFU irq code doesn't need to reach out to the platform. Signed-off-by: Greg Kurz --- drivers/misc/ocxl/afu_irq.c |1 - 1 file changed, 1 deletion(-) diff --git a/drivers/misc/ocxl/afu_irq.c b/drivers/misc

Re: [PATCH] ocxl: Clarify error path in setup_xsl_irq()

2018-12-10 Thread Andrew Donnellan
: Greg Kurz This is good, thanks. Acked-by: Andrew Donnellan --- drivers/misc/ocxl/link.c | 23 ++- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/drivers/misc/ocxl/link.c b/drivers/misc/ocxl/link.c index eed92055184d..659977a17405 100644 --- a/drivers

Re: [PATCH] ocxl: Fix endiannes bug in read_afu_name()

2018-12-10 Thread Andrew Donnellan
On 11/12/18 11:05 am, Andrew Donnellan wrote: On 11/12/18 2:10 am, Greg Kurz wrote: The double word returned by read_afu_info(OCXL_DVSEC_TEMPL_NAME) contains four characters of the AFU name, read from the PCI config space, hence with a little-endian ordering. When composing the string, a big

Re: [PATCH] ocxl: Simplify free_spa()

2018-12-10 Thread Andrew Donnellan
inter. Drop both. Signed-off-by: Greg Kurz I like defensive programming but for this case I don't really care too much either way Acked-by: Andrew Donnellan --- drivers/misc/ocxl/link.c |7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/misc/ocxl/link.

Re: [PATCH] ocxl: Simplify free_spa()

2018-12-11 Thread Andrew Donnellan
e obvious they're not needed... Should I re-post this as two patches for clarity ? Ah, that makes much more sense. If that's the case, then why not go all the way and change the function signature while you're at it? -- Andrew Donnellan OzLabs, ADL Canberra andrew.

Re: [PATCH v2] ocxl: Fix endiannes bug in read_afu_name()

2018-12-11 Thread Andrew Donnellan
with le32_to_cpu(). Cc: sta...@vger.kernel.org # v4.16 Signed-off-by: Greg Kurz Acked-by: Frederic Barrat Acked-by: Andrew Donnellan --- v2: - silence sparse with (__force __le32) cast - new changelog --- drivers/misc/ocxl/config.c |2 +- 1 file changed, 1 insertion(+), 1 del

Re: [PATCH 8/8] cxl: drop the dma_set_mask callback from vphb

2018-12-16 Thread Andrew Donnellan
On 17/12/18 4:19 am, Christoph Hellwig wrote: The CXL code never even looks at the dma mask, so there is no good reason for this sanity check. Remove it because it gets in the way of the dma ops refactoring. Signed-off-by: Christoph Hellwig Acked-by: Andrew Donnellan --- drivers/misc

Re: [PATCH] ocxl: Fix endiannes bug in ocxl_link_update_pe()

2018-12-16 Thread Andrew Donnellan
kernel.org # v4.18 Signed-off-by: Greg Kurz If only we read our sparse warnings which would have told us this. One warning down :) Thanks for finding this! Acked-by: Andrew Donnellan --- This bug remained unnoticed so far because the current OCXL test suite happe

Re: [PATCH 01/14] ABI: fix some syntax issues at the ABI database

2019-06-14 Thread Andrew Donnellan
note" over "Please notice". Acked-by: Andrew Donnellan # cxl -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [PATCH v2] cxl: no need to check return value of debugfs_create functions

2019-06-14 Thread Andrew Donnellan
f the local debugfs_create_io_x64() call void, as no one ever did anything with the return value (as they did not need to.) And make the cxl_debugfs_* calls return void as no one was even checking their return value at all. Cc: Frederic Barrat Cc: Andrew Donnellan Cc: Arnd Bergmann Cc: linuxpp

Re: [PATCH] ocxl: Allow contexts to be attached with a NULL mm

2019-06-17 Thread Andrew Donnellan
_remove_copro(pe_data->mm); - mmdrop(pe_data->mm); + if (pe_data->mm) { + mm_context_remove_copro(pe_data->mm); + mmdrop(pe_data->mm); + } kfree_rcu(pe_data, rcu); } unlock: -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [PATCH v2] ocxl: Allow contexts to be attached with a NULL mm

2019-06-20 Thread Andrew Donnellan
if (pe_data->mm) { + mm_context_remove_copro(pe_data->mm); + mmdrop(pe_data->mm); + } kfree_rcu(pe_data, rcu); } unlock: -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [PATCH] ocxl: Update for AFU descriptor template version 1.1

2019-06-24 Thread Andrew Donnellan
river doesn't do much yet to support LPC memory but as we start seeing (non-LPC) AFU images using the new template, this patch updates the config space parsing code to avoid spitting a warning. Signed-off-by: Alastair D'Silva Signed-off-by: Frederic Barrat Acked-by: Andrew Donnellan Alast

Re: [PATCH 22/39] docs: ocxl.rst: add it to the uAPI book

2019-06-30 Thread Andrew Donnellan
On 28/6/19 10:30 pm, Mauro Carvalho Chehab wrote: The content of this file is user-faced. Signed-off-by: Mauro Carvalho Chehab Acked-by: Andrew Donnellan --- Documentation/{ => userspace-api}/accelerators/ocxl.rst | 2 -- Documentation/userspace-api/index.rst

Re: [RFC 02/11] powerpc/powernv/ioda: Protect PE list

2019-07-01 Thread Andrew Donnellan
pe_list_mutex); list_del(&pe->list); + mutex_unlock(&phb->ioda.pe_list_mutex); + switch (phb->type) { case PNV_PHB_IODA1: pnv_pci_ioda1_release_pe_dma(pe); -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [RFC 11/11] ocxl: Add PCI hotplug dependency to Kconfig

2019-07-02 Thread Andrew Donnellan
On 19/6/19 11:28 pm, Frederic Barrat wrote: The PCI hotplug framework is used to update the devices when a new image is written to the FPGA. Signed-off-by: Frederic Barrat Acked-by: Andrew Donnellan --- drivers/misc/ocxl/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a

Re: [RFC 09/11] pci/hotplug/pnv-php: Relax check when disabling slot

2019-07-02 Thread Andrew Donnellan
allow to disable a slot in the REGISTERED state. Removing the devices will do nothing since it's not populated, and we'll set the power state of the slot back to off. Signed-off-by: Frederic Barrat Reviewed-by: Andrew Donnellan --- drivers/pci/hotplug/pnv_php.c | 8 +++- 1

Re: [PATCH v5] powerpc/64s: support nospectre_v2 cmdline option

2019-07-09 Thread Andrew Donnellan
On 5/6/19 5:42 pm, Andrew Donnellan wrote: On 24/5/19 12:46 pm, Christopher M. Riedl wrote: Add support for disabling the kernel implemented spectre v2 mitigation (count cache flush on context switch) via the nospectre_v2 and mitigations=off cmdline options. Suggested-by: Michael Ellerman

Re: [PATCH v2] powerpc/powernv: Restrict OPAL symbol map to only be readable by root

2019-07-30 Thread Andrew Donnellan
On 3/5/19 5:52 pm, Andrew Donnellan wrote: Currently the OPAL symbol map is globally readable, which seems bad as it contains physical addresses. Restrict it to root. Suggested-by: Michael Ellerman Cc: Jordan Niethe Cc: Stewart Smith Fixes: c8742f85125d ("powerpc/powernv: Expose

Re: [PATCH v2 5/5] powerpc/configs: Disable SCOM_DEBUGFS in powernv_defconfig

2019-07-30 Thread Andrew Donnellan
On 9/5/19 3:54 pm, Andrew Donnellan wrote: On 9/5/19 3:37 pm, Nicholas Piggin wrote: Andrew Donnellan's on May 9, 2019 3:11 pm: SCOM_DEBUGFS is really not needed for anything other than low-level hardware debugging. opal-prd uses its own interface (/dev/prd) for SCOM access, so it do

Re: [PATCH 1/3] powerpc/spinlocks: Refactor SHARED_PROCESSOR

2019-07-31 Thread Andrew Donnellan
On 28/7/19 10:54 pm, Christopher M. Riedl wrote: Determining if a processor is in shared processor mode is not a constant so don't hide it behind a #define. Signed-off-by: Christopher M. Riedl This seems aesthetically more right. Reviewed-by: Andrew Donnellan --- arch/powerpc/in

Re: [PATCH 2/3] powerpc/spinlocks: Rename SPLPAR-only spinlocks

2019-07-31 Thread Andrew Donnellan
On 28/7/19 10:54 pm, Christopher M. Riedl wrote: The __rw_yield and __spin_yield locks only pertain to SPLPAR mode. Rename them to make this relationship obvious. Signed-off-by: Christopher M. Riedl Reviewed-by: Andrew Donnellan --- arch/powerpc/include/asm/spinlock.h | 6 -- arch

Re: [PATCH 3/3] powerpc/spinlock: Fix oops in shared-processor spinlocks

2019-07-31 Thread Andrew Donnellan
_rw_yield(lock) -#define arch_write_relax(lock) __rw_yield(lock) +#define arch_spin_relax(lock) spin_yield(lock) +#define arch_read_relax(lock) rw_yield(lock) +#define arch_write_relax(lock) rw_yield(lock) /* See include/linux/spinlock.h */ #define smp_mb__after_spinlock() smp_mb(

[PATCH] powerpc/configs: Add debug config fragment

2019-07-31 Thread Andrew Donnellan
Add a debug config fragment that we can use to put useful debug options into. Currently we only define a target for powernv[_be]_debug_defconfig, and the only option included is to enable debugfs SCOM access. Suggested-by: Michael Ellerman Signed-off-by: Andrew Donnellan --- arch/powerpc

Re: [RFC PATCH v4 1/2] powerpc/xmon: Allow listing active breakpoints in read-only mode

2019-08-15 Thread Andrew Donnellan
r all breakpoints */ for (i = 0; i < NBPTS; ++i) Clearing breakpoints is probably alright too. -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

Re: [PATCH] powerpc/powernv/npu: Fix oops in pnv_try_setup_npu_table_group()

2019-01-09 Thread Andrew Donnellan
pound IOMMU groups") Signed-off-by: Frederic Barrat Reviewed-by: Andrew Donnellan --- arch/powerpc/platforms/powernv/pci-ioda.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/powerpc/platforms/powernv/pci-ioda.c b/arch/powerpc/platforms/powernv/pci-io

[RFC PATCH] powerpc: Enable kcov

2019-01-14 Thread Andrew Donnellan
kcov provides kernel coverage data that's useful for fuzzing tools like syzkaller. Wire up kcov support on powerpc. Disable kcov instrumentation on the same files where we currently disable gcov and UBSan instrumentation. Signed-off-by: Andrew Donnellan --- kcov looks like it's wo

Re: [RFC PATCH] powerpc: Enable kcov

2019-01-15 Thread Andrew Donnellan
On 15/1/19 5:40 pm, Dmitry Vyukov wrote: On Tue, Jan 15, 2019 at 5:20 AM Andrew Donnellan wrote: kcov provides kernel coverage data that's useful for fuzzing tools like syzkaller. Wire up kcov support on powerpc. Disable kcov instrumentation on the same files where we currently disable

Re: gcc 6.3 vs 8.2 Re: [RFC PATCH] powerpc: Enable kcov

2019-01-15 Thread Andrew Donnellan
On 15/1/19 6:26 pm, Mathieu Malaterre wrote: [Sorry to hijack this thread. ] On Tue, Jan 15, 2019 at 5:22 AM Andrew Donnellan wrote: kcov provides kernel coverage data that's useful for fuzzing tools like syzkaller. Wire up kcov support on powerpc. Disable kcov instrumentation on the

Re: [PATCH v2 1/5] drivers/accel: Introduce subsystem

2019-01-26 Thread Andrew Donnellan
he CAPI or OpenCAPI protocol respectively - many of which will be FPGA boards flashed with customer-designed accelerator cores for specific workloads, some will be accelerators using ASICs or using FPGA images supplied by vendors, some will be driven from userspace, others using the cxl/ocxl kernel A

Re: [PATCH v3] cxl: Wrap iterations over afu slices inside 'afu_list_lock'

2019-01-28 Thread Andrew Donnellan
rapped within the context of spin-lock 'adapter->afu_list_lock'. Signed-off-by: Vaibhav Jain Does this need to go to stable? (I'm guessing we've been hitting actual Oopses?) Acked-by: Andrew Donnellan --- Changelog: v3: * Updated a slice loop in cxl_pci_error_det

[PATCH 1/2] powerpc/64s: Work around spurious warning on old gccs with -fsanitize-coverage

2019-02-06 Thread Andrew Donnellan
Some older gccs (cpu_ftr_bit_mask) An upcoming patch will enable support for kcov, which requires -fsanitize-coverage=trace-pc. Work around this by explicitly initialising m to NULL. Signed-off-by: Andrew Donnellan --- arch/powerpc/kernel/dt_cpu_ftrs.c | 2 +- 1 file changed, 1 insertion

[PATCH 2/2] powerpc: Enable kcov

2019-02-06 Thread Andrew Donnellan
kcov provides kernel coverage data that's useful for fuzzing tools like syzkaller. Wire up kcov support on powerpc. Disable kcov instrumentation on the same files where we currently disable gcov and UBSan instrumentation. Signed-off-by: Andrew Donnellan Acked-by: Dmitry Vyukov ---

Re: [PATCH 1/2] powerpc/64s: Work around spurious warning on old gccs with -fsanitize-coverage

2019-02-06 Thread Andrew Donnellan
On 7/2/19 5:37 pm, Segher Boessenkool wrote: On Thu, Feb 07, 2019 at 04:33:23PM +1100, Andrew Donnellan wrote: Some older gccs (cpu_ftr_bit_mask) It seems to me the warning is correct? If enable_unknown is false and no cpu_feature is found, it will in if (m->cpu_ftr_bit_m

Re: [PATCH 1/2] powerpc/64s: Work around spurious warning on old gccs with -fsanitize-coverage

2019-02-07 Thread Andrew Donnellan
(+ Nick) On 7/2/19 6:49 pm, Segher Boessenkool wrote: On Thu, Feb 07, 2019 at 05:59:48PM +1100, Andrew Donnellan wrote: On 7/2/19 5:37 pm, Segher Boessenkool wrote: On Thu, Feb 07, 2019 at 04:33:23PM +1100, Andrew Donnellan wrote: Some older gccs (cpu_ftr_bit_mask) It seems to me the

Re: [PATCH 1/2] powerpc/64s: Work around spurious warning on old gccs with -fsanitize-coverage

2019-02-07 Thread Andrew Donnellan
by kernel)\n", + f->name); + return false; } if (m->cpu_ftr_bit_mask) Sure, I can send a v2 with this fix and your signoff? -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH 1/2] powerpc/64s: Work around spurious warning on old gccs with -fsanitize-coverage

2019-02-09 Thread Andrew Donnellan
o this if "known", afaics. I've got a v2 ready to send which fixes both things. Segher -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

[PATCH v2 2/2] powerpc: Enable kcov

2019-02-10 Thread Andrew Donnellan
kcov provides kernel coverage data that's useful for fuzzing tools like syzkaller. Wire up kcov support on powerpc. Disable kcov instrumentation on the same files where we currently disable gcov and UBSan instrumentation. Signed-off-by: Andrew Donnellan Acked-by: Dmitry Vyukov ---

[PATCH v2 1/2] powerpc/64s: Fix logic when handling unknown CPU features

2019-02-10 Thread Andrew Donnellan
message] Signed-off-by: Andrew Donnellan --- v1->v2: - fix the other logic errors in this function (segher, mpe) --- arch/powerpc/kernel/dt_cpu_ftrs.c | 17 +++-- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/arch/powerpc/kernel/dt_cpu_ftrs.c b/arch/powerpc/ker

Re: [RFC PATCH 1/5] kasan: do not open-code addr_has_shadow

2019-02-14 Thread Andrew Donnellan
override the layout of the shadow mapping. Signed-off-by: Daniel Axtens Reviewed-by: Andrew Donnellan --- mm/kasan/generic.c | 3 +-- mm/kasan/tags.c| 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/mm/kasan/generic.c b/mm/kasan/generic.c index ccb6207276e3

Re: [RFC PATCH 4/5] powerpc: move KASAN into its own subdirectory

2019-02-14 Thread Andrew Donnellan
/kasan/kasan_init_32.c similarity index 100% rename from arch/powerpc/mm/kasan_init.c rename to arch/powerpc/mm/kasan/kasan_init_32.c -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH v2 2/2] powerpc: Enable kcov

2019-02-19 Thread Andrew Donnellan
t telling us anything interesting, for example), but certainly this is a great start. I think syzkaller (as the main kcov consumer) can probably cope... With those changes, Tested-by: Daniel Axtens # e6500 -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

[PATCH v3 2/2] powerpc: Enable kcov

2019-02-21 Thread Andrew Donnellan
ook3e machines. Signed-off-by: Andrew Donnellan Acked-by: Dmitry Vyukov Tested-by: Daniel Axtens # e6500 --- v2->v3: - Add additional exclusions required to boot on book3e (dja) --- arch/powerpc/Kconfig| 1 + arch/powerpc/kernel/Makefile| 12 +++- arch/powerp

[PATCH v3 1/2] powerpc/64s: Fix logic when handling unknown CPU features

2019-02-21 Thread Andrew Donnellan
message] Signed-off-by: Andrew Donnellan --- arch/powerpc/kernel/dt_cpu_ftrs.c | 17 +++-- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/arch/powerpc/kernel/dt_cpu_ftrs.c b/arch/powerpc/kernel/dt_cpu_ftrs.c index 8be3721d9302..e49bd5efcfe6 100644 --- a/arch/powerpc/

Re: [PATCH v5 1/7] powerpc: Add TIDR CPU feature for POWER9

2018-05-30 Thread Andrew Donnellan
On 11/05/18 16:12, Alastair D'Silva wrote: From: Alastair D'Silva This patch adds a CPU feature bit to show whether the CPU has the TIDR register available, enabling as_notify/wait in userspace. Signed-off-by: Alastair D'Silva Reviewed-by: Andrew Donnellan -- A

Re: [PATCH v5 2/7] powerpc: Use TIDR CPU feature to control TIDR allocation

2018-05-30 Thread Andrew Donnellan
On 11/05/18 16:12, Alastair D'Silva wrote: From: Alastair D'Silva Switch the use of TIDR on it's CPU feature, rather than assuming it is available based on architecture. Signed-off-by: Alastair D'Silva Reviewed-by: Andrew Donnellan -- Andrew Donnellan

Re: [PATCH v5 3/7] powerpc: use task_pid_nr() for TID allocation

2018-05-30 Thread Andrew Donnellan
va Thanks for the clarifying comment. The diff is painful to read but I think it makes sense :) Reviewed-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH v5 4/7] ocxl: Rename pnv_ocxl_spa_remove_pe to clarify it's action

2018-05-30 Thread Andrew Donnellan
On 11/05/18 16:13, Alastair D'Silva wrote: From: Alastair D'Silva The function removes the process element from NPU cache. Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH v5 5/7] ocxl: Expose the thread_id needed for wait on POWER9

2018-05-30 Thread Andrew Donnellan
ir D'Silva Acked-by: Andrew Donnellan Comments below. +#ifdef CONFIG_PPC64 +static long afu_ioctl_enable_p9_wait(struct ocxl_context *ctx, + struct ocxl_ioctl_p9_wait __user *uarg) +{ + struct ocxl_ioctl_p9_wait arg; + + memset(&arg, 0, sizeof(

Re: [PATCH v5 6/7] ocxl: Add an IOCTL so userspace knows what OCXL features are available

2018-05-30 Thread Andrew Donnellan
On 11/05/18 16:13, Alastair D'Silva wrote: From: Alastair D'Silva In order for a userspace AFU driver to call the POWER9 specific OCXL_IOCTL_ENABLE_P9_WAIT, it needs to verify that it can actually make that call. Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnel

Re: [PATCH v5 7/7] ocxl: Document new OCXL IOCTLs

2018-05-30 Thread Andrew Donnellan
On 11/05/18 16:13, Alastair D'Silva wrote: From: Alastair D'Silva Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH] misc: ocxl: Change return type for fault handler

2018-06-11 Thread Andrew Donnellan
ptick Joarder Looks okay to me Acked-by: Andrew Donnellan --- drivers/misc/ocxl/context.c | 22 +++--- drivers/misc/ocxl/sysfs.c | 5 ++--- 2 files changed, 13 insertions(+), 14 deletions(-) diff --git a/drivers/misc/ocxl/context.c b/drivers/misc/ocxl/context.c index 909

Re: [PATCH] ocxl: Fix page fault handler in case of fault on dying process

2018-06-22 Thread Andrew Donnellan
re and it looks right. Acked-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH 00/10] cxl: Remove abandonned capi support for the Mellanox CX4

2018-06-25 Thread Andrew Donnellan
emcpy tests on POWER8 and POWER9 - Mellanox CX5, which uses a different code path, based on cxllib - cxlflash tests on POWER8 9 of these commits are missing Signed-off-bys. git revert -s is a thing :) -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH 00/10] cxl: Remove abandonned capi support for the Mellanox CX4

2018-06-25 Thread Andrew Donnellan
On 26/06/18 12:31, Andrew Donnellan wrote: 9 of these commits are missing Signed-off-bys. git revert -s is a thing :) After mentally preparing myself for the flashbacks from when we had to implement some of these hacks in the first place, I've read through the rest of the series and i

Re: [PATCH v2 01/10] Revert "cxl: Add kernel API to allow a context to operate with relocate disabled"

2018-06-28 Thread Andrew Donnellan
5c. Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnellan --- drivers/misc/cxl/api.c| 19 --- drivers/misc/cxl/cxl.h| 1 - drivers/misc/cxl/guest.c | 3 --- drivers/misc/cxl/native.c | 3 ++- include/misc/cxl.h| 8 5 files changed, 2 inse

Re: [PATCH v2 02/10] Revert "cxl: Add support for interrupts on the Mellanox CX4"

2018-06-28 Thread Andrew Donnellan
On 28/06/18 20:05, Frederic Barrat wrote: From: Alastair D'Silva Remove abandonned capi support for the Mellanox CX4. This reverts commit a2f67d5ee8d950caaa7a6144cf0bfb256500b73e. Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnellan --- arch/powerpc/platforms/powernv

Re: [PATCH v2 03/10] Revert "cxl: Add preliminary workaround for CX4 interrupt limitation"

2018-06-28 Thread Andrew Donnellan
On 28/06/18 20:05, Frederic Barrat wrote: From: Alastair D'Silva Remove abandonned capi support for the Mellanox CX4. This reverts commit cbce0917e2e47d4bf5aa3b5fd6b1247f33e1a126. Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnellan --- drivers/misc/cxl/api.

Re: [PATCH v2 04/10] Revert "cxl: Add kernel APIs to get & set the max irqs per context"

2018-06-28 Thread Andrew Donnellan
On 28/06/18 20:05, Frederic Barrat wrote: From: Alastair D'Silva Remove abandonned capi support for the Mellanox CX4. This reverts commit 79384e4b71240abf50c375eea56060b0d79c242a. Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnellan --- drivers/misc/cxl/

Re: [PATCH v2 05/10] Revert "cxl: Add cxl_check_and_switch_mode() API to switch bi-modal cards"

2018-06-28 Thread Andrew Donnellan
lly worked... (Hmm, I should go back and see if there's anything we can rip out of pnv_php now...) Acked-by: Andrew Donnellan --- drivers/misc/cxl/Kconfig | 8 -- drivers/misc/cxl/pci.c | 236 +++ include/misc/cxl.h | 25 - 3 files changed

Re: [PATCH v2 06/10] Revert "cxl: Add support for using the kernel API with a real PHB"

2018-06-28 Thread Andrew Donnellan
On 28/06/18 20:05, Frederic Barrat wrote: From: Alastair D'Silva Remove abandonned capi support for the Mellanox CX4. This reverts commit 317f5ef1b363417b6f1e93b90dfd2ffd6be6e867. Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnellan --- drivers/misc/cxl/p

Re: [PATCH v2 07/10] Revert "powerpc/powernv: Add support for the cxl kernel api on the real phb"

2018-06-28 Thread Andrew Donnellan
On 28/06/18 20:05, Frederic Barrat wrote: From: Alastair D'Silva Remove abandonned capi support for the Mellanox CX4. This reverts commit 4361b03430d685610e5feea3ec7846e8b9ae795f. Signed-off-by: Alastair D'Silva Acked-by: Andrew Donnellan --- arch/powerpc/include/asm

Re: [PATCH v2 08/10] Revert "cxl: Add cxl_slot_is_supported API"

2018-06-28 Thread Andrew Donnellan
On 28/06/18 20:05, Frederic Barrat wrote: Remove abandonned capi support for the Mellanox CX4. This reverts commit 4e56f858bdde5cbfb70f61baddfaa56a8ed851bf. Signed-off-by: Frederic Barrat Acked-by: Andrew Donnellan --- drivers/misc/cxl/pci.c | 37

Re: [PATCH v2 09/10] Revert "cxl: Allow a default context to be associated with an external pci_dev"

2018-06-28 Thread Andrew Donnellan
On 28/06/18 20:05, Frederic Barrat wrote: Remove abandonned capi support for the Mellanox CX4. This reverts commit a19bd79e31769626d288cc016e21a31b6f47bf6f. Signed-off-by: Frederic Barrat Acked-by: Andrew Donnellan --- drivers/misc/cxl/Makefile | 2 +- drivers/misc/cxl/base.c | 35

Re: [PATCH v2 10/10] cxl: Remove abandonned capi support for the Mellanox CX4, final cleanup

2018-06-28 Thread Andrew Donnellan
On 28/06/18 20:05, Frederic Barrat wrote: Remove a few XSL/CX4 oddities which are no longer needed. A simple revert of the initial commits was not possible (or not worth it) due to the history of the code. Signed-off-by: Frederic Barrat Acked-by: Andrew Donnellan --- drivers/misc/cxl

Re: [PATCH] cxl: Fix wrong comparison in cxl_adapter_context_get()

2018-07-04 Thread Andrew Donnellan
e context exists") Reported-by: Dan Carpenter Signed-off-by: Vaibhav Jain Acked-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra andrew.donnel...@au1.ibm.com IBM Australia Limited

Re: [PATCH 1/2] selftests/powerpc: Skip earlier in alignment_handler test

2018-07-30 Thread Andrew Donnellan
like: test: test_alignment_handler_vsx_206 tags: git_version:v4.18-rc3-134-gfb21a48904aa [SKIP] Test skipped on line 291 skip: test_alignment_handler_vsx_206 Signed-off-by: Michael Ellerman This seems sensible. Acked-by: Andrew Donnellan --- .../powerpc/alignment/alig

Re: [PATCH v2 2/2] selftests/powerpc: Add more version checks to alignment_handler test

2018-07-31 Thread Andrew Donnellan
On 31/07/18 22:08, Michael Ellerman wrote: The alignment_handler is documented to only work on Power8/Power9, but we can make it run on older CPUs by guarding more of the tests with feature checks. Signed-off-by: Michael Ellerman Looks good to me. Reviewed-by: Andrew Donnellan

Re: [PATCH] misc: cxl: changed asterisk position

2018-08-05 Thread Andrew Donnellan
On 03/08/18 20:20, Parth Y Shah wrote: Resolved <"foo* bar" should be "foo *bar"> error Signed-off-by: Parth Y Shah Thanks for picking this up. Acked-by: Andrew Donnellan --- drivers/misc/cxl/fault.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) dif

Re: [PATCH] powerpc/64: Use {SAVE,REST}_NVGPRS macros

2019-12-10 Thread Andrew Donnellan
On 11/12/19 1:35 pm, Jordan Niethe wrote: In entry_64.S there are places that open code saving and restoring the non-volatile registers. There are already macros for doing this so use them. Signed-off-by: Jordan Niethe Reviewed-by: Andrew Donnellan -- Andrew Donnellan OzLabs

Re: [PATCH 1/2] powerpc/64s/exception: Remove unused parameters from KVMTEST macro

2019-12-10 Thread Andrew Donnellan
On 11/12/19 1:37 pm, Jordan Niethe wrote: The hsrr and n parameters are never used by the KVMTEST macro so remove them. Signed-off-by: Jordan Niethe Reviewed-by: Andrew Donnellan -- Andrew Donnellan OzLabs, ADL Canberra a...@linux.ibm.com IBM Australia Limited

<    1   2   3   4   5   6   7   8   9   10   >