All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/4] include/linux/printk.h is not self-contained
@ 2011-05-25  9:09 y
  2011-05-25 14:42 ` Joe Perches
  2011-05-25 17:09 ` [PATCH 1/4] include/linux/printk.h is not self-contained Randy Dunlap
  0 siblings, 2 replies; 20+ messages in thread
From: y @ 2011-05-25  9:09 UTC (permalink / raw)
  To: Andrew Morton, Joe Perches, Randy Dunlap; +Cc: linux-kernel, Geert Uytterhoeven

From: Geert Uytterhoeven <geert@linux-m68k.org>

<linux/printk.h> needs to include
  - <stdarg.h> for "va_list",
  - <linux/linkage.h> for "asmlinkage",
  - <linux/types.h> for "bool".

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
 include/linux/printk.h |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/include/linux/printk.h b/include/linux/printk.h
index ee048e7..6388bc8 100644
--- a/include/linux/printk.h
+++ b/include/linux/printk.h
@@ -1,6 +1,10 @@
 #ifndef __KERNEL_PRINTK__
 #define __KERNEL_PRINTK__
 
+#include <stdarg.h>
+#include <linux/linkage.h>
+#include <linux/types.h>
+
 extern const char linux_banner[];
 extern const char linux_proc_banner[];
 
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 20+ messages in thread
* [PATCH 4/4] treewide: Remove asmlinkage from printk
  2011-05-25 15:20   ` Geert Uytterhoeven
  2011-05-25 15:52     ` Alexey Dobriyan
  2011-05-25 17:02       ` Joe Perches
@ 2011-05-25 17:02 ` Joe Perches
  1 sibling, 0 replies; 20+ messages in thread
From: Joe Perches @ 2011-05-25 17:02 UTC (permalink / raw)
  To: kvm-ia64

Remove the now unnecessary asmlinkage attribute from the various
printk prototypes and uses.

Signed-off-by: Joe Perches <joe@perches.com>
---
 arch/arm/kernel/early_printk.c |    2 +-
 arch/ia64/kvm/vmm.c            |    2 +-
 arch/x86/kernel/early_printk.c |    2 +-
 include/linux/printk.h         |    6 +++---
 kernel/printk.c                |    6 +++---
 5 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/arch/arm/kernel/early_printk.c b/arch/arm/kernel/early_printk.c
index 85aa2b2..46798d5 100644
--- a/arch/arm/kernel/early_printk.c
+++ b/arch/arm/kernel/early_printk.c
@@ -36,7 +36,7 @@ static struct console early_console = {
 	.index =	-1,
 };
 
-asmlinkage void early_printk(const char *fmt, ...)
+void early_printk(const char *fmt, ...)
 {
 	char buf[512];
 	int n;
diff --git a/arch/ia64/kvm/vmm.c b/arch/ia64/kvm/vmm.c
index f0b9cac..40331ac 100644
--- a/arch/ia64/kvm/vmm.c
+++ b/arch/ia64/kvm/vmm.c
@@ -81,7 +81,7 @@ static void vcpu_debug_exit(struct kvm_vcpu *vcpu)
 	local_irq_restore(psr);
 }
 
-asmlinkage int printk(const char *fmt, ...)
+int printk(const char *fmt, ...)
 {
 	struct kvm_vcpu *vcpu = current_vcpu;
 	va_list args;
diff --git a/arch/x86/kernel/early_printk.c b/arch/x86/kernel/early_printk.c
index cd28a35..b9b323a 100644
--- a/arch/x86/kernel/early_printk.c
+++ b/arch/x86/kernel/early_printk.c
@@ -173,7 +173,7 @@ static struct console early_serial_console = {
 static struct console *early_console = &early_vga_console;
 static int __initdata early_console_initialized;
 
-asmlinkage void early_printk(const char *fmt, ...)
+void early_printk(const char *fmt, ...)
 {
 	char buf[512];
 	int n;
diff --git a/include/linux/printk.h b/include/linux/printk.h
index 3736545..e52bc4b 100644
--- a/include/linux/printk.h
+++ b/include/linux/printk.h
@@ -90,16 +90,16 @@ int no_printk(const char *fmt, ...)
 	return 0;
 }
 
-extern asmlinkage __attribute__ ((format (printf, 1, 2)))
+extern __attribute__ ((format (printf, 1, 2)))
 void early_printk(const char *fmt, ...);
 
 extern int printk_needs_cpu(int cpu);
 extern void printk_tick(void);
 
 #ifdef CONFIG_PRINTK
-asmlinkage __attribute__ ((format (printf, 1, 0)))
+__attribute__ ((format (printf, 1, 0)))
 int vprintk(const char *fmt, va_list args);
-asmlinkage __attribute__ ((format (printf, 1, 2))) __cold
+__attribute__ ((format (printf, 1, 2))) __cold
 int printk(const char *fmt, ...);
 
 /*
diff --git a/kernel/printk.c b/kernel/printk.c
index da8ca81..735056c 100644
--- a/kernel/printk.c
+++ b/kernel/printk.c
@@ -46,7 +46,7 @@
 /*
  * Architectures can override it:
  */
-void asmlinkage __attribute__((weak)) early_printk(const char *fmt, ...)
+void __attribute__((weak)) early_printk(const char *fmt, ...)
 {
 }
 
@@ -704,7 +704,7 @@ static int have_callable_console(void)
  * See the vsnprintf() documentation for format string extensions over C99.
  */
 
-asmlinkage int printk(const char *fmt, ...)
+int printk(const char *fmt, ...)
 {
 	va_list args;
 	int r;
@@ -794,7 +794,7 @@ static inline void printk_delay(void)
 	}
 }
 
-asmlinkage int vprintk(const char *fmt, va_list args)
+int vprintk(const char *fmt, va_list args)
 {
 	int printed_len = 0;
 	int current_log_level = default_message_loglevel;
-- 
1.7.4.rc3


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

end of thread, other threads:[~2011-05-29 20:40 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-25  9:09 [PATCH 1/4] include/linux/printk.h is not self-contained y
2011-05-25 14:42 ` Joe Perches
2011-05-25 15:20   ` Geert Uytterhoeven
2011-05-25 15:52     ` Alexey Dobriyan
2011-05-25 17:02     ` [PATCH 0/4] printk: cleanups of direct includes Joe Perches
2011-05-25 17:02       ` Joe Perches
2011-05-25 17:02       ` Joe Perches
2011-05-25 17:02       ` Joe Perches
2011-05-25 17:02       ` Joe Perches
2011-05-25 17:02       ` [PATCH 1/4] treewide: Remove direct includes of printk.h Joe Perches
2011-05-25 17:02       ` [PATCH 2/4] staging: " Joe Perches
2011-05-26  7:37         ` Roland Vossen
2011-05-29 17:00         ` julie Sullivan
2011-05-29 20:40           ` Joe Perches
2011-05-25 17:02       ` [PATCH 3/4] printk: Don't allow direct inclusion Joe Perches
2011-05-25 17:09 ` [PATCH 1/4] include/linux/printk.h is not self-contained Randy Dunlap
  -- strict thread matches above, loose matches on Subject: below --
2011-05-25 17:02 [PATCH 4/4] treewide: Remove asmlinkage from printk Joe Perches
2011-05-25 17:02 ` Joe Perches
2011-05-25 17:02 ` Joe Perches
2011-05-25 17:02 ` Joe Perches

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.