9
0
Fork 0
Commit Graph

12 Commits

Author SHA1 Message Date
Sascha Hauer 4960dc9db0 rework debug_ll
Convert to static inline functions and use lower case letters for function
names. Also, include mach/debug_ll.h when an architecture provides support
for debug_ll, not only when it's actually enabled. This allows architecures
to put some UART initialization code into mach/debug_ll.h which is compiled
out when debug_ll is disabled.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-09-05 10:15:48 +02:00
Sascha Hauer c429c68416 console: consolidate common console code
The different console implementations share a good amount of code,
share this in console_common.c.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-02-13 09:22:33 +01:00
Jean-Christophe PLAGNIOL-VILLARD 0448644294 console: use debug_ll before the console is available
This will allow to have the same feature as earlyprintk in the kernel

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-10-30 10:23:50 +01:00
Sascha Hauer d13f42dd3c console simple: return with a proper error value
There can be only one console for console_simple, so
return with -EBUSY when the second gets registered.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-04-13 16:56:15 +02:00
Sascha Hauer 4430b1a6fc console_simple: fix compiler warning
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-07 13:05:54 +01:00
Sascha Hauer 0ee6847f7b Merge branch 'next' 2011-12-07 12:03:13 +01:00
Sascha Hauer ab6dc1d297 console_simple: Fix compilation
Since fprintf and console_puts now return the number of
character written the prototypes have changes. We forgot
to fix console_simple which now fails to compile with:

common/console_simple.c:48:6: error: conflicting types for 'fprintf'
include/stdio.h:57:5: note: previous declaration of 'fprintf' was here
common/console_simple.c:67:6: error: conflicting types for 'console_puts'
include/stdio.h:20:5: note: previous declaration of 'console_puts' was here

Fix this by returning the proper numbers of characters written.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-07 10:55:19 +01:00
Robert Jarzmik ea8314d19f console: add console unregistering
Some console are transient, like the USB connected serial
console which should be removed when the USB connection is
severed.

Enable console removal for such devices.

Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-05 17:59:02 +01:00
Sascha Hauer 3f1ff6b730 move version_string to seperate file
In a noninteractive environment barebox will be compiled without
command support. So move version_string to a seperate file which
is compiled unconditionally.
Also, display the banner when the simple console support is used.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-11 12:36:08 +02:00
Peter Korsgaard 1945936991 console_simple: add fprintf / console_list for commands/loadb.c
commands/loadb.c doesn't build with CONFIG_CONSOLE_SIMPLE, because it uses
fprintf / for_each_console (which uses console_list).

Fix it by adding trivial implementations of both in console_simple.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-12-12 09:27:40 +01:00
Sascha Hauer e536d48f60 simple console: implement console_flush
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-05-18 12:15:43 +02:00
Sascha Hauer aca52174a9 console: add a simple console for saving space
Add a simple console layer which is not able to handle multiple
consoles for those who don't need it.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-08-01 11:47:10 +02:00