Thread (17 messages) flat view 17 messages, 2 authors, 2024-12-04

Re: [PATCH 1/3] powerpc: copy preempt.h into arch/include/asm

From: Christophe Leroy <hidden>
Date: 2024-12-02 18:17:41
Also in: lkml


Le 02/12/2024 à 15:05, Shrikanth Hegde a écrit :

On 11/27/24 12:07, Christophe Leroy wrote:
quoted

Le 25/11/2024 à 05:22, Shrikanth Hegde a écrit :
quoted
PowerPC uses asm-generic preempt definitions as of now.
Copy that into arch/asm so that arch specific changes can be done.
This would help the next patch for enabling dynamic preemption.
The reason I want the content instead was to allow future patches where 
I thought of making preempt count per paca for ppc64 atleast. generic 
code assumes it is per thread. If this change is to be done at that 
point, that is fair too. I am okay with it.
I think it is better to keep series minimal and consistent. If you have 
a futur plan, no problem, keep it future and do everything at once 
unless it is heavy and better done in two steps.

As we say in French, a lot of water will have flowed under the bridge by 
then.

I'm sure there will be a lot of discussion when you do that and maybe at 
the end you will end up with something completely different than what 
you have in mind at the moment.
quoted
Instead of copying all the content of asm-generic version, can you 
just create a receptacle for your new macros, that will include asm- 
generic/ preempt.h ?

Look at arch/powerpc/include/asm/percpu.h for exemple.
You mean something like below right?


#ifndef __ASM_POWERPC_PREEMPT_H
#define __ASM_POWERPC_PREEMPT_H

#include <asm-generic/preempt.h>

#if defined(CONFIG_PREEMPT_DYNAMIC) && 
defined(CONFIG_HAVE_PREEMPT_DYNAMIC_KEY)
DECLARE_STATIC_KEY_TRUE(sk_dynamic_irqentry_exit_cond_resched);
#endif

#endif /* __ASM_POWERPC_PREEMPT_H */
Yes exactly.


Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help