[PATCH] powerpc/32s: Fix RTAS machine check with VMAP stack

2020-12-21 Thread Christophe Leroy
When we have VMAP stack, exception prolog 1 sets r1, not r11. Fixes: da7bb43ab9da ("powerpc/32: Fix vmap stack - Properly set r1 before activating MMU") Fixes: d2e006036082 ("powerpc/32: Use SPRN_SPRG_SCRATCH2 in exception prologs") Cc: sta...@vger.kernel.org Signed-off-by: Christophe Leroy ---

[Bug 210749] sysfs: cannot create duplicate filename '/bus/nvmem/devices/module-vpd'

2020-12-21 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=210749 --- Comment #2 from Erhard F. (erhar...@mailbox.org) --- Created attachment 294285 --> https://bugzilla.kernel.org/attachment.cgi?id=294285=edit dmesg (kernel 5.9.16, Talos II) Hmm... does not seem to happen on kernel 5.9.x. -- You may reply

Re: [PATCH 3/3] ibmvfc: use correlation token to tag commands

2020-12-21 Thread Nathan Chancellor
On Tue, Nov 17, 2020 at 12:50:31PM -0600, Tyrel Datwyler wrote: > The vfcFrame correlation field is 64bit handle that is intended to trace > I/O operations through both the client stack and VIOS stack when the > underlying physical FC adapter supports tagging. > > Tag vfcFrames with the

Re: [PATCH 3/3] powerpc: rewrite atomics to use ARCH_ATOMIC

2020-12-21 Thread Nicholas Piggin
Excerpts from Boqun Feng's message of November 14, 2020 1:30 am: > Hi Nicholas, > > On Wed, Nov 11, 2020 at 09:07:23PM +1000, Nicholas Piggin wrote: >> All the cool kids are doing it. >> >> Signed-off-by: Nicholas Piggin >> --- >> arch/powerpc/include/asm/atomic.h | 681

Re: [RFC PATCH 3/5] powerpc/64s: add CONFIG_PPC_NMMU for nest MMU support

2020-12-21 Thread Nicholas Piggin
Excerpts from Christophe Leroy's message of December 20, 2020 9:43 pm: > > > Le 20/12/2020 à 00:48, Nicholas Piggin a écrit : >> This allows some nest MMU features to be compiled away if coprocessor >> support is not selected. >> >> Signed-off-by: Nicholas Piggin >> --- >>

Re: [RFC PATCH 1/5] powerpc/64s: update_mmu_cache inline the radix test

2020-12-21 Thread Nicholas Piggin
Excerpts from Christophe Leroy's message of December 20, 2020 9:37 pm: > > > Le 20/12/2020 à 00:48, Nicholas Piggin a écrit : >> This allows the function to be entirely noped if hash support is >> compiled out (not possible yet). >> >> Signed-off-by: Nicholas Piggin >> --- >>

Re: [PATCH] powerpc: always enable queued spinlocks for 64s, disable for others

2020-12-21 Thread Nicholas Piggin
Excerpts from Christophe Leroy's message of December 21, 2020 4:04 pm: > > > Le 21/12/2020 à 04:22, Nicholas Piggin a écrit : >> Queued spinlocks have shown to have good performance and fairness >> properties even on smaller (2 socket) POWER systems. This selects >> them automatically for 64s.

Re: [PATCH] powerpc:Don't print raw EIP/LR hex values in dump_stack() and show_regs()

2020-12-21 Thread Segher Boessenkool
On Mon, Dec 21, 2020 at 04:42:23PM +, David Laight wrote: > From: Segher Boessenkool > > Sent: 21 December 2020 16:32 > > > > On Mon, Dec 21, 2020 at 04:17:21PM +0100, Christophe Leroy wrote: > > > Le 21/12/2020 à 04:27, Xiaoming Ni a écrit : > > > >Since the commit 2b0e86cc5de6

RE: [PATCH] powerpc:Don't print raw EIP/LR hex values in dump_stack() and show_regs()

2020-12-21 Thread David Laight
From: Segher Boessenkool > Sent: 21 December 2020 16:32 > > On Mon, Dec 21, 2020 at 04:17:21PM +0100, Christophe Leroy wrote: > > Le 21/12/2020 à 04:27, Xiaoming Ni a écrit : > > >Since the commit 2b0e86cc5de6 ("powerpc/fsl_booke/32: implement KASLR > > >infrastructure"), the powerpc system is

Re: [PATCH] powerpc:Don't print raw EIP/LR hex values in dump_stack() and show_regs()

2020-12-21 Thread Segher Boessenkool
On Mon, Dec 21, 2020 at 04:17:21PM +0100, Christophe Leroy wrote: > Le 21/12/2020 à 04:27, Xiaoming Ni a écrit : > >Since the commit 2b0e86cc5de6 ("powerpc/fsl_booke/32: implement KASLR > >infrastructure"), the powerpc system is ready to support KASLR. > >To reduces the risk of invalidating

Re: [PATCH] powerpc:Don't print raw EIP/LR hex values in dump_stack() and show_regs()

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 04:27, Xiaoming Ni a écrit : Since the commit 2b0e86cc5de6 ("powerpc/fsl_booke/32: implement KASLR infrastructure"), the powerpc system is ready to support KASLR. To reduces the risk of invalidating address randomization, don't print the EIP/LR hex values in dump_stack() and

Re: [RFC Qemu PATCH v2 1/2] spapr: drc: Add support for async hcalls at the drc level

2020-12-21 Thread Greg Kurz
On Mon, 21 Dec 2020 13:08:53 +0100 Greg Kurz wrote: > Hi Shiva, > > On Mon, 30 Nov 2020 09:16:39 -0600 > Shivaprasad G Bhat wrote: > > > The patch adds support for async hcalls at the DRC level for the > > spapr devices. To be used by spapr-scm devices in the patch/es to follow. > > > >

Re: [RFC Qemu PATCH v2 0/2] spapr: nvdimm: Asynchronus flush hcall support

2020-12-21 Thread Greg Kurz
On Mon, 30 Nov 2020 09:16:14 -0600 Shivaprasad G Bhat wrote: > The nvdimm devices are expected to ensure write persistent during power > failure kind of scenarios. > > The libpmem has architecture specific instructions like dcbf on power > to flush the cache data to backend nvdimm device during

Re: [RFC Qemu PATCH v2 2/2] spapr: nvdimm: Implement async flush hcalls

2020-12-21 Thread Greg Kurz
On Mon, 30 Nov 2020 09:17:24 -0600 Shivaprasad G Bhat wrote: > When the persistent memory beacked by a file, a cpu cache flush instruction > is not sufficient to ensure the stores are correctly flushed to the media. > > The patch implements the async hcalls for flush operation on demand from

Re: [RFC Qemu PATCH v2 1/2] spapr: drc: Add support for async hcalls at the drc level

2020-12-21 Thread Greg Kurz
Hi Shiva, On Mon, 30 Nov 2020 09:16:39 -0600 Shivaprasad G Bhat wrote: > The patch adds support for async hcalls at the DRC level for the > spapr devices. To be used by spapr-scm devices in the patch/es to follow. > > Signed-off-by: Shivaprasad G Bhat > --- The overall idea looks good but I

Re: [PATCH] KVM: PPC: fix comparison to bool warning

2020-12-21 Thread Michael Ellerman
On Sat, 7 Nov 2020 23:49:38 +0800, xiakaixu1...@gmail.com wrote: > Fix the following coccicheck warning: > > ./arch/powerpc/kvm/booke.c:503:6-16: WARNING: Comparison to bool > ./arch/powerpc/kvm/booke.c:505:6-17: WARNING: Comparison to bool > ./arch/powerpc/kvm/booke.c:507:6-16: WARNING:

Re: [PATCH] KVM: PPC: Book3S: Assign boolean values to a bool variable

2020-12-21 Thread Michael Ellerman
On Sat, 7 Nov 2020 14:26:22 +0800, xiakaixu1...@gmail.com wrote: > Fix the following coccinelle warnings: > > ./arch/powerpc/kvm/book3s_xics.c:476:3-15: WARNING: Assignment of 0/1 to bool > variable > ./arch/powerpc/kvm/book3s_xics.c:504:3-15: WARNING: Assignment of 0/1 to bool > variable

Re: [PATCH] powerpc/ps3: use dma_mapping_error()

2020-12-21 Thread Michael Ellerman
On Sun, 13 Dec 2020 19:26:22 +0100, Vincent Stehlé wrote: > The DMA address returned by dma_map_single() should be checked with > dma_mapping_error(). Fix the ps3stor_setup() function accordingly. Applied to powerpc/next. [1/1] powerpc/ps3: use dma_mapping_error()

Re: [PATCH] powerpc/configs: Add ppc64le_allnoconfig target

2020-12-21 Thread Michael Ellerman
On Wed, 25 Nov 2020 14:15:51 +1100, Michael Ellerman wrote: > Add a phony target for ppc64le_allnoconfig, which tests some > combinations of CONFIG symbols that aren't covered by any of our > defconfigs. Applied to powerpc/next. [1/1] powerpc/configs: Add ppc64le_allnoconfig target

Re: [PATCH] powerpc: Add config fragment for disabling -Werror

2020-12-21 Thread Michael Ellerman
On Fri, 23 Oct 2020 15:00:02 +1100, Michael Ellerman wrote: > This makes it easy to disable building with -Werror: > > $ make defconfig > $ grep WERROR .config > # CONFIG_PPC_DISABLE_WERROR is not set > CONFIG_PPC_WERROR=y > > [...] Applied to powerpc/next. [1/1] powerpc: Add config

Re: [PATCH v2 1/1] powerpc/kvm: Fix mask size for emulated msgsndp

2020-12-21 Thread Michael Ellerman
On Tue, 8 Dec 2020 18:57:08 -0300, Leonardo Bras wrote: > According to ISAv3.1 and ISAv3.0b, the msgsndp is described to split RB in: > msgtype <- (RB) 32:36 > payload <- (RB) 37:63 > t <- (RB) 57:63 > > The current way of getting 'msgtype', and 't' is missing their MSB: > msgtype: ((arg >>

Re: [PATCH] powerpc/memhotplug: quieting some DLPAR operations

2020-12-21 Thread Michael Ellerman
On Fri, 11 Dec 2020 15:59:54 +0100, Laurent Dufour wrote: > When attempting to remove by index a set of LMB a lot of messages are > displayed on the console, even when everything goes fine: > > pseries-hotplug-mem: Attempting to hot-remove LMB, drc index 802d > Offlined Pages 4096 >

Re: [PATCH] powerpc/mm: Fix hugetlb_free_pmd_range() and hugetlb_free_pud_range()

2020-12-21 Thread Michael Ellerman
On Sat, 12 Dec 2020 13:41:25 + (UTC), Christophe Leroy wrote: > Commit 7bfe54b5f165 ("powerpc/mm: Refactor the floor/ceiling check in > hugetlb range freeing functions") inadvertely removed the mask > applied to start parameter in those two functions, leading to the > following crash on

Re: [PATCH] powerpc: force inlining of csum_partial() to avoid multiple csum_partial() with GCC10

2020-12-21 Thread Michael Ellerman
On Thu, 15 Oct 2020 10:52:20 + (UTC), Christophe Leroy wrote: > ppc-linux-objdump -d vmlinux | grep -e "" -e > "<__csum_partial>" > > With gcc9 I get: > > c0017ef8 <__csum_partial>: > c00182fc: 4b ff fb fd bl c0017ef8 <__csum_partial> > c0018478:

Re: [PATCH] powerpc/powernv: Rate limit opal-elog read failure message

2020-12-21 Thread Michael Ellerman
On Fri, 11 Dec 2020 13:11:41 +1100, Andrew Donnellan wrote: > Sometimes we can't read an error log from OPAL, and we print an error > message accordingly. But the OPAL userspace tools seem to like retrying a > lot, in which case we flood the kernel log with a lot of messages. > > Change pr_err()

Re: [PATCH V3] powerpc/perf: Fix Threshold Event Counter Multiplier width for P10

2020-12-21 Thread Michael Ellerman
On Tue, 15 Dec 2020 03:56:18 -0500, Athira Rajeev wrote: > Threshold Event Counter Multiplier (TECM) is part of Monitor Mode > Control Register A (MMCRA). This field along with Threshold Event > Counter Exponent (TECE) is used to get threshould counter value. > In Power10, this is a 8bit field, so

Re: [PATCH 01/23] kernel: irq: irqdescs: warn on spurious IRQ

2020-12-21 Thread Andy Shevchenko
On Mon, Dec 21, 2020 at 7:44 AM Michael Ellerman wrote: > Andy Shevchenko writes: > > On Fri, Dec 18, 2020 at 4:37 PM Enrico Weigelt, metux IT consult > > wrote: > > > >> + if (printk_ratelimit()) > >> + pr_warn("spurious IRQ: irq=%d hwirq=%d > >>

Re: [PATCH v2] powerpc/perf/hv-24x7: Dont create sysfs event files for dummy events

2020-12-21 Thread kajoljain
On 12/21/20 11:10 AM, Michael Ellerman wrote: > Kajol Jain writes: >> hv_24x7 performance monitoring unit creates list of supported events >> from the event catalog obtained via HCALL. hv_24x7 catalog could also >> contain invalid or dummy events (with names like FREE_* or CPM_FREE_* >> and

Re: [PATCH 23/23] powerpc/pseries/eeh: Make pseries_send_allow_unfreeze() static

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 08:42, Cédric Le Goater a écrit : It fixes these W=1 compile error : ../arch/powerpc/platforms/pseries/eeh_pseries.c:697:5: error: no previous prototype for ‘pseries_send_allow_unfreeze’ [-Werror=missing-prototypes] 697 | int pseries_send_allow_unfreeze(struct pci_dn

Re: [PATCH 17/23] powerpc/watchdog: Declare soft_nmi_interrupt() prototype

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 08:42, Cédric Le Goater a écrit : It fixes this W=1 compile error : ../arch/powerpc/kernel/watchdog.c:250:6: error: no previous prototype for ‘soft_nmi_interrupt’ [-Werror=missing-prototypes] 250 | void soft_nmi_interrupt(struct pt_regs *regs) |

Re: [PATCH 13/23] powerpc/mm: Move hpte_insert_repeating() prototype

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 08:42, Cédric Le Goater a écrit : It fixes this W=1 compile error : ../arch/powerpc/mm/book3s64/hash_utils.c:1867:6: error: no previous prototype for ‘hpte_insert_repeating’ [-Werror=missing-prototypes] 1867 | long hpte_insert_repeating(unsigned long hash, unsigned long

Re: [PATCH 10/23] powerpc/optprobes: Remove unused routine patch_imm32_load_insns()

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 08:42, Cédric Le Goater a écrit : It fixes W=1 this compile error : Please give more details on why it can be removed. Has it been used in the past and its user was removed by a commit ? Has it never been used ? ../arch/powerpc/kernel/optprobes.c:149:6: error: no previous

Re: [PATCH 06/23] powerpc/setup_64: Make some routines static

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 08:42, Cédric Le Goater a écrit : Fixes these W=1 errors : Explain why it can be made static, not just that it does fix a W=1 compile error, because there are several possible ways to fix such a warning. Also explain why you need to add asm/asm-prototypes.h

Re: [PATCH 04/23] powerpc/pseries/ras: Make init_ras_hotplug_IRQ() static

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 08:42, Cédric Le Goater a écrit : It fixes this W=1 compile error: Explain why it can be made static, not just that it does fix a W=1 compile error, because there are several possible ways to fix such a warning. ../arch/powerpc/platforms/pseries/ras.c:125:12: error: no

Re: [PATCH 03/23] powerpc/pseries/eeh: Make pseries_pcibios_bus_add_device() static

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 08:42, Cédric Le Goater a écrit : It fixes this W=1 compile error: Explain why it can be made static, not just that it does fix a W=1 compile error, because there are several possible ways to fix such a warning. ../arch/powerpc/platforms/pseries/eeh_pseries.c:46:6:

Re: [PATCH 02/23] powerpc/pseries/ras: Remove unused variable 'status'

2020-12-21 Thread Christophe Leroy
Le 21/12/2020 à 08:42, Cédric Le Goater a écrit : The last use of 'status' was removed in 2012. Remove the variable to fix this W=1 compile error. ../arch/powerpc/platforms/pseries/ras.c: In function ‘ras_epow_interrupt’: ../arch/powerpc/platforms/pseries/ras.c:318:6: error: variable

[PATCH 20/23] KVM: PPC: Book3S HV: Declare some prototypes

2020-12-21 Thread Cédric Le Goater
This fixes these W=1 compile errors: ../arch/powerpc/kvm/book3s_hv_builtin.c:425:6: error: no previous prototype for ‘kvmppc_read_intr’ [-Werror=missing-prototypes] 425 | long kvmppc_read_intr(void) | ^~~~ ../arch/powerpc/kvm/book3s_hv_builtin.c:652:6: error: no previous

[PATCH 23/23] powerpc/pseries/eeh: Make pseries_send_allow_unfreeze() static

2020-12-21 Thread Cédric Le Goater
It fixes these W=1 compile error : ../arch/powerpc/platforms/pseries/eeh_pseries.c:697:5: error: no previous prototype for ‘pseries_send_allow_unfreeze’ [-Werror=missing-prototypes] 697 | int pseries_send_allow_unfreeze(struct pci_dn *pdn, | ^~~ Cc: Frederic

[PATCH 19/23] KVM: PPC: Book3S HV: Include prototypes

2020-12-21 Thread Cédric Le Goater
It fixes these W=1 compile errors : CC [M] arch/powerpc/kvm/book3s_64_mmu_hv.o ../arch/powerpc/kvm/book3s_64_mmu_hv.c:879:5: error: no previous prototype for ‘kvm_unmap_hva_range_hv’ [-Werror=missing-prototypes] 879 | int kvm_unmap_hva_range_hv(struct kvm *kvm, unsigned long start, unsigned

[PATCH 17/23] powerpc/watchdog: Declare soft_nmi_interrupt() prototype

2020-12-21 Thread Cédric Le Goater
It fixes this W=1 compile error : ../arch/powerpc/kernel/watchdog.c:250:6: error: no previous prototype for ‘soft_nmi_interrupt’ [-Werror=missing-prototypes] 250 | void soft_nmi_interrupt(struct pt_regs *regs) | ^~ Cc: Nicholas Piggin Signed-off-by: Cédric Le

[PATCH 15/23] powerpc/mm/hugetlb: Make pseries_alloc_bootmem_huge_page() static

2020-12-21 Thread Cédric Le Goater
It fixes this W=1 compile error : ../arch/powerpc/mm/hugetlbpage.c:220:12: error: no previous prototype for ‘pseries_alloc_bootmem_huge_page’ [-Werror=missing-prototypes] 220 | int __init pseries_alloc_bootmem_huge_page(struct hstate *hstate) |^~~

[PATCH 16/23] powerpc/mm: Declare arch_report_meminfo() prototype.

2020-12-21 Thread Cédric Le Goater
It fixes this W=1 compile error : ../arch/powerpc/mm/book3s64/pgtable.c:411:6: error: no previous prototype for ‘arch_report_meminfo’ [-Werror=missing-prototypes] 411 | void arch_report_meminfo(struct seq_file *m) | ^~~ Cc: "Aneesh Kumar K.V" Signed-off-by: Cédric

[PATCH 14/23] powerpc/mm: Declare preload_new_slb_context() prototype

2020-12-21 Thread Cédric Le Goater
It fixes this W=1 compile error : ../arch/powerpc/mm/book3s64/slb.c:380:6: error: no previous prototype for ‘preload_new_slb_context’ [-Werror=missing-prototypes] 380 | void preload_new_slb_context(unsigned long start, unsigned long sp) | ^~~ Cc: "Aneesh Kumar

[PATCH 10/23] powerpc/optprobes: Remove unused routine patch_imm32_load_insns()

2020-12-21 Thread Cédric Le Goater
It fixes W=1 this compile error : ../arch/powerpc/kernel/optprobes.c:149:6: error: no previous prototype for ‘patch_imm32_load_insns’ [-Werror=missing-prototypes] 149 | void patch_imm32_load_insns(unsigned int val, kprobe_opcode_t *addr) Cc: Jordan Niethe Signed-off-by: Cédric Le Goater ---

[PATCH 21/23] powerpc/pseries: Make IOV setup routines static

2020-12-21 Thread Cédric Le Goater
It fixes these W=1 compile errors : ../arch/powerpc/platforms/pseries/setup.c:610:17: error: no previous prototype for ‘pseries_get_iov_fw_value’ [-Werror=missing-prototypes] 610 | resource_size_t pseries_get_iov_fw_value(struct pci_dev *dev, int resno, |

[PATCH 11/23] powerpc/optprobes: Make patch_imm64_load_insns() static

2020-12-21 Thread Cédric Le Goater
It fixes W=1 this compile error : ../arch/powerpc/kernel/optprobes.c:149:6: error: no previous prototype for ‘patch_imm64_load_insns’ [-Werror=missing-prototypes] 149 | void patch_imm64_load_insns(unsigned int val, kprobe_opcode_t *addr) Cc: Jordan Niethe Signed-off-by: Cédric Le Goater ---

[PATCH 07/23] powerpc/mce: Include prototypes

2020-12-21 Thread Cédric Le Goater
It fixes these W=1 compile errors : ../arch/powerpc/kernel/mce.c:591:14: error: no previous prototype for ‘machine_check_early’ [-Werror=missing-prototypes] 591 | long notrace machine_check_early(struct pt_regs *regs) | ^~~ ../arch/powerpc/kernel/mce.c:725:6:

[PATCH 22/23] powerpc/pcidn: Make IOV setup routines static

2020-12-21 Thread Cédric Le Goater
It fixes these W=1 compile errors : ../arch/powerpc/platforms/pseries/pci.c:58:5: error: no previous prototype for ‘pseries_send_map_pe’ [-Werror=missing-prototypes] 58 | int pseries_send_map_pe(struct pci_dev *pdev, | ^~~

[PATCH 04/23] powerpc/pseries/ras: Make init_ras_hotplug_IRQ() static

2020-12-21 Thread Cédric Le Goater
It fixes this W=1 compile error: ../arch/powerpc/platforms/pseries/ras.c:125:12: error: no previous prototype for ‘init_ras_hotplug_IRQ’ [-Werror=missing-prototypes] 125 | int __init init_ras_hotplug_IRQ(void) |^~~~ Fixes: c9dccf1d074a ("powerpc/pseries:

[PATCH 09/23] powerpc/smp: Make debugger_ipi_callback() static

2020-12-21 Thread Cédric Le Goater
It fixes this W=1 compile error : ../arch/powerpc/kernel/smp.c:579:6: error: no previous prototype for ‘debugger_ipi_callback’ [-Werror=missing-prototypes] 579 | void debugger_ipi_callback(struct pt_regs *regs) | ^ Signed-off-by: Cédric Le Goater ---