summaryrefslogtreecommitdiff
path: root/include/linux/serial_core.h
diff options
context:
space:
mode:
authorRob Herring <robh@kernel.org>2014-03-27 17:06:16 +0400
committerRob Herring <robh@kernel.org>2014-05-21 00:19:25 +0400
commitb0b6abd34c1b508d4ac95dbc614f36c49d29e65a (patch)
tree153b298e55c0ba79dc0ff1ad7f3d308f8d9ed32f /include/linux/serial_core.h
parent54196ccbe0ba1f268a646059473313589db35b01 (diff)
downloadlinux-b0b6abd34c1b508d4ac95dbc614f36c49d29e65a.tar.xz
serial: earlycon: add DT support
This adds the infrastructure to generic earlycon for earlycon setup using DT. The actual setup is not enabled until a following commit to add the FDT parsing. Signed-off-by: Rob Herring <robh@kernel.org> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Jiri Slaby <jslaby@suse.cz> Cc: Arnd Bergmann <arnd@arndb.de> Acked-by: Grant Likely <grant.likely@linaro.org>
Diffstat (limited to 'include/linux/serial_core.h')
-rw-r--r--include/linux/serial_core.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/serial_core.h b/include/linux/serial_core.h
index 7a15b5b24c0b..5bbb809ee197 100644
--- a/include/linux/serial_core.h
+++ b/include/linux/serial_core.h
@@ -294,6 +294,9 @@ struct earlycon_device {
int setup_earlycon(char *buf, const char *match,
int (*setup)(struct earlycon_device *, const char *));
+extern int of_setup_earlycon(unsigned long addr,
+ int (*setup)(struct earlycon_device *, const char *));
+
#define EARLYCON_DECLARE(name, func) \
static int __init name ## _setup_earlycon(char *buf) \
{ \
@@ -301,6 +304,9 @@ static int __init name ## _setup_earlycon(char *buf) \
} \
early_param("earlycon", name ## _setup_earlycon);
+#define OF_EARLYCON_DECLARE(name, compat, fn) \
+ _OF_DECLARE(earlycon, name, compat, fn, void *)
+
struct uart_port *uart_get_console(struct uart_port *ports, int nr,
struct console *c);
void uart_parse_options(char *options, int *baud, int *parity, int *bits,