Le 07/09/2020 à 06:02, Nicholas Piggin a écrit :
Excerpts from Christophe Leroy's message of September 6, 2020 5:32 pm:


Le 05/09/2020 à 19:43, Nicholas Piggin a écrit :
There is no need for this to be in asm, use the new intrrupt entry wrapper.

Signed-off-by: Nicholas Piggin <npig...@gmail.com>
---
   arch/powerpc/include/asm/interrupt.h   | 14 ++++++++
   arch/powerpc/include/asm/processor.h   |  1 +
   arch/powerpc/include/asm/thread_info.h |  6 ++++
   arch/powerpc/kernel/exceptions-64s.S   | 45 --------------------------
   arch/powerpc/kernel/idle_book3s.S      |  4 +++
   5 files changed, 25 insertions(+), 45 deletions(-)

diff --git a/arch/powerpc/include/asm/processor.h 
b/arch/powerpc/include/asm/processor.h
index ed0d633ab5aa..3da1dba91386 100644
--- a/arch/powerpc/include/asm/processor.h
+++ b/arch/powerpc/include/asm/processor.h
@@ -424,6 +424,7 @@ extern unsigned long isa300_idle_stop_mayloss(unsigned long 
psscr_val);
   extern unsigned long isa206_idle_insn_mayloss(unsigned long type);
   #ifdef CONFIG_PPC_970_NAP
   extern void power4_idle_nap(void);
+extern void power4_idle_nap_return(void);

Please please please, 'extern' keyword is pointless and deprecated for
function prototypes. Don't add new ones.

Also, put it outside the #ifdef, so that you can use IS_ENABLED()
instead of #ifdef when using it.

I just copy paste and forget to remove it. I expect someone will do a
"cleanup" patch to get rid of them in one go, I find a random assortment
of extern and not extern to be even uglier :(

If we don't want to make fixes backporting a huge headache, some transition with random assortment is the price to pay.

One day, when 'extern' have become the minority, we can get rid of the few last ones.

But if someone believe it is not such a problem with backporting, I can provide a cleanup patch now.

Christophe

Reply via email to