diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2015-07-29 11:41:06 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2015-07-31 08:49:42 +0200 |
commit | ca8a4b0ff52a7505d3970c2619a309a52f7479fc (patch) | |
tree | aef68446454edad57f9ee72ff0d03f53569208e8 /include | |
parent | 37b8e171350d8803f3a637813c28fdd89a18d28a (diff) | |
download | barebox-ca8a4b0ff52a7505d3970c2619a309a52f7479fc.tar.gz barebox-ca8a4b0ff52a7505d3970c2619a309a52f7479fc.tar.xz |
PBL: console: Make independent of DEBUG_LL
With more stuff being done in PBL regular console support gets more and more
useful. This makes the PBL console independent of DEBUG_LL which is only
meant for early debugging but not regular output.
To use the regular PBL console a board must call pbl_set_putc() which stores
a pointer to the putc function to be used.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/console.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/console.h b/include/console.h index 839ec17e50..a6737c8581 100644 --- a/include/console.h +++ b/include/console.h @@ -83,4 +83,10 @@ unsigned console_get_active(struct console_device *cdev); int console_set_baudrate(struct console_device *cdev, unsigned baudrate); unsigned console_get_baudrate(struct console_device *cdev); +#ifdef CONFIG_PBL_CONSOLE +void pbl_set_putc(void (*putcf)(void *ctx, int c), void *ctx); +#else +static inline void pbl_set_putc(void (*putcf)(void *ctx, int c), void *ctx) {} +#endif + #endif |