linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] treewide: __attribute__ neatening
@ 2011-11-10  9:41 Joe Perches
  2011-11-10  9:41 ` [PATCH 1/5] kernel.h: Neaten panic prototype Joe Perches
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Joe Perches @ 2011-11-10  9:41 UTC (permalink / raw)
  To: Andrew Morton
  Cc: linux-kernel, linux-ia64, linux-m68k, linux-mips,
	linux-am33-list, linuxppc-dev, linux-s390, linux-sh

Use the more current __<foo> styles for compiler attributes.
NORET_TYPE is #defined to a null comment, so just remove it.

Joe Perches (5):
  kernel.h: Neaten panic prototype
  linkage: Remove unused NORET_AND macro
  treewide: Remove useless NORET_TYPE macro and uses
  treewide: Convert uses of ATTRIB_NORETURN to __noreturn
  linkage: Remove unused ATTRIB_NORET macro

 arch/avr32/include/asm/system.h        |    2 +-
 arch/avr32/kernel/traps.c              |    2 +-
 arch/ia64/kernel/machine_kexec.c       |    4 ++--
 arch/m68k/amiga/config.c               |    4 ++--
 arch/mips/include/asm/ptrace.h         |    2 +-
 arch/mips/kernel/traps.c               |    2 +-
 arch/mn10300/include/asm/exceptions.h  |    2 +-
 arch/powerpc/kernel/machine_kexec_32.c |    4 ++--
 arch/powerpc/kernel/machine_kexec_64.c |    6 +++---
 arch/s390/include/asm/processor.h      |    2 +-
 arch/s390/kernel/nmi.c                 |    2 +-
 arch/sh/kernel/process_32.c            |    2 +-
 arch/sh/kernel/process_64.c            |    2 +-
 arch/tile/kernel/machine_kexec.c       |    6 +++---
 include/linux/kernel.h                 |   13 +++++++------
 include/linux/linkage.h                |    4 ----
 include/linux/sched.h                  |    2 +-
 kernel/exit.c                          |    6 +++---
 kernel/panic.c                         |    2 +-
 19 files changed, 33 insertions(+), 36 deletions(-)

-- 
1.7.6.405.gc1be0


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH 1/5] kernel.h: Neaten panic prototype
  2011-11-10  9:41 [PATCH 0/5] treewide: __attribute__ neatening Joe Perches
@ 2011-11-10  9:41 ` Joe Perches
  2011-11-10  9:41 ` [PATCH 2/5] linkage: Remove unused NORET_AND macro Joe Perches
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 11+ messages in thread
From: Joe Perches @ 2011-11-10  9:41 UTC (permalink / raw)
  To: Andrew Morton, linux-kernel

Use __printf macro.
Convert NORET_AND to ATTRIB_NORET.
Use the normal kernel style for pointer arguments.

Signed-off-by: Joe Perches <joe@perches.com>
---
 include/linux/kernel.h |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index e8b1597..23dae61 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -185,8 +185,9 @@ static inline void might_fault(void)
 
 extern struct atomic_notifier_head panic_notifier_list;
 extern long (*panic_blink)(int state);
-NORET_TYPE void panic(const char * fmt, ...)
-	__attribute__ ((NORET_AND format (printf, 1, 2))) __cold;
+NORET_TYPE __printf(1, 2)
+void panic(const char *fmt, ...)
+	ATTRIB_NORET __cold;
 extern void oops_enter(void);
 extern void oops_exit(void);
 void print_oops_end_marker(void);
-- 
1.7.6.405.gc1be0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 2/5] linkage: Remove unused NORET_AND macro
  2011-11-10  9:41 [PATCH 0/5] treewide: __attribute__ neatening Joe Perches
  2011-11-10  9:41 ` [PATCH 1/5] kernel.h: Neaten panic prototype Joe Perches
@ 2011-11-10  9:41 ` Joe Perches
  2011-11-10  9:41 ` [PATCH 3/5] treewide: Remove useless NORET_TYPE macro and uses Joe Perches
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 11+ messages in thread
From: Joe Perches @ 2011-11-10  9:41 UTC (permalink / raw)
  To: Andrew Morton, linux-kernel

The only use in kernel.h is gone so remove the macro.

Signed-off-by: Joe Perches <joe@perches.com>
---
 include/linux/linkage.h |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/include/linux/linkage.h b/include/linux/linkage.h
index 3f46aed..c75074c 100644
--- a/include/linux/linkage.h
+++ b/include/linux/linkage.h
@@ -90,6 +90,5 @@
 
 #define NORET_TYPE    /**/
 #define ATTRIB_NORET  __attribute__((noreturn))
-#define NORET_AND     noreturn,
 
 #endif
-- 
1.7.6.405.gc1be0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 3/5] treewide: Remove useless NORET_TYPE macro and uses
  2011-11-10  9:41 [PATCH 0/5] treewide: __attribute__ neatening Joe Perches
  2011-11-10  9:41 ` [PATCH 1/5] kernel.h: Neaten panic prototype Joe Perches
  2011-11-10  9:41 ` [PATCH 2/5] linkage: Remove unused NORET_AND macro Joe Perches
@ 2011-11-10  9:41 ` Joe Perches
  2011-11-10 11:41   ` Ralf Baechle
  2011-11-14 20:50   ` Geert Uytterhoeven
  2011-11-10  9:41 ` [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn Joe Perches
  2011-11-10  9:41 ` [PATCH 5/5] linkage: Remove unused ATTRIB_NORET macro Joe Perches
  4 siblings, 2 replies; 11+ messages in thread
From: Joe Perches @ 2011-11-10  9:41 UTC (permalink / raw)
  To: Andrew Morton, Ingo Molnar, Peter Zijlstra
  Cc: Haavard Skinnemoen, Hans-Christian Egtvedt, Tony Luck,
	Fenghua Yu, Geert Uytterhoeven, Ralf Baechle,
	Benjamin Herrenschmidt, Paul Mackerras, Martin Schwidefsky,
	Heiko Carstens, linux390, Chris Metcalf, linux-kernel,
	linux-ia64, linux-m68k, linux-mips, linuxppc-dev, linux-s390

It's a very old and now unused prototype marking
so just delete it.

Neaten panic pointer argument style to keep checkpatch quiet.

Signed-off-by: Joe Perches <joe@perches.com>
---
 arch/avr32/include/asm/system.h        |    2 +-
 arch/avr32/kernel/traps.c              |    2 +-
 arch/ia64/kernel/machine_kexec.c       |    2 +-
 arch/m68k/amiga/config.c               |    2 +-
 arch/mips/include/asm/ptrace.h         |    2 +-
 arch/mips/kernel/traps.c               |    2 +-
 arch/powerpc/kernel/machine_kexec_32.c |    2 +-
 arch/powerpc/kernel/machine_kexec_64.c |    6 +++---
 arch/s390/kernel/nmi.c                 |    2 +-
 arch/tile/kernel/machine_kexec.c       |    4 ++--
 include/linux/kernel.h                 |    6 +++---
 include/linux/linkage.h                |    1 -
 include/linux/sched.h                  |    2 +-
 kernel/exit.c                          |    6 +++---
 kernel/panic.c                         |    2 +-
 15 files changed, 21 insertions(+), 22 deletions(-)

diff --git a/arch/avr32/include/asm/system.h b/arch/avr32/include/asm/system.h
index 9702c221..62d9ded 100644
--- a/arch/avr32/include/asm/system.h
+++ b/arch/avr32/include/asm/system.h
@@ -169,7 +169,7 @@ static inline unsigned long __cmpxchg_local(volatile void *ptr,
 #define cmpxchg64_local(ptr, o, n) __cmpxchg64_local_generic((ptr), (o), (n))
 
 struct pt_regs;
-void NORET_TYPE die(const char *str, struct pt_regs *regs, long err);
+void die(const char *str, struct pt_regs *regs, long err);
 void _exception(long signr, struct pt_regs *regs, int code,
 		unsigned long addr);
 
diff --git a/arch/avr32/kernel/traps.c b/arch/avr32/kernel/traps.c
index 7aa2575..3d760c0 100644
--- a/arch/avr32/kernel/traps.c
+++ b/arch/avr32/kernel/traps.c
@@ -24,7 +24,7 @@
 
 static DEFINE_SPINLOCK(die_lock);
 
-void NORET_TYPE die(const char *str, struct pt_regs *regs, long err)
+void die(const char *str, struct pt_regs *regs, long err)
 {
 	static int die_counter;
 
diff --git a/arch/ia64/kernel/machine_kexec.c b/arch/ia64/kernel/machine_kexec.c
index 3d3aeef..581a16d 100644
--- a/arch/ia64/kernel/machine_kexec.c
+++ b/arch/ia64/kernel/machine_kexec.c
@@ -27,7 +27,7 @@
 #include <asm/sal.h>
 #include <asm/mca.h>
 
-typedef NORET_TYPE void (*relocate_new_kernel_t)(
+typedef void (*relocate_new_kernel_t)(
 					unsigned long indirection_page,
 					unsigned long start_address,
 					struct ia64_boot_param *boot_param,
diff --git a/arch/m68k/amiga/config.c b/arch/m68k/amiga/config.c
index 82a4bb5..a3b0558 100644
--- a/arch/m68k/amiga/config.c
+++ b/arch/m68k/amiga/config.c
@@ -511,7 +511,7 @@ static unsigned long amiga_gettimeoffset(void)
 	return ticks + offset;
 }
 
-static NORET_TYPE void amiga_reset(void)
+static void amiga_reset(void)
     ATTRIB_NORET;
 
 static void amiga_reset(void)
diff --git a/arch/mips/include/asm/ptrace.h b/arch/mips/include/asm/ptrace.h
index de39b1f..3d91325 100644
--- a/arch/mips/include/asm/ptrace.h
+++ b/arch/mips/include/asm/ptrace.h
@@ -144,7 +144,7 @@ extern int ptrace_set_watch_regs(struct task_struct *child,
 extern asmlinkage void syscall_trace_enter(struct pt_regs *regs);
 extern asmlinkage void syscall_trace_leave(struct pt_regs *regs);
 
-extern NORET_TYPE void die(const char *, struct pt_regs *) ATTRIB_NORET;
+extern void die(const char *, struct pt_regs *) ATTRIB_NORET;
 
 static inline void die_if_kernel(const char *str, struct pt_regs *regs)
 {
diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c
index 261ccbc..fc2cbbc 100644
--- a/arch/mips/kernel/traps.c
+++ b/arch/mips/kernel/traps.c
@@ -1340,7 +1340,7 @@ void ejtag_exception_handler(struct pt_regs *regs)
 /*
  * NMI exception handler.
  */
-NORET_TYPE void ATTRIB_NORET nmi_exception_handler(struct pt_regs *regs)
+void ATTRIB_NORET nmi_exception_handler(struct pt_regs *regs)
 {
 	bust_spinlocks(1);
 	printk("NMI taken!!!!\n");
diff --git a/arch/powerpc/kernel/machine_kexec_32.c b/arch/powerpc/kernel/machine_kexec_32.c
index e63f2e7..026e7f1 100644
--- a/arch/powerpc/kernel/machine_kexec_32.c
+++ b/arch/powerpc/kernel/machine_kexec_32.c
@@ -16,7 +16,7 @@
 #include <asm/hw_irq.h>
 #include <asm/io.h>
 
-typedef NORET_TYPE void (*relocate_new_kernel_t)(
+typedef void (*relocate_new_kernel_t)(
 				unsigned long indirection_page,
 				unsigned long reboot_code_buffer,
 				unsigned long start_address) ATTRIB_NORET;
diff --git a/arch/powerpc/kernel/machine_kexec_64.c b/arch/powerpc/kernel/machine_kexec_64.c
index 26ccbf7..5fbbf81 100644
--- a/arch/powerpc/kernel/machine_kexec_64.c
+++ b/arch/powerpc/kernel/machine_kexec_64.c
@@ -307,9 +307,9 @@ static union thread_union kexec_stack __init_task_data =
 struct paca_struct kexec_paca;
 
 /* Our assembly helper, in kexec_stub.S */
-extern NORET_TYPE void kexec_sequence(void *newstack, unsigned long start,
-					void *image, void *control,
-					void (*clear_all)(void)) ATTRIB_NORET;
+extern void kexec_sequence(void *newstack, unsigned long start,
+			   void *image, void *control,
+			   void (*clear_all)(void)) ATTRIB_NORET;
 
 /* too late to fail here */
 void default_machine_kexec(struct kimage *image)
diff --git a/arch/s390/kernel/nmi.c b/arch/s390/kernel/nmi.c
index fab8843..0fd2e86 100644
--- a/arch/s390/kernel/nmi.c
+++ b/arch/s390/kernel/nmi.c
@@ -30,7 +30,7 @@ struct mcck_struct {
 
 static DEFINE_PER_CPU(struct mcck_struct, cpu_mcck);
 
-static NORET_TYPE void s390_handle_damage(char *msg)
+static void s390_handle_damage(char *msg)
 {
 	smp_send_stop();
 	disabled_wait((unsigned long) __builtin_return_address(0));
diff --git a/arch/tile/kernel/machine_kexec.c b/arch/tile/kernel/machine_kexec.c
index e00d717..b0c9070 100644
--- a/arch/tile/kernel/machine_kexec.c
+++ b/arch/tile/kernel/machine_kexec.c
@@ -248,10 +248,10 @@ static void setup_quasi_va_is_pa(void)
 }
 
 
-NORET_TYPE void machine_kexec(struct kimage *image)
+void machine_kexec(struct kimage *image)
 {
 	void *reboot_code_buffer;
-	NORET_TYPE void (*rnk)(unsigned long, void *, unsigned long)
+	void (*rnk)(unsigned long, void *, unsigned long)
 		ATTRIB_NORET;
 
 	/* Mask all interrupts before starting to reboot. */
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index 23dae61..c0e0055 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -185,16 +185,16 @@ static inline void might_fault(void)
 
 extern struct atomic_notifier_head panic_notifier_list;
 extern long (*panic_blink)(int state);
-NORET_TYPE __printf(1, 2)
+__printf(1, 2)
 void panic(const char *fmt, ...)
 	ATTRIB_NORET __cold;
 extern void oops_enter(void);
 extern void oops_exit(void);
 void print_oops_end_marker(void);
 extern int oops_may_print(void);
-NORET_TYPE void do_exit(long error_code)
+void do_exit(long error_code)
 	ATTRIB_NORET;
-NORET_TYPE void complete_and_exit(struct completion *, long)
+void complete_and_exit(struct completion *, long)
 	ATTRIB_NORET;
 
 /* Internal, do not use. */
diff --git a/include/linux/linkage.h b/include/linux/linkage.h
index c75074c..6a8f252 100644
--- a/include/linux/linkage.h
+++ b/include/linux/linkage.h
@@ -88,7 +88,6 @@
 
 #endif
 
-#define NORET_TYPE    /**/
 #define ATTRIB_NORET  __attribute__((noreturn))
 
 #endif
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 68daf4f..5e00e6b 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -2252,7 +2252,7 @@ extern void __cleanup_sighand(struct sighand_struct *);
 extern void exit_itimers(struct signal_struct *);
 extern void flush_itimer_signals(void);
 
-extern NORET_TYPE void do_group_exit(int);
+extern void do_group_exit(int);
 
 extern void daemonize(const char *, ...);
 extern int allow_signal(int);
diff --git a/kernel/exit.c b/kernel/exit.c
index d0b7d98..d1bdbee 100644
--- a/kernel/exit.c
+++ b/kernel/exit.c
@@ -888,7 +888,7 @@ static void check_stack_usage(void)
 static inline void check_stack_usage(void) {}
 #endif
 
-NORET_TYPE void do_exit(long code)
+void do_exit(long code)
 {
 	struct task_struct *tsk = current;
 	int group_dead;
@@ -1049,7 +1049,7 @@ NORET_TYPE void do_exit(long code)
 
 EXPORT_SYMBOL_GPL(do_exit);
 
-NORET_TYPE void complete_and_exit(struct completion *comp, long code)
+void complete_and_exit(struct completion *comp, long code)
 {
 	if (comp)
 		complete(comp);
@@ -1068,7 +1068,7 @@ SYSCALL_DEFINE1(exit, int, error_code)
  * Take down every thread in the group.  This is called by fatal signals
  * as well as by sys_exit_group (below).
  */
-NORET_TYPE void
+void
 do_group_exit(int exit_code)
 {
 	struct signal_struct *sig = current->signal;
diff --git a/kernel/panic.c b/kernel/panic.c
index b2659360..9b7df21 100644
--- a/kernel/panic.c
+++ b/kernel/panic.c
@@ -57,7 +57,7 @@ EXPORT_SYMBOL(panic_blink);
  *
  *	This function never returns.
  */
-NORET_TYPE void panic(const char * fmt, ...)
+void panic(const char *fmt, ...)
 {
 	static char buf[1024];
 	va_list args;
-- 
1.7.6.405.gc1be0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn
  2011-11-10  9:41 [PATCH 0/5] treewide: __attribute__ neatening Joe Perches
                   ` (2 preceding siblings ...)
  2011-11-10  9:41 ` [PATCH 3/5] treewide: Remove useless NORET_TYPE macro and uses Joe Perches
@ 2011-11-10  9:41 ` Joe Perches
  2011-11-10 11:16   ` Ralf Baechle
                     ` (2 more replies)
  2011-11-10  9:41 ` [PATCH 5/5] linkage: Remove unused ATTRIB_NORET macro Joe Perches
  4 siblings, 3 replies; 11+ messages in thread
From: Joe Perches @ 2011-11-10  9:41 UTC (permalink / raw)
  To: Andrew Morton, linux-kernel
  Cc: Tony Luck, Fenghua Yu, Geert Uytterhoeven, Ralf Baechle,
	David Howells, Koichi Yasutake, Benjamin Herrenschmidt,
	Paul Mackerras, Martin Schwidefsky, Heiko Carstens, linux390,
	Paul Mundt, Chris Metcalf, linux-ia64, linux-m68k, linux-mips,
	linux-am33-list, linuxppc-dev, linux-s390, linux-sh

Use the more commonly used __noreturn instead of ATTRIB_NORETURN.

Signed-off-by: Joe Perches <joe@perches.com>
---
 arch/ia64/kernel/machine_kexec.c       |    2 +-
 arch/m68k/amiga/config.c               |    2 +-
 arch/mips/include/asm/ptrace.h         |    2 +-
 arch/mips/kernel/traps.c               |    2 +-
 arch/mn10300/include/asm/exceptions.h  |    2 +-
 arch/powerpc/kernel/machine_kexec_32.c |    2 +-
 arch/powerpc/kernel/machine_kexec_64.c |    2 +-
 arch/s390/include/asm/processor.h      |    2 +-
 arch/sh/kernel/process_32.c            |    2 +-
 arch/sh/kernel/process_64.c            |    2 +-
 arch/tile/kernel/machine_kexec.c       |    2 +-
 include/linux/kernel.h                 |    6 +++---
 12 files changed, 14 insertions(+), 14 deletions(-)

diff --git a/arch/ia64/kernel/machine_kexec.c b/arch/ia64/kernel/machine_kexec.c
index 581a16d..4eed358 100644
--- a/arch/ia64/kernel/machine_kexec.c
+++ b/arch/ia64/kernel/machine_kexec.c
@@ -31,7 +31,7 @@ typedef void (*relocate_new_kernel_t)(
 					unsigned long indirection_page,
 					unsigned long start_address,
 					struct ia64_boot_param *boot_param,
-					unsigned long pal_addr) ATTRIB_NORET;
+					unsigned long pal_addr) __noreturn;
 
 struct kimage *ia64_kimage;
 
diff --git a/arch/m68k/amiga/config.c b/arch/m68k/amiga/config.c
index a3b0558..7aec938 100644
--- a/arch/m68k/amiga/config.c
+++ b/arch/m68k/amiga/config.c
@@ -512,7 +512,7 @@ static unsigned long amiga_gettimeoffset(void)
 }
 
 static void amiga_reset(void)
-    ATTRIB_NORET;
+    __noreturn;
 
 static void amiga_reset(void)
 {
diff --git a/arch/mips/include/asm/ptrace.h b/arch/mips/include/asm/ptrace.h
index 3d91325..7b99c67 100644
--- a/arch/mips/include/asm/ptrace.h
+++ b/arch/mips/include/asm/ptrace.h
@@ -144,7 +144,7 @@ extern int ptrace_set_watch_regs(struct task_struct *child,
 extern asmlinkage void syscall_trace_enter(struct pt_regs *regs);
 extern asmlinkage void syscall_trace_leave(struct pt_regs *regs);
 
-extern void die(const char *, struct pt_regs *) ATTRIB_NORET;
+extern void die(const char *, struct pt_regs *) __noreturn;
 
 static inline void die_if_kernel(const char *str, struct pt_regs *regs)
 {
diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c
index fc2cbbc..ac740b0 100644
--- a/arch/mips/kernel/traps.c
+++ b/arch/mips/kernel/traps.c
@@ -1340,7 +1340,7 @@ void ejtag_exception_handler(struct pt_regs *regs)
 /*
  * NMI exception handler.
  */
-void ATTRIB_NORET nmi_exception_handler(struct pt_regs *regs)
+void __noreturn nmi_exception_handler(struct pt_regs *regs)
 {
 	bust_spinlocks(1);
 	printk("NMI taken!!!!\n");
diff --git a/arch/mn10300/include/asm/exceptions.h b/arch/mn10300/include/asm/exceptions.h
index ca3e205..95a4d42 100644
--- a/arch/mn10300/include/asm/exceptions.h
+++ b/arch/mn10300/include/asm/exceptions.h
@@ -110,7 +110,7 @@ extern asmlinkage void nmi_handler(void);
 extern asmlinkage void misalignment(struct pt_regs *, enum exception_code);
 
 extern void die(const char *, struct pt_regs *, enum exception_code)
-	ATTRIB_NORET;
+	__noreturn;
 
 extern int die_if_no_fixup(const char *, struct pt_regs *, enum exception_code);
 
diff --git a/arch/powerpc/kernel/machine_kexec_32.c b/arch/powerpc/kernel/machine_kexec_32.c
index 026e7f1..affe5dc 100644
--- a/arch/powerpc/kernel/machine_kexec_32.c
+++ b/arch/powerpc/kernel/machine_kexec_32.c
@@ -19,7 +19,7 @@
 typedef void (*relocate_new_kernel_t)(
 				unsigned long indirection_page,
 				unsigned long reboot_code_buffer,
-				unsigned long start_address) ATTRIB_NORET;
+				unsigned long start_address) __noreturn;
 
 /*
  * This is a generic machine_kexec function suitable at least for
diff --git a/arch/powerpc/kernel/machine_kexec_64.c b/arch/powerpc/kernel/machine_kexec_64.c
index 5fbbf81..d7f6090 100644
--- a/arch/powerpc/kernel/machine_kexec_64.c
+++ b/arch/powerpc/kernel/machine_kexec_64.c
@@ -309,7 +309,7 @@ struct paca_struct kexec_paca;
 /* Our assembly helper, in kexec_stub.S */
 extern void kexec_sequence(void *newstack, unsigned long start,
 			   void *image, void *control,
-			   void (*clear_all)(void)) ATTRIB_NORET;
+			   void (*clear_all)(void)) __noreturn;
 
 /* too late to fail here */
 void default_machine_kexec(struct kimage *image)
diff --git a/arch/s390/include/asm/processor.h b/arch/s390/include/asm/processor.h
index 5f33d37..c0d6f77 100644
--- a/arch/s390/include/asm/processor.h
+++ b/arch/s390/include/asm/processor.h
@@ -238,7 +238,7 @@ static inline unsigned long __rewind_psw(psw_t psw, unsigned long ilc)
 /*
  * Function to drop a processor into disabled wait state
  */
-static inline void ATTRIB_NORET disabled_wait(unsigned long code)
+static inline void __noreturn disabled_wait(unsigned long code)
 {
         unsigned long ctl_buf;
         psw_t dw_psw;
diff --git a/arch/sh/kernel/process_32.c b/arch/sh/kernel/process_32.c
index aaf6d59..7ec6651 100644
--- a/arch/sh/kernel/process_32.c
+++ b/arch/sh/kernel/process_32.c
@@ -70,7 +70,7 @@ void show_regs(struct pt_regs * regs)
 /*
  * Create a kernel thread
  */
-ATTRIB_NORET void kernel_thread_helper(void *arg, int (*fn)(void *))
+__noreturn void kernel_thread_helper(void *arg, int (*fn)(void *))
 {
 	do_exit(fn(arg));
 }
diff --git a/arch/sh/kernel/process_64.c b/arch/sh/kernel/process_64.c
index 210c1ca..cbd4e4b 100644
--- a/arch/sh/kernel/process_64.c
+++ b/arch/sh/kernel/process_64.c
@@ -285,7 +285,7 @@ void show_regs(struct pt_regs *regs)
 /*
  * Create a kernel thread
  */
-ATTRIB_NORET void kernel_thread_helper(void *arg, int (*fn)(void *))
+__noreturn void kernel_thread_helper(void *arg, int (*fn)(void *))
 {
 	do_exit(fn(arg));
 }
diff --git a/arch/tile/kernel/machine_kexec.c b/arch/tile/kernel/machine_kexec.c
index b0c9070..6255f2e 100644
--- a/arch/tile/kernel/machine_kexec.c
+++ b/arch/tile/kernel/machine_kexec.c
@@ -252,7 +252,7 @@ void machine_kexec(struct kimage *image)
 {
 	void *reboot_code_buffer;
 	void (*rnk)(unsigned long, void *, unsigned long)
-		ATTRIB_NORET;
+		__noreturn;
 
 	/* Mask all interrupts before starting to reboot. */
 	interrupt_mask_set_mask(~0ULL);
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index c0e0055..b93c66e 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -187,15 +187,15 @@ extern struct atomic_notifier_head panic_notifier_list;
 extern long (*panic_blink)(int state);
 __printf(1, 2)
 void panic(const char *fmt, ...)
-	ATTRIB_NORET __cold;
+	__noreturn __cold;
 extern void oops_enter(void);
 extern void oops_exit(void);
 void print_oops_end_marker(void);
 extern int oops_may_print(void);
 void do_exit(long error_code)
-	ATTRIB_NORET;
+	__noreturn;
 void complete_and_exit(struct completion *, long)
-	ATTRIB_NORET;
+	__noreturn;
 
 /* Internal, do not use. */
 int __must_check _kstrtoul(const char *s, unsigned int base, unsigned long *res);
-- 
1.7.6.405.gc1be0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 5/5] linkage: Remove unused ATTRIB_NORET macro
  2011-11-10  9:41 [PATCH 0/5] treewide: __attribute__ neatening Joe Perches
                   ` (3 preceding siblings ...)
  2011-11-10  9:41 ` [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn Joe Perches
@ 2011-11-10  9:41 ` Joe Perches
  4 siblings, 0 replies; 11+ messages in thread
From: Joe Perches @ 2011-11-10  9:41 UTC (permalink / raw)
  To: Andrew Morton, linux-kernel

The uses have been renamed so delete the unused macro.

Signed-off-by: Joe Perches <joe@perches.com>
---
 include/linux/linkage.h |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/include/linux/linkage.h b/include/linux/linkage.h
index 6a8f252..807f1e5 100644
--- a/include/linux/linkage.h
+++ b/include/linux/linkage.h
@@ -88,6 +88,4 @@
 
 #endif
 
-#define ATTRIB_NORET  __attribute__((noreturn))
-
 #endif
-- 
1.7.6.405.gc1be0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn
  2011-11-10  9:41 ` [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn Joe Perches
@ 2011-11-10 11:16   ` Ralf Baechle
  2011-11-11  2:02   ` Paul Mundt
  2011-11-14 20:50   ` Geert Uytterhoeven
  2 siblings, 0 replies; 11+ messages in thread
From: Ralf Baechle @ 2011-11-10 11:16 UTC (permalink / raw)
  To: Joe Perches
  Cc: Andrew Morton, linux-kernel, Tony Luck, Fenghua Yu,
	Geert Uytterhoeven, David Howells, Koichi Yasutake,
	Benjamin Herrenschmidt, Paul Mackerras, Martin Schwidefsky,
	Heiko Carstens, linux390, Paul Mundt, Chris Metcalf, linux-ia64,
	linux-m68k, linux-mips, linux-am33-list, linuxppc-dev,
	linux-s390, linux-sh

On Thu, Nov 10, 2011 at 01:41:45AM -0800, Joe Perches wrote:

> Use the more commonly used __noreturn instead of ATTRIB_NORETURN.

Subject and here: s/ATTRIB_NORETURN/ATTRIB_NORET/

> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  arch/ia64/kernel/machine_kexec.c       |    2 +-
>  arch/m68k/amiga/config.c               |    2 +-
>  arch/mips/include/asm/ptrace.h         |    2 +-
>  arch/mips/kernel/traps.c               |    2 +-

For the MIPS bits:

Acked-by: Ralf Baechle <ralf@linux-mips.org>

  Ralf

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] treewide: Remove useless NORET_TYPE macro and uses
  2011-11-10  9:41 ` [PATCH 3/5] treewide: Remove useless NORET_TYPE macro and uses Joe Perches
@ 2011-11-10 11:41   ` Ralf Baechle
  2011-11-14 20:50   ` Geert Uytterhoeven
  1 sibling, 0 replies; 11+ messages in thread
From: Ralf Baechle @ 2011-11-10 11:41 UTC (permalink / raw)
  To: Joe Perches
  Cc: Andrew Morton, Ingo Molnar, Peter Zijlstra, Haavard Skinnemoen,
	Hans-Christian Egtvedt, Tony Luck, Fenghua Yu,
	Geert Uytterhoeven, Benjamin Herrenschmidt, Paul Mackerras,
	Martin Schwidefsky, Heiko Carstens, linux390, Chris Metcalf,
	linux-kernel, linux-ia64, linux-m68k, linux-mips, linuxppc-dev,
	linux-s390

On Thu, Nov 10, 2011 at 01:41:44AM -0800, Joe Perches wrote:

>  arch/mips/include/asm/ptrace.h         |    2 +-
>  arch/mips/kernel/traps.c               |    2 +-

For the MIPS bits:

Acked-by: Ralf Baechle <ralf@linux-mips.org>

  Ralf

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn
  2011-11-10  9:41 ` [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn Joe Perches
  2011-11-10 11:16   ` Ralf Baechle
@ 2011-11-11  2:02   ` Paul Mundt
  2011-11-14 20:50   ` Geert Uytterhoeven
  2 siblings, 0 replies; 11+ messages in thread
From: Paul Mundt @ 2011-11-11  2:02 UTC (permalink / raw)
  To: Joe Perches
  Cc: Andrew Morton, linux-kernel, Tony Luck, Fenghua Yu,
	Geert Uytterhoeven, Ralf Baechle, David Howells, Koichi Yasutake,
	Benjamin Herrenschmidt, Paul Mackerras, Martin Schwidefsky,
	Heiko Carstens, linux390, Chris Metcalf, linux-ia64, linux-m68k,
	linux-mips, linux-am33-list, linuxppc-dev, linux-s390, linux-sh

On Thu, Nov 10, 2011 at 01:41:45AM -0800, Joe Perches wrote:
> Use the more commonly used __noreturn instead of ATTRIB_NORETURN.
> 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  arch/ia64/kernel/machine_kexec.c       |    2 +-
>  arch/m68k/amiga/config.c               |    2 +-
>  arch/mips/include/asm/ptrace.h         |    2 +-
>  arch/mips/kernel/traps.c               |    2 +-
>  arch/mn10300/include/asm/exceptions.h  |    2 +-
>  arch/powerpc/kernel/machine_kexec_32.c |    2 +-
>  arch/powerpc/kernel/machine_kexec_64.c |    2 +-
>  arch/s390/include/asm/processor.h      |    2 +-
>  arch/sh/kernel/process_32.c            |    2 +-
>  arch/sh/kernel/process_64.c            |    2 +-
>  arch/tile/kernel/machine_kexec.c       |    2 +-
>  include/linux/kernel.h                 |    6 +++---
>  12 files changed, 14 insertions(+), 14 deletions(-)
> 
For the SH bits:

Signed-off-by: Paul Mundt <lethal@linux-sh.org>

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] treewide: Remove useless NORET_TYPE macro and uses
  2011-11-10  9:41 ` [PATCH 3/5] treewide: Remove useless NORET_TYPE macro and uses Joe Perches
  2011-11-10 11:41   ` Ralf Baechle
@ 2011-11-14 20:50   ` Geert Uytterhoeven
  1 sibling, 0 replies; 11+ messages in thread
From: Geert Uytterhoeven @ 2011-11-14 20:50 UTC (permalink / raw)
  To: Joe Perches
  Cc: Andrew Morton, Ingo Molnar, Peter Zijlstra, Haavard Skinnemoen,
	Hans-Christian Egtvedt, Tony Luck, Fenghua Yu, Ralf Baechle,
	Benjamin Herrenschmidt, Paul Mackerras, Martin Schwidefsky,
	Heiko Carstens, linux390, Chris Metcalf, linux-kernel,
	linux-ia64, linux-m68k, linux-mips, linuxppc-dev, linux-s390

On Thu, Nov 10, 2011 at 10:41, Joe Perches <joe@perches.com> wrote:
> It's a very old and now unused prototype marking
> so just delete it.
>
> Neaten panic pointer argument style to keep checkpatch quiet.
>
> Signed-off-by: Joe Perches <joe@perches.com>

For the m68k parts:
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn
  2011-11-10  9:41 ` [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn Joe Perches
  2011-11-10 11:16   ` Ralf Baechle
  2011-11-11  2:02   ` Paul Mundt
@ 2011-11-14 20:50   ` Geert Uytterhoeven
  2 siblings, 0 replies; 11+ messages in thread
From: Geert Uytterhoeven @ 2011-11-14 20:50 UTC (permalink / raw)
  To: Joe Perches
  Cc: Andrew Morton, linux-kernel, Tony Luck, Fenghua Yu, Ralf Baechle,
	David Howells, Koichi Yasutake, Benjamin Herrenschmidt,
	Paul Mackerras, Martin Schwidefsky, Heiko Carstens, linux390,
	Paul Mundt, Chris Metcalf, linux-ia64, linux-m68k, linux-mips,
	linux-am33-list, linuxppc-dev, linux-s390, linux-sh

On Thu, Nov 10, 2011 at 10:41, Joe Perches <joe@perches.com> wrote:
> Use the more commonly used __noreturn instead of ATTRIB_NORETURN.
>
> Signed-off-by: Joe Perches <joe@perches.com>

For the m68k parts:
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2011-11-14 20:50 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-10  9:41 [PATCH 0/5] treewide: __attribute__ neatening Joe Perches
2011-11-10  9:41 ` [PATCH 1/5] kernel.h: Neaten panic prototype Joe Perches
2011-11-10  9:41 ` [PATCH 2/5] linkage: Remove unused NORET_AND macro Joe Perches
2011-11-10  9:41 ` [PATCH 3/5] treewide: Remove useless NORET_TYPE macro and uses Joe Perches
2011-11-10 11:41   ` Ralf Baechle
2011-11-14 20:50   ` Geert Uytterhoeven
2011-11-10  9:41 ` [PATCH 4/5] treewide: Convert uses of ATTRIB_NORETURN to __noreturn Joe Perches
2011-11-10 11:16   ` Ralf Baechle
2011-11-11  2:02   ` Paul Mundt
2011-11-14 20:50   ` Geert Uytterhoeven
2011-11-10  9:41 ` [PATCH 5/5] linkage: Remove unused ATTRIB_NORET macro Joe Perches

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).