Re: [PATCH v2 06/14] powerpc: Include all arch-specific syscall prototypes

2022-08-09 Thread Andrew Donnellan
On Mon, 2022-08-08 at 15:24 +1000, Andrew Donnellan wrote: > > diff --git a/arch/powerpc/include/asm/syscalls.h > > b/arch/powerpc/include/asm/syscalls.h > > index 025d4b877161..8b2757d7f423 100644 > > --- a/arch/powerpc/include/asm/syscalls.h > > +++ b/arch/powerpc/include/asm/syscalls.h > > @@

Re: [PATCH 06/17] powerpc/qspinlock: theft prevention to control latency

2022-08-09 Thread Jordan Niethe
On Thu, 2022-07-28 at 16:31 +1000, Nicholas Piggin wrote: > Give the queue head the ability to stop stealers. After a number of > spins without sucessfully acquiring the lock, the queue head employs > this, which will assure it is the next owner. > --- > arch/powerpc/include/asm/qspinlock_types.h

[PATCH v2] powerpc/kexec: Fix build failure from uninitialised variable

2022-08-09 Thread Russell Currey
clang 14 won't build because ret is uninitialised and can be returned if both prop and fdtprop are NULL. Drop the ret variable and return an error in that failure case. Fixes: b1fc44eaa9ba ("pseries/iommu/ddw: Fix kdump to work in absence of ibm,dma-window") Suggested-by: Christophe Leroy

Re: [PATCH 05/17] powerpc/qspinlock: allow new waiters to steal the lock before queueing

2022-08-09 Thread Jordan Niethe
On Thu, 2022-07-28 at 16:31 +1000, Nicholas Piggin wrote: > Allow new waiters a number of spins on the lock word before queueing, > which particularly helps paravirt performance when physical CPUs are > oversubscribed. > --- > arch/powerpc/lib/qspinlock.c | 152 ---

[PATCH] docs: powerpc: add POWER9 and POWER10 to CPU families

2022-08-09 Thread Nicholas Miehlbradt
Add POWER9 and POWER10 to CPU families and list Radix MMU. Signed-off-by: Nicholas Miehlbradt --- Documentation/powerpc/cpu_families.rst | 13 + 1 file changed, 13 insertions(+) diff --git a/Documentation/powerpc/cpu_families.rst b/Documentation/powerpc/cpu_families.rst index

Re: [PATCH 04/17] powerpc/qspinlock: convert atomic operations to assembly

2022-08-09 Thread Jordan Niethe
On Thu, 2022-07-28 at 16:31 +1000, Nicholas Piggin wrote: > This uses more optimal ll/sc style access patterns (rather than > cmpxchg), and also sets the EH=1 lock hint on those operations > which acquire ownership of the lock. > --- > arch/powerpc/include/asm/qspinlock.h | 25 +-- >

Re: [PATCH 03/17] powerpc/qspinlock: use a half-word store to unlock to avoid larx/stcx.

2022-08-09 Thread Jordan Niethe
On Thu, 2022-07-28 at 16:31 +1000, Nicholas Piggin wrote: > The first 16 bits of the lock are only modified by the owner, and other > modifications always use atomic operations on the entire 32 bits, so > unlocks can use plain stores on the 16 bits. This is the same kind of > optimisation done by

Re: [PATCH 02/17] powerpc/qspinlock: add mcs queueing for contended waiters

2022-08-09 Thread Jordan NIethe
On Thu, 2022-07-28 at 16:31 +1000, Nicholas Piggin wrote: > > +/* > + * Bitfields in the atomic value: > + * > + * 0: locked bit > + * 16-31: tail cpu (+1) > + */ > +#define _Q_SET_MASK(type) (((1U << _Q_ ## type ## _BITS) - 1)\ > + << _Q_ ##

Re: [PATCH 01/17] powerpc/qspinlock: powerpc qspinlock implementation

2022-08-09 Thread Jordan NIethe
On Thu, 2022-07-28 at 16:31 +1000, Nicholas Piggin wrote: > -#define queued_spin_lock queued_spin_lock > > -static inline void queued_spin_unlock(struct qspinlock *lock) > +static __always_inline int queued_spin_trylock(struct qspinlock *lock) > { > - if

Re: [PATCH 06/16] powerpc: Fix objtool unannotated intra-function call warnings on PPC32

2022-08-09 Thread kernel test robot
Hi Sathvika, I love your patch! Yet something to improve: [auto build test ERROR on linus/master] [also build test ERROR on v5.19 next-20220809] [cannot apply to powerpc/next powerpc/topic/ppc-kvm masahiroy-kbuild/for-next] [If your patch is applied to the wrong git tree, kindly drop us a note

Re: [PATCH] powerpc64/ftrace: Fix ftrace for clang builds

2022-08-09 Thread Ondrej Mosnáček
On Tue, Aug 9, 2022 at 11:59 AM Naveen N. Rao wrote: > Clang doesn't support -mprofile-kernel ABI, so guard the checks against > CONFIG_DYNAMIC_FTRACE_WITH_REGS, rather than the elf ABI version. > > Fixes: 23b44fc248f420 ("powerpc/ftrace: Make __ftrace_make_{nop/call}() > common to PPC32 and

Re: [PATCH v4 3/8] dt-bindings: clock: Add ids for Lynx 10g PLLs

2022-08-09 Thread Sean Anderson
On 8/9/22 1:21 AM, Krzysztof Kozlowski wrote: > On 08/08/2022 18:16, Sean Anderson wrote: >> >>> This entry here is not >>> parsed for any tools and only sometimes people look at it. The questions >>> are directed via entry in maintainers file or via git history, so you >>> can put company

[PATCH] powerpc/ftrace: Ignore weak functions

2022-08-09 Thread Naveen N. Rao
Extend commit b39181f7c6907d ("ftrace: Add FTRACE_MCOUNT_MAX_OFFSET to avoid adding weak function") to ppc32 and ppc64 -mprofile-kernel by defining FTRACE_MCOUNT_MAX_OFFSET. For ppc64 -mprofile-kernel ABI, we can have two instructions at function entry for TOC setup followed by 'mflr r0' and 'bl

Re: [PATCH] powerpc/kexec: Fix build failure from uninitialised variable

2022-08-09 Thread Christophe Leroy
Le 09/08/2022 à 07:45, Russell Currey a écrit : > clang 14 won't build because ret is uninitialised and can be returned if > both prop and fdtprop are NULL. > > Fixes: b1fc44eaa9ba ("pseries/iommu/ddw: Fix kdump to work in absence of > ibm,dma-window") > Signed-off-by: Russell Currey > --- >

[PATCH] powerpc64/ftrace: Fix ftrace for clang builds

2022-08-09 Thread Naveen N. Rao
Clang doesn't support -mprofile-kernel ABI, so guard the checks against CONFIG_DYNAMIC_FTRACE_WITH_REGS, rather than the elf ABI version. Fixes: 23b44fc248f420 ("powerpc/ftrace: Make __ftrace_make_{nop/call}() common to PPC32 and PPC64") Reported-by: Nick Desaulniers Reported-by: Ondrej

Re: [PATCH v3] powerpc/mm: Support execute-only memory on the Radix MMU

2022-08-09 Thread Russell Currey
On Tue, 2022-08-09 at 05:51 +, Christophe Leroy wrote: > Le 09/08/2022 à 04:44, Russell Currey a écrit : > > The Hash MMU already supports XOM (i.e. mmap with PROT_EXEC only) > > through the execute-only pkey.  A PROT_EXEC-only mapping will > > actually > > map to RX, and then the pkey will be

Re: [PATCH v3] powerpc/mm: Support execute-only memory on the Radix MMU

2022-08-09 Thread Aneesh Kumar K V
On 8/9/22 11:21 AM, Christophe Leroy wrote: > Le 09/08/2022 à 04:44, Russell Currey a écrit : >> The Hash MMU already supports XOM (i.e. mmap with PROT_EXEC only) >> through the execute-only pkey. A PROT_EXEC-only mapping will actually >> map to RX, and then the pkey will be applied on top of it.

Re: [PATCH v3 11/25] powerpc/ftrace: Make __ftrace_make_{nop/call}() common to PPC32 and PPC64

2022-08-09 Thread Naveen N. Rao
Nick Desaulniers wrote: Christ...that's not what I meant to send; sorry, mutt is giving me bizarro errors today so I can't insert myself into threads using the usual incantation I have in the past. What I meant to send was: Christophe, Ondrej reported a regression with ftrace when building w/