]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
console: move for_each_console to linux/console.h
authorJiri Slaby <jslaby@suse.cz>
Thu, 4 Nov 2010 15:20:20 +0000 (16:20 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 16 Nov 2010 20:50:17 +0000 (12:50 -0800)
Move it out of printk.c so that we can use it all over the code. There
are some potential users which will be converted to that macro in next
patches.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
include/linux/console.h
kernel/printk.c

index 95cf6f08a59d2f39e51ba182a911f8f3ec5675cd..875cfb1c8132feb7fcd29d038c596cba133be829 100644 (file)
@@ -126,6 +126,12 @@ struct console {
        struct   console *next;
 };
 
+/*
+ * for_each_console() allows you to iterate on each console
+ */
+#define for_each_console(con) \
+       for (con = console_drivers; con != NULL; con = con->next)
+
 extern int console_set_on_cmdline;
 
 extern int add_preferred_console(char *name, int idx, char *options);
index b2ebaee8c377d2aa92c073e772748242b5ce5c90..bf0420a92a1a4cd7e714980d949a1691c881e63b 100644 (file)
 
 #include <asm/uaccess.h>
 
-/*
- * for_each_console() allows you to iterate on each console
- */
-#define for_each_console(con) \
-       for (con = console_drivers; con != NULL; con = con->next)
-
 /*
  * Architectures can override it:
  */