Re: [PATCH RFC v3 1/2] mm: Add personality flag to limit address to 47 bits

2024-09-11 Thread Michael Ellerman
"Arnd Bergmann" writes: > On Mon, Sep 9, 2024, at 23:22, Charlie Jenkins wrote: >> On Fri, Sep 06, 2024 at 10:52:34AM +0100, Lorenzo Stoakes wrote: >>> On Fri, Sep 06, 2024 at 09:14:08AM GMT, Arnd Bergmann wrote: >>> The intent is to optionally be able to run a process that keeps higher bits >>> f

Re: [PATCH RFC v3 1/2] mm: Add personality flag to limit address to 47 bits

2024-09-11 Thread Michael Ellerman
Geert Uytterhoeven writes: > Hi Christophe, > > On Tue, Sep 10, 2024 at 11:21 AM Christophe Leroy > wrote: >> >>> diff --git a/include/uapi/linux/personality.h >> >>> b/include/uapi/linux/personality.h >> >>> index 49796b7756af..cd3b8c154d9b 100644 >> >>> --- a/include/uapi/linux/personality.h >

Re: [PATCH RFC v3 1/2] mm: Add personality flag to limit address to 47 bits

2024-09-11 Thread Michael Ellerman
Charlie Jenkins writes: > On Fri, Sep 06, 2024 at 04:59:40PM +1000, Michael Ellerman wrote: >> Charlie Jenkins writes: >> > Create a personality flag ADDR_LIMIT_47BIT to support applications >> > that wish to transition from running in environments that support

Re: [PATCH v2] powerpc/pseries/eeh: Fix pseries_eeh_err_inject

2024-09-10 Thread Michael Ellerman
Narayana Murty N writes: > On 05/09/24 6:33 PM, Michael Ellerman wrote: >> Narayana Murty N writes: >>> VFIO_EEH_PE_INJECT_ERR ioctl is currently failing on pseries >>> due to missing implementation of err_inject eeh_ops for pseries. >>> This patch implemen

Re: [PATCH] powerpc/ftrace: restore r2 to caller's stack on livepatch sibling call

2024-09-10 Thread Michael Ellerman
"Ryan B. Sullivan" writes: > Hello all, > > Just wanted to ping and see if there was any further feedback or > questions regarding the patch? Hi Ryan, I'd really like a selftest that triggers the sibling call behaviour. As I said upthread I tried writing one but failed. Which you later explaine

Re: [PATCH -next,v2] MIPS: Remove the obsoleted code for include/linux/mv643xx.h

2024-09-09 Thread Michael Ellerman
Gaosheng Cui writes: > Most of the drivers which used this header have been deleted, most > of these code is obsoleted, move the only defines that are actually > used into arch/powerpc/platforms/chrp/pegasos_eth.c and delete the > file completely. > > Signed-off-by: Gaosheng Cui > --- > v2: Delet

Re: [PATCH v4 RESEND] powerpc: Replace kretprobe code with rethook on powerpc

2024-09-08 Thread Michael Ellerman
Masami Hiramatsu (Google) writes: > On Fri, 06 Sep 2024 21:52:52 +1000 > Michael Ellerman wrote: > >> On Fri, 30 Aug 2024 07:31:31 -0400, Abhishek Dubey wrote: >> > This is an adaptation of commit f3a112c0c40d ("x86,rethook,kprobes: >> > Replace kret

Re: [PATCH] crash: Default to CRASH_DUMP=n when support for it is unlikely

2024-09-08 Thread Michael Ellerman
Dave Vasilevsky writes: > I received a notification from Patchwork that my patch is now in the > state "Handled Elsewhere".[0] Does that mean someone merged it > somewhere? Or that I should be using a different mailing list? Or > something else? > > I'd appreciate some guidance. It was sent/Cc'ed

Re: [PATCH] powerpc/xive: Use cpumask_intersects()

2024-09-08 Thread Michael Ellerman
Costa Shulyupin writes: > Replace `cpumask_any_and(a, b) >= nr_cpu_ids` > with the more readable `!cpumask_intersects(a, b)`. I agree it's more readable. It would be nice if the change log told me that both functions have similar performance behaviour. I'm not saying this is a super hot path, bu

Re: [PATCH 1/2] powerpc/vdso: Fix VDSO data access when running in a non-root time namespace

2024-09-08 Thread Michael Ellerman
"Jason A. Donenfeld" writes: > On Fri, Sep 06, 2024 at 03:43:17PM +0200, Jason A. Donenfeld wrote: >> On Fri, Sep 06, 2024 at 10:23:08PM +1000, Michael Ellerman wrote: >> > Christophe Leroy writes: >> > > When running in a non-root time namespace, the glo

Re: [GIT PULL] Please pull powerpc/linux.git powerpc-6.11-3 tag

2024-09-06 Thread Michael Ellerman
Linus Torvalds writes: > On Fri, 6 Sept 2024 at 05:08, Michael Ellerman wrote: >> >> Please pull some more powerpc fixes for 6.11: >> >> https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git >> tags/powerpc-6.11-3 > > Hmm. New pgp key? Ple

Re: [PATCH 1/2] powerpc/vdso: Fix VDSO data access when running in a non-root time namespace

2024-09-06 Thread Michael Ellerman
Christophe Leroy writes: > When running in a non-root time namespace, the global VDSO data page > is replaced by a dedicated namespace data page and the global data > page is mapped next to it. Detailed explanations can be found at > commit 660fd04f9317 ("lib/vdso: Prepare for time namespace suppo

[GIT PULL] Please pull powerpc/linux.git powerpc-6.11-3 tag

2024-09-06 Thread Michael Ellerman
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 Hi Linus, Please pull some more powerpc fixes for 6.11: The following changes since commit 227bbaabe64b6f9cd98aa051454c1d4a194a8c6a: powerpc/topology: Check if a core is online (2024-08-13 10:32:17 +1000) are available in the git repository at:

Re: [PATCH] KVM: PPC: remove unused varible

2024-09-06 Thread Michael Ellerman
On Fri, 16 Aug 2024 17:33:12 +0800, al...@kernel.org wrote: > During build testing, we found a error: > /arch/powerpc/kvm/book3s_hv.c:4052:17: error: variable 'loops' set but not > used [-Werror,-Wunused-but-set-variable] > unsigned long loops = 0; > 1 error generated. > > Remove

Re: [PATCH] powerpc/configs/64s: Enable DEFERRED_STRUCT_PAGE_INIT

2024-09-06 Thread Michael Ellerman
On Tue, 20 Aug 2024 16:57:05 +1000, Michael Ellerman wrote: > It can speed up initialisation of page structs at boot on large > machines. > > Applied to powerpc/next. [1/1] powerpc/configs/64s: Enable DEFERRED_STRUCT_PAGE_INIT https://git.kernel.o

Re: [PATCH] powerpc/64s/mm: Move __real_pte stubs into hash-4k.h

2024-09-06 Thread Michael Ellerman
On Wed, 21 Aug 2024 18:07:29 +1000, Michael Ellerman wrote: > The stub versions of __real_pte() etc are only used with HPT & 4K pages, > so move them into the hash-4k.h header. > > Applied to powerpc/next. [1/1] powerpc/64s/mm: Move __real_pte stubs into hash-4k.h https:

Re: [PATCH 0/2] Use helper function for_each_child_of_node()

2024-09-06 Thread Michael Ellerman
On Thu, 22 Aug 2024 16:54:28 +0800, Zhang Zekun wrote: > Use for_each_child_of_node() to iterate through the device_node, this > can make code more simple. > > Zhang Zekun (2): > powerpc/powermac/pfunc_base: Use helper function > for_each_child_of_node() > powerpc/pseries/dlpar: Use helper

Re: [PATCH] powerpc: Stop using no_llseek

2024-09-06 Thread Michael Ellerman
On Tue, 03 Sep 2024 21:19:51 +1000, Michael Ellerman wrote: > Since commit 868941b14441 ("fs: remove no_llseek"), no_llseek() is > simply defined to be NULL, and a NULL llseek means seeking is > unsupported. > > So for statically defined file_operations, such as all th

Re: [PATCH] powerpc/64s: Remove the "fast endian switch" syscall

2024-09-06 Thread Michael Ellerman
On Fri, 23 Aug 2024 17:08:30 +1000, Michael Ellerman wrote: > The non-standard "fast endian switch" syscall was added in 2008[1], > but was never widely used. It was disabled by default in 2017[2], and > there's no evidence it's ever been used since. > > Remov

Re: [PATCH] powerpc/64s: Make mmu_hash_ops __ro_after_init

2024-09-06 Thread Michael Ellerman
On Wed, 21 Aug 2024 18:07:45 +1000, Michael Ellerman wrote: > The mmu_hash_ops are only assigned to during boot, so mark them > __ro_after_init to prevent any further modification. > > Applied to powerpc/next. [1/1] powerpc/64s: Make mmu_hash_ops __ro_after_init https://gi

Re: [PATCH] macintosh/via-pmu: register_pmu_pm_ops() can be __init

2024-09-06 Thread Michael Ellerman
On Wed, 21 Aug 2024 18:21:01 +1000, Michael Ellerman wrote: > register_pmu_pm_ops() is only called at init time, via > device_initcall(), so can be marked __init. The driver can't be built as > a module. > > Applied to powerpc/next. [1/1] macintosh/via-pmu: register_pmu_pm

Re: [PATCH 1/2] powerpc/mm/64s: Move THP reqs into a separate symbol

2024-09-06 Thread Michael Ellerman
On Fri, 23 Aug 2024 13:29:10 +1000, Michael Ellerman wrote: > Move the Kconfig symbols related to transparent hugepages (THP) under a > separate config symbol, separate from CONFIG_PPC_BOOK3S_64. > > The new symbol is automatically enabled if CONFIG_PPC_BOOK3S_64 is > enabled,

Re: [PATCH v3] powerpc/xmon: Fix tmpstr length check in scanhex

2024-09-06 Thread Michael Ellerman
On Mon, 26 Aug 2024 12:12:17 +0530, Madhavan Srinivasan wrote: > If a function name is greater than 63 char long, xmon command > may not find them. For example, here is a test that > executed an illegal instruction in a kernel function and one of > call stack function has name >63 char long, > > c

Re: [PATCH -next 1/3] powerpc: Constify struct kobj_type

2024-09-06 Thread Michael Ellerman
On Mon, 26 Aug 2024 23:09:55 +0800, Huang Xiaojia wrote: > 'struct kobj_type' is not modified. It is only used in > kobject_init_and_add()/kobject_init() which takes > a 'const struct kobj_type *ktype' parameter. > > Constifying this structure moves some data to a read-only section, > so increase

Re: [PATCH v3 1/3] powerpc/pseries: Use correct data types from pseries_hp_errorlog struct

2024-09-06 Thread Michael Ellerman
On Wed, 21 Aug 2024 19:50:26 -0700, Haren Myneni wrote: > _be32 type is defined for some elements in pseries_hp_errorlog > struct but also used them u32 after be32_to_cpu() conversion. > > Example: In handle_dlpar_errorlog() > hp_elog->_drc_u.drc_index = be32_to_cpu(hp_elog->_drc_u.drc_index); >

Re: [PATCH -next] powerpc/powernv/pci: Remove obsoleted declaration for pnv_pci_init_ioda_hub

2024-09-06 Thread Michael Ellerman
On Thu, 22 Aug 2024 21:00:43 +0800, Gaosheng Cui wrote: > The pnv_pci_init_ioda_hub() have been removed since > commit 5ac129cdb50b ("powerpc/powernv/pci: Remove ioda1 support"), > and now it is useless, so remove it. > > Applied to powerpc/next. [1/1] powerpc/powernv/pci: Remove obsoleted decl

Re: [PATCH -next 0/4] Remove obsoleted declaration for powerpc

2024-09-06 Thread Michael Ellerman
On Thu, 22 Aug 2024 21:06:05 +0800, Gaosheng Cui wrote: > Remove obsoleted declaration for powerpc, thanks! > > Gaosheng Cui (4): > powerpc: Remove obsoleted declaration for _get_SP > powerpc: Remove obsoleted declaration for maple_calibrate_decr > powerpc: Remove obsoleted declaration for p

Re: [PATCH 00/14] Reduce alignment constraint on STRICT_KERNEL_RWX and speed-up TLB misses on 8xx and 603

2024-09-06 Thread Michael Ellerman
On Tue, 20 Aug 2024 19:23:44 +0200, Christophe Leroy wrote: > This series does mainly two things: > - Remove the 8M alignment constraint on STRICT_KERNEL_RWX on 8xx to > avoid wasting memory. > - Speed-up TLB misses by duplicating kernel PGD entries into each > task's PGDIRs to avoid the address co

Re: [PATCH] powerpc/vdso: Inconditionally use CFUNC macro

2024-09-06 Thread Michael Ellerman
On Thu, 22 Aug 2024 10:00:29 +0200, Christophe Leroy wrote: > During merge of commit 4e991e3c16a3 ("powerpc: add CFUNC assembly > label annotation") a fallback version of CFUNC macro was added at > the last minute, so it can be used inconditionally. > > Applied to powerpc/next. [1/1] powerpc/vd

Re: [PATCH v2] powerpc/32: Implement validation of emergency stack

2024-09-06 Thread Michael Ellerman
On Tue, 20 Aug 2024 14:26:54 +0200, Christophe Leroy wrote: > VMAP stack added an emergency stack on powerpc/32 for when there is > a stack overflow, but failed to add stack validation for that > emergency stack. That validation is required for show stack. > > Implement it. > > > [...] Applied

Re: [PATCH v4 RESEND] powerpc: Replace kretprobe code with rethook on powerpc

2024-09-06 Thread Michael Ellerman
On Fri, 30 Aug 2024 07:31:31 -0400, Abhishek Dubey wrote: > This is an adaptation of commit f3a112c0c40d ("x86,rethook,kprobes: > Replace kretprobe with rethook on x86") to powerpc. > > Rethook follows the existing kretprobe implementation, but separates > it from kprobes so that it can be used by

Re: [PATCH v2] powerpc/qspinlock: Fix deadlock in MCS queue

2024-09-06 Thread Michael Ellerman
On Thu, 29 Aug 2024 07:58:27 +0530, Nysal Jan K.A. wrote: > If an interrupt occurs in queued_spin_lock_slowpath() after we increment > qnodesp->count and before node->lock is initialized, another CPU might > see stale lock values in get_tail_qnode(). If the stale lock value happens > to match the l

Re: [oss-security] Linux kernel: memory leak in arch/powerpc/platforms/powernv/opal-irqchip.c: opal_event_init()

2024-09-06 Thread Michael Ellerman
Solar Designer writes: > Hi, > > This bug report is misaddressed. Per upstream's preference and common > sense (given how many issue reports there are against the Linux kernel), > most Linux kernel (maybe-)issues should first be reported to Linux > kernel maintainers/lists or (if you're reasonabl

Re: [PATCH RFC v3 1/2] mm: Add personality flag to limit address to 47 bits

2024-09-05 Thread Michael Ellerman
Charlie Jenkins writes: > Create a personality flag ADDR_LIMIT_47BIT to support applications > that wish to transition from running in environments that support at > most 47-bit VAs to environments that support larger VAs. This > personality can be set to cause all allocations to be below the 47-b

Re: [PATCH v2] powerpc/pseries/eeh: Fix pseries_eeh_err_inject

2024-09-05 Thread Michael Ellerman
Narayana Murty N writes: > VFIO_EEH_PE_INJECT_ERR ioctl is currently failing on pseries > due to missing implementation of err_inject eeh_ops for pseries. > This patch implements pseries_eeh_err_inject in eeh_ops/pseries > eeh_ops. Implements support for injecting MMIO load/store error > for testi

Re: [PATCH 13/15] powerpc/rtas: Use fsleep() to minimize additional sleep duration

2024-09-05 Thread Michael Ellerman
*/ > - if (ms <= 20) > - usleep_range(ms * 100, ms * 1000); > - else > - msleep(ms); > + fsleep(ms * 1000); > break; > case RTAS_BUSY: > ret = true; Acked-by: Michael Ellerman (powerpc) cheers

Re: [PATCH v5 0/5] Wire up getrandom() vDSO implementation on powerpc

2024-09-05 Thread Michael Ellerman
"Jason A. Donenfeld" writes: > Hi Christophe, Michael, > > On Mon, Sep 02, 2024 at 09:17:17PM +0200, Christophe Leroy wrote: >> This series wires up getrandom() vDSO implementation on powerpc. >> >> Tested on PPC32 on real hardware. >> Tested on PPC64 (

Re: [PATCH 2/3] mm: Pass vm_flags to generic_get_unmapped_area()

2024-09-03 Thread Michael Ellerman
mentation in the radix_enabled() case. > > Signed-off-by: Mark Brown > --- > arch/powerpc/mm/book3s64/slice.c | 4 ++-- > include/linux/sched/mm.h | 4 ++-- > mm/mmap.c| 10 ++ > 3 files changed, 10 insertions(+), 8 deletions(-) Ack

Re: clearly mark DMA_OPS support as an architecture feature v2

2024-09-03 Thread Michael S. Tsirkin
On Tue, Sep 03, 2024 at 09:27:44AM +0200, Christoph Hellwig wrote: > I've pulled this into the dma-mapping for-next tree, although I'd > love to see one of the vdpa maintainers look over patch 1. I'm > pretty sure it's correct, but a confirmation would be good. Missed patch 1, I was wondering why

Re: [PATCH 1/2] vdpa_sim: don't select DMA_OPS

2024-09-03 Thread Michael S. Tsirkin
ff-by: Christoph Hellwig Acked-by: Michael S. Tsirkin > --- > drivers/vdpa/Kconfig | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/vdpa/Kconfig b/drivers/vdpa/Kconfig > index 5265d09fc1c409..b08de3b7706109 100644 > --- a/drivers/vdpa/Kconfig

[PATCH] powerpc: Stop using no_llseek

2024-09-03 Thread Michael Ellerman
Since commit 868941b14441 ("fs: remove no_llseek"), no_llseek() is simply defined to be NULL, and a NULL llseek means seeking is unsupported. So for statically defined file_operations, such as all these, there's no need or benefit to set llseek = no_llseek. Signed-off-by: M

Re: [PATCH] tty: hvc: convert comma to semicolon

2024-09-02 Thread Michael Ellerman
Chen Ni writes: > Replace a comma between expression statements by a semicolon. > > Signed-off-by: Chen Ni > --- > drivers/tty/hvc/hvsi_lib.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Acked-by: Michael Ellerman (powerpc) cheers > diff --git a/drivers

Re: [PATCH v4 RESEND] powerpc: Replace kretprobe code with rethook on powerpc

2024-09-02 Thread Michael Ellerman
Abhishek Dubey writes: > This is an adaptation of commit f3a112c0c40d ("x86,rethook,kprobes: > Replace kretprobe with rethook on x86") to powerpc. > > Rethook follows the existing kretprobe implementation, but separates > it from kprobes so that it can be used by fprobe (ftrace-based > function en

Re: [PATCH v3 1/5] mm: Define VM_DROPPABLE for powerpc/32

2024-09-01 Thread Michael Ellerman
Christophe Leroy writes: > Commit 9651fcedf7b9 ("mm: add MAP_DROPPABLE for designating always > lazily freeable mappings") only adds VM_DROPPABLE for 64 bits > architectures. > > In order to also use the getrandom vDSO implementation on powerpc/32, > use VM_ARCH_1 for VM_DROPPABLE on powerpc/32. T

Re: [PATCH] powerpc: Use printk instead of WARN in change_memory_attr

2024-08-30 Thread Michael Ellerman
Christophe Leroy writes: > Le 27/08/2024 à 11:12, Ritesh Harjani (IBM) a écrit : >> [Vous ne recevez pas souvent de courriers de ritesh.l...@gmail.com. >> Découvrez pourquoi ceci est important à >> https://aka.ms/LearnAboutSenderIdentification ] >> >> Use pr_warn_once instead of WARN_ON_ONCE as

Re: [PATCH -next 1/4] powerpc: Remove obsoleted declaration for _get_SP

2024-08-30 Thread Michael Ellerman
cuigaosheng writes: > On 2024/8/22 22:16, LEROY Christophe wrote: >> >> Le 22/08/2024 à 15:06, Gaosheng Cui a écrit : >>> [Vous ne recevez pas souvent de courriers de cuigaoshe...@huawei.com. >>> Découvrez pourquoi ceci est important à >>> https://aka.ms/LearnAboutSenderIdentification ] >>> >>>

Re: [PATCH v2 05/17] vdso: Avoid call to memset() by getrandom

2024-08-30 Thread Michael Ellerman
Segher Boessenkool writes: > On Thu, Aug 29, 2024 at 07:36:38PM +0200, Christophe Leroy wrote: >> >> >> Le 28/08/2024 à 19:25, Segher Boessenkool a écrit : >> > >> >>Not sure about static binaries, though: do those even use the VDSO? >> > >> >With "static binary" people usually mean "a binary no

Re: [PATCH RFC v2 1/4] mm: Add MAP_BELOW_HINT

2024-08-29 Thread Michael Ellerman
Charlie Jenkins writes: > Some applications rely on placing data in free bits addresses allocated > by mmap. Various architectures (eg. x86, arm64, powerpc) restrict the > address returned by mmap to be less than the 48-bit address space, > unless the hint address uses more than 47 bits (the 48th

Re: [PATCH v3 3/3] powerpc/pseries/dlpar: Add device tree nodes for DLPAR IO add

2024-08-28 Thread Michael Ellerman
Haren Myneni writes: > On Wed, 2024-08-28 at 18:12 +1000, Michael Ellerman wrote: >> Hi Haren, >> >> One query below about the of_node refcounting. >> >> Haren Myneni writes: >> > In the powerpc-pseries specific implementation, the IO hotplug >>

Re: [PATCH v3 3/3] powerpc/pseries/dlpar: Add device tree nodes for DLPAR IO add

2024-08-28 Thread Michael Ellerman
Hi Haren, One query below about the of_node refcounting. Haren Myneni writes: > In the powerpc-pseries specific implementation, the IO hotplug > event is handled in the user space (drmgr tool). For the DLPAR > IO ADD, the corresponding device tree nodes and properties will > be added to the devi

Re: [PATCH] powerpc/qspinlock: Fix deadlock in MCS queue

2024-08-27 Thread Michael Ellerman
"Nysal Jan K.A." writes: > If an interrupt occurs in queued_spin_lock_slowpath() after we increment > qnodesp->count and before node->lock is initialized, another CPU might > see stale lock values in get_tail_qnode(). If the stale lock value happens > to match the lock on that CPU, then we write t

Re: [PATCH v2] powerpc/mm: Fix return type of pgd_val()

2024-08-27 Thread Michael Ellerman
On Thu, 22 Aug 2024 09:58:42 +0200, Christophe Leroy wrote: > Commit 6b0e82791bd0 ("powerpc/e500: switch to 64 bits PGD on 85xx > (32 bits)") switched PGD entries to 64 bits, but pgd_val() returns > an unsigned long which is 32 bits on PPC32. This is not a problem > for regular PMD entries because

Re: [PATCH] powerpc/vdso: Don't discard rela sections

2024-08-27 Thread Michael Ellerman
On Tue, 20 Aug 2024 13:28:07 +0200, Christophe Leroy wrote: > After building the VDSO, there is a verification that it contains > no dynamic relocation, see commit aff69273af61 ("vdso: Improve > cmd_vdso_check to check all dynamic relocations"). > > This verification uses readelf -r and doesn't wo

Re: [PATCH] powerpc/64e: Define mmu_pte_psize static

2024-08-27 Thread Michael Ellerman
On Tue, 20 Aug 2024 14:42:38 +0200, Christophe Leroy wrote: > mmu_pte_psize is only used in the tlb_64e.c, define it static. > > Applied to powerpc/fixes. [1/1] powerpc/64e: Define mmu_pte_psize static https://git.kernel.org/powerpc/c/d92b5cc29c792f1d3f0aaa3b29dddfe816c03e88 cheers

Re: [PATCH 1/2] MAINTAINERS: Mark powerpc Cell as orphaned

2024-08-27 Thread Michael Ellerman
On Fri, 26 Jul 2024 22:33:21 +1000, Michael Ellerman wrote: > Arnd is no longer actively maintaining Cell, mark it as orphan. > > Also drop the dead developerworks link. > > Applied to powerpc/next. [1/2] MAINTAINERS: Mark powerpc Cell as orphaned https://git.kerne

Re: [PATCH v4 0/5] Add generic data patching functions

2024-08-27 Thread Michael Ellerman
On Wed, 15 May 2024 12:44:40 +1000, Benjamin Gray wrote: > Currently patch_instruction() bases the write length on the value being > written. If the value looks like a prefixed instruction it writes 8 bytes, > otherwise it writes 4 bytes. This makes it potentially buggy to use for > writing arbitra

Re: [PATCH] powerpc: Remove LHZX_BE macro

2024-08-27 Thread Michael Ellerman
On Wed, 21 Aug 2024 08:47:51 +0200, Christophe Leroy wrote: > LHZX_BE has been unused since commit dbf44daf7c88 ("bpf, ppc64: remove > ld_abs/ld_ind") > > Remove it. > > Applied to powerpc/next. [1/1] powerpc: Remove LHZX_BE macro https://git.kernel.org/powerpc/c/a540ad3e386f8f84bc6d600b

[PATCH] MAINTAINERS: powerpc: Add Maddy

2024-08-26 Thread Michael Ellerman
Maddy will be helping out with upstream maintenance, add him as a reviewer. Signed-off-by: Michael Ellerman --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index 878dcd23b331..0ee724dcc05a 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -12912,6

Re: linux-next: boot warning after merge of the vfs-brauner tree

2024-08-26 Thread Michael Ellerman
"Pankaj Raghav (Samsung)" writes: > On Mon, Aug 26, 2024 at 05:59:31PM +1000, Stephen Rothwell wrote: >> Hi all, >> >> After merging the vfs-brauner tree, today's linux-next boot test (powerpc >> pseries_le_defconfig) produced this warning: > > iomap dio calls set_memory_ro() on the page that is

Re: [PATCH v2] ata: pata_macio: Use WARN instead of BUG

2024-08-26 Thread Michael Ellerman
Sergei Shtylyov writes: > On 8/20/24 6:04 AM, Michael Ellerman wrote: > >> The overflow/underflow conditions in pata_macio_qc_prep() should never >> happen. But if they do there's no need to kill the system entirely, a >> WARN and failing the IO request should be s

Re: [PATCH] crash: Default to CRASH_DUMP=n when support for it is unlikely

2024-08-25 Thread Michael Ellerman
Geert Uytterhoeven writes: > Hi Dave, > > On Fri, Aug 23, 2024 at 2:54 PM Dave Vasilevsky wrote: >> Fixes boot failures on 6.9 on PPC_BOOK3S_32 machines using >> Open Firmware. On these machines, the kernel refuses to boot >> from non-zero PHYSICAL_START, which occurs when CRASH_DUMP is on. >> >>

[PATCH 1/3] powerpc/64: Remove maple platform

2024-08-23 Thread Michael Ellerman
nux-fullhistory.git/commit/?id=f0d068d65c5e555ffcfbc189de32598f6f00770c Signed-off-by: Michael Ellerman --- Documentation/arch/powerpc/booting.rst | 4 +- arch/powerpc/Kconfig.debug | 6 - arch/powerpc/boot/.gitignore | 1 - arch/powerpc/boot/Makefile | 3 +- arch/powerpc/b

[PATCH 3/3] EDAC/powerpc: Remove "maple" drivers

2024-08-23 Thread Michael Ellerman
These two drivers are only buildable for the powerpc "maple" platform, which has now been removed. Remove the drivers. Signed-off-by: Michael Ellerman --- drivers/edac/Kconfig| 18 -- drivers/edac/Makefile | 2 - drivers/edac/amd8111_ed

[PATCH 2/3] cpufreq: maple: Remove maple driver

2024-08-23 Thread Michael Ellerman
es to support those machines. Signed-off-by: Michael Ellerman --- drivers/cpufreq/Kconfig.powerpc | 7 - drivers/cpufreq/Makefile| 1 - drivers/cpufreq/maple-cpufreq.c | 241 3 files changed, 249 deletions(-) delete mode 100644 drivers/cpufreq/maple-cp

[PATCH] powerpc/64s: Remove the "fast endian switch" syscall

2024-08-23 Thread Michael Ellerman
264b ("[POWERPC] Add fast little-endian switch system call") [2]: 529d235a0e19 ("powerpc: Add a proper syscall for switching endianness") [3]: 727f13616c45 ("powerpc: Disable the fast-endian switch syscall by default") Signed-off-by: Michael Ellerman --- arch/powerpc

[PATCH 1/2] powerpc/mm/64s: Move THP reqs into a separate symbol

2024-08-22 Thread Michael Ellerman
. Signed-off-by: Michael Ellerman --- arch/powerpc/platforms/Kconfig.cputype | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/platforms/Kconfig.cputype b/arch/powerpc/platforms/Kconfig.cputype index 4b0d7d4f88f6..9536e591c72a 100644 --- a/arch/powerpc

[PATCH 2/2] powerpc/mm/64s: Restrict THP to Radix or HPT w/64K pages

2024-08-22 Thread Michael Ellerman
never run. See the stubs in arch/powerpc/include/asm/book3s/64/hash-4k.h. Signed-off-by: Michael Ellerman --- arch/powerpc/platforms/Kconfig.cputype | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/powerpc/platforms/Kconfig.cputype b/arch/powerpc/platforms/Kconfig.cputype index 9536e59

Re: [PATCH] powerpc/pseries: Use correct data types from pseries_hp_errorlog struct

2024-08-21 Thread Michael Ellerman
Haren Myneni writes: > _be32 type is defined for some elements in pseries_hp_errorlog > struct but also used them u32 after be32_to_cpu() conversion. > > Example: In handle_dlpar_errorlog() > hp_elog->_drc_u.drc_index = be32_to_cpu(hp_elog->_drc_u.drc_index); > > And later assigned to u32 type > d

[PATCH] macintosh/via-pmu: register_pmu_pm_ops() can be __init

2024-08-21 Thread Michael Ellerman
register_pmu_pm_ops() is only called at init time, via device_initcall(), so can be marked __init. The driver can't be built as a module. Signed-off-by: Michael Ellerman --- drivers/macintosh/via-pmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/macintos

[PATCH] powerpc/64s: Make mmu_hash_ops __ro_after_init

2024-08-21 Thread Michael Ellerman
The mmu_hash_ops are only assigned to during boot, so mark them __ro_after_init to prevent any further modification. Signed-off-by: Michael Ellerman --- arch/powerpc/mm/book3s64/hash_utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/mm/book3s64

[PATCH] powerpc/64s/mm: Move __real_pte stubs into hash-4k.h

2024-08-21 Thread Michael Ellerman
The stub versions of __real_pte() etc are only used with HPT & 4K pages, so move them into the hash-4k.h header. Signed-off-by: Michael Ellerman --- arch/powerpc/include/asm/book3s/64/hash-4k.h | 20 +++ arch/powerpc/include/asm/book3s/64/pgtable.h | 26 2 f

[PATCH] powerpc/configs/64s: Enable DEFERRED_STRUCT_PAGE_INIT

2024-08-19 Thread Michael Ellerman
It can speed up initialisation of page structs at boot on large machines. Signed-off-by: Michael Ellerman --- arch/powerpc/configs/ppc64_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/powerpc/configs/ppc64_defconfig b/arch/powerpc/configs/ppc64_defconfig index 544a65fda77b

Re: [PATCH v2 1/4] mm: Add optional close() to struct vm_special_mapping

2024-08-19 Thread Michael Ellerman
Linus Torvalds writes: > On Mon, 19 Aug 2024 at 13:15, Linus Torvalds > wrote: >> >> Ok, I did a quick hack-job to remove that disgusting >> install_special_mapping() legacy case. >> >> With this [..] > > I forgot to actually attach that "this". Here it is. For real, this time. > >

[PATCH v2] ata: pata_macio: Use WARN instead of BUG

2024-08-19 Thread Michael Ellerman
The overflow/underflow conditions in pata_macio_qc_prep() should never happen. But if they do there's no need to kill the system entirely, a WARN and failing the IO request should be sufficient and might allow the system to keep running. Signed-off-by: Michael Ellerman --- driver

[PATCH v2] ata: pata_macio: Fix DMA table overflow

2024-08-19 Thread Michael Ellerman
nel.org/all/3b6441b8-06e6-45da-9e55-f92f2c869...@ufal.mff.cuni.cz/ Tested-by: Kolbjørn Barmen Signed-off-by: Michael Ellerman --- drivers/ata/pata_macio.c | 23 +++ 1 file changed, 15 insertions(+), 8 deletions(-) v2: Namespace the defines as requested by Damien. Tab align t

Re: [PATCH v3 14/16] modules: Support extended MODVERSIONS info

2024-08-19 Thread Michael Ellerman
Matthew Maurer writes: > On Fri, Aug 16, 2024 at 4:04 PM Michael Ellerman wrote: >> Matthew Maurer writes: >> > Adds a new format for MODVERSIONS which stores each field in a separate >> > ELF section. This initially adds support for variable length names, but >

Re: [RFC PATCH] ata: pata_macio: Use WARN instead of BUG

2024-08-19 Thread Michael Ellerman
Damien Le Moal writes: > On 8/19/24 19:19, Michael Ellerman wrote: >> The overflow/underflow conditions in pata_macio_qc_prep() should never >> happen. But if they do there's no need to kill the system entirely, a >> WARN and failing the IO request should be suff

Re: [PATCH] ata: pata_macio: Fix DMA table overflow

2024-08-19 Thread Michael Ellerman
Damien Le Moal writes: > On 8/19/24 19:17, Michael Ellerman wrote: >> Kolbjørn and Jonáš reported that their 32-bit PowerMacs were crashing >> in pata-macio since commit 09fe2bfa6b83 ("ata: pata_macio: Fix >> max_segment_size with PAGE_SIZE == 64K"). >> &

[PATCH] powerpc/pseries: Fix dtl_access_lock to be a rw_semaphore

2024-08-19 Thread Michael Ellerman
258 Fixes: 06220d78f24a ("powerpc/pseries: Introduce rwlock to gatekeep DTLB usage") Signed-off-by: Michael Ellerman --- arch/powerpc/include/asm/dtl.h| 3 ++- arch/powerpc/platforms/pseries/dtl.c | 8 arch/powerpc/platforms/pseries/lpar.c | 8 3 files changed,

[RFC PATCH] ata: pata_macio: Use WARN instead of BUG

2024-08-19 Thread Michael Ellerman
The overflow/underflow conditions in pata_macio_qc_prep() should never happen. But if they do there's no need to kill the system entirely, a WARN and failing the IO request should be sufficient and might allow the system to keep running. Signed-off-by: Michael Ellerman --- driver

[PATCH] ata: pata_macio: Fix DMA table overflow

2024-08-19 Thread Michael Ellerman
nel.org/all/3b6441b8-06e6-45da-9e55-f92f2c869...@ufal.mff.cuni.cz/ Tested-by: Kolbjørn Barmen Signed-off-by: Michael Ellerman --- drivers/ata/pata_macio.c | 23 +++ 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/drivers/ata/pata_macio.c b/drivers/ata/pata_m

[GIT PULL] Please pull powerpc/linux.git powerpc-6.11-2 tag

2024-08-17 Thread Michael Ellerman
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Hi Linus, Please pull some powerpc fixes for 6.11: The following changes since commit de9c2c66ad8e787abec7c9d7eff4f8c3cdd28aed: Linux 6.11-rc2 (2024-08-04 13:50:53 -0700) are available in the git repository at: https://git.kernel.org/pub/scm

Re: Since 6.10 - kernel oops/panics on G4 macmini due to change in drivers/ata/pata_macio.c

2024-08-16 Thread Michael Ellerman
Niklas Cassel writes: > On Wed, Aug 14, 2024 at 10:20:55PM +1000, Michael Ellerman wrote: >> Niklas Cassel writes: >> > On Tue, Aug 13, 2024 at 10:32:36PM +1000, Michael Ellerman wrote: >> >> Niklas Cassel writes: >> >> > On Tue, Aug 13

Re: [PATCH v3 14/16] modules: Support extended MODVERSIONS info

2024-08-16 Thread Michael Ellerman
Matthew Maurer writes: > Adds a new format for MODVERSIONS which stores each field in a separate > ELF section. This initially adds support for variable length names, but > could later be used to add additional fields to MODVERSIONS in a > backwards compatible way if needed. Any new fields will be

Re: [PATCH v3] PCI: Fix crash during pci_dev hot-unplug on pseries KVM guest

2024-08-16 Thread Michael Ellerman
Amit Machhiwal writes: > On 2024/08/15 01:20 PM, Michael Ellerman wrote: >> Bjorn Helgaas writes: >> > On Sat, Aug 03, 2024 at 12:03:25AM +0530, Amit Machhiwal wrote: >> >> With CONFIG_PCI_DYNAMIC_OF_NODES [1], a hot-plug and hot-unplug sequence >> >>

Re: OVERFLOW_KUNIT_TEST fails with BUG: KASAN: stack-out-of-bounds in string_nocheck+0x168/0x1c8 (kernel 6.11-rc2, PowerMac G4 DP)

2024-08-16 Thread Michael Ellerman
Ivan Orlov writes: > On 8/15/24 00:26, Ivan Orlov wrote: >> >> As you can see, the device name is defined as a local variable, which >> means that it doesn't exist out of the 'overflow_allocation_test' >> function scope. This patch: >> >> diff --git a/lib/overflow_kunit.c b/lib/overflow_kunit.

Re: 'do_IRQ: stack overflow: 1072' at using bcachefs partition (ppc32, kernel 6.10.5)

2024-08-16 Thread Michael Ellerman
Erhard Furtner writes: > Greetings! > > Basically bcachefs works on ppc32 but I get stack overflows like this one > rather easy: > > [...] > do_IRQ: stack overflow: 1072 > CPU: 1 PID: 2114 Comm: bash Not tainted 6.10.5-gentoo-PMacG4 #1 > Hardware name: PowerMac3,6 7455 0x80010303 PowerMac > Call

Re: [PATCH] powerpc/ftrace: restore r2 to caller's stack on livepatch sibling call

2024-08-15 Thread Michael Ellerman
Ryan Sullivan writes: > Hello Michael, > > In the case of no sibling call within the livepatch then the store is > only "restoring" the r2 value that was already there as it is stored > and retrieved from the livepatch stack. But what guarantee do we have that it

Re: [PATCH v3] PCI: Fix crash during pci_dev hot-unplug on pseries KVM guest

2024-08-14 Thread Michael Ellerman
Bjorn Helgaas writes: > On Sat, Aug 03, 2024 at 12:03:25AM +0530, Amit Machhiwal wrote: >> With CONFIG_PCI_DYNAMIC_OF_NODES [1], a hot-plug and hot-unplug sequence >> of a PCI device attached to a PCI-bridge causes following kernel Oops on >> a pseries KVM guest: > > What is unique about pseries h

Re: Since 6.10 - kernel oops/panics on G4 macmini due to change in drivers/ata/pata_macio.c

2024-08-14 Thread Michael Ellerman
Niklas Cassel writes: > On Tue, Aug 13, 2024 at 10:32:36PM +1000, Michael Ellerman wrote: >> Niklas Cassel writes: >> > On Tue, Aug 13, 2024 at 07:49:34AM +0200, Jonáš Vidra wrote: ... >> >> [ cut here ] >> >> kernel BUG at dri

Re: [PATCH v5 0/7] mm/mprotect: Fix dax puds

2024-08-13 Thread Michael Ellerman
Peter Xu writes: > [Based on mm-unstable, commit 98808d08fc0f, Aug 7th. NOTE: it is > intentional to not have rebased to latest mm-unstable, as this is to > replace the queued v4] > > v5 Changelog: > - Rename patch subject "mm/x86: arch_check_zapped_pud()", add "Implement" > [tglx] > - Mostly r

Re: [PATCH v2] KVM: PPC: Book3S HV: Refactor HFSCR emulation for KVM guests

2024-08-13 Thread Michael Ellerman
On Tue, 16 Jul 2024 17:22:04 +0530, Gautam Menghani wrote: > Refactor HFSCR emulation for KVM guests when they exit out with > H_FAC_UNAVAIL to use a switch case instead of checking all "cause" > values, since the "cause" values are mutually exclusive; and this is > better expressed with a switch c

Re: [PATCH v2 0/2] Skip offline cores when enabling SMT on PowerPC

2024-08-13 Thread Michael Ellerman
On Wed, 31 Jul 2024 08:31:11 +0530, Nysal Jan K.A. wrote: > After the addition of HOTPLUG_SMT support for PowerPC [1] there was a > regression reported [2] when enabling SMT. On a system with at least > one offline core, when enabling SMT, the expectation is that no CPUs > of offline cores are made

Re: Since 6.10 - kernel oops/panics on G4 macmini due to change in drivers/ata/pata_macio.c

2024-08-13 Thread Michael Ellerman
h the 6.10.3 kernel version. Reverting the linked change >> ("ata: pata_macio: Fix max_segment_size with PAGE_SIZE == 64K") makes >> the errors go away. > > Michael, as the author of the this commit, could you please look into > this issue? I can. My commit was reall

Re: [PATCH v2] selftest/powerpc/benchmark: remove requirement libc-dev

2024-08-13 Thread Michael Ellerman
and the same is > proposed as a fix here. > > Suggested-by: Michael Ellerman > Signed-off-by: Madhavan Srinivasan > --- > Chnagelog v1: > - Add comment for clobber register and proper list of > clobber registers as suggested by Michael Ellerman and > Christophe Leroy > >

Re: [PATCH] powerpc/476: Drop explicit initialization of struct i2c_device_id::driver_data to 0

2024-08-12 Thread Michael Ellerman
On Sun, 04 Aug 2024 13:20:31 +0200, Uwe Kleine-König wrote: > This driver doesn't use the driver_data member of struct i2c_device_id, > so don't explicitly initialize this member. > > This prepares putting driver_data in an anonymous union which requires > either no initialization or named designa

Re: [PATCH 0/2] arch: powerpc: Use backlight power constants

2024-08-12 Thread Michael Ellerman
On Wed, 31 Jul 2024 15:06:13 +0200, Thomas Zimmermann wrote: > Commit a1cacb8a8e70 ("backlight: Add BACKLIGHT_POWER_ constants for > power states") introduced dedicated constants for backlight power states. > Convert PowerPC code to the new constants. > > The new constants replace the fbdev consta

Re: [PATCH -next v2] powerpc: Remove useless config comment in asm/percpu.h

2024-08-12 Thread Michael Ellerman
On Wed, 07 Aug 2024 10:56:04 +0800, Jinjie Ruan wrote: > commit 0db880fc865f ("powerpc: Avoid nmi_enter/nmi_exit in real mode > interrupt.") has a config comment typo, and the #if/#else/#endif section > is small and doesn't nest additional #ifdefs so the comment is useless > and should be removed c

Re: [PATCH] powerpc: Use of_property_present()

2024-08-12 Thread Michael Ellerman
On Wed, 31 Jul 2024 13:12:47 -0600, Rob Herring (Arm) wrote: > Use of_property_present() to test for property presence rather than > of_get_property(). This is part of a larger effort to remove callers > of of_get_property() and similar functions. of_get_property() leaks > the DT property data poin

Re: [PATCH] soc/fsl/qbman: remove unused struct 'cgr_comp'

2024-08-12 Thread Michael Ellerman
On Wed, 29 May 2024 00:11:23 +0100, li...@treblig.org wrote: > 'cgr_comp' has been unused since > commit 96f413f47677 ("soc/fsl/qbman: fix issue in > qman_delete_cgr_safe()"). > > Remove it. > > > [...] Applied to powerpc/fixes. [1/1] soc/fsl/qbman: remove unused struct 'cgr_comp' https:

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