public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot-Users] [PATCH RESEND] serial: Make default_serial_console() a weak function
@ 2007-12-27 15:57 Matthias Fuchs
  2008-01-09 12:29 ` Wolfgang Denk
  0 siblings, 1 reply; 2+ messages in thread
From: Matthias Fuchs @ 2007-12-27 15:57 UTC (permalink / raw)
  To: u-boot

With this patch it is possible to reimplement default_serial_console()
in board specific code. This will be done in the upcomming PMC440
U-Boot port. This also allows the lwmon board maintainer to
remove the '#if !defined(CONFIG_LWMON) ...' from common/serial.c.

Signed-off-by: Matthias Fuchs <matthias.fuchs@esd-electronics.com>
---
 common/serial.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/common/serial.c b/common/serial.c
index b9916e2..5601080 100644
--- a/common/serial.c
+++ b/common/serial.c
@@ -33,7 +33,7 @@ static struct serial_device *serial_devices = NULL;
 static struct serial_device *serial_current = NULL;
 
 #if !defined(CONFIG_LWMON) && !defined(CONFIG_PXA27X)
-struct serial_device *default_serial_console (void)
+struct serial_device *__default_serial_console (void)
 {
 #if defined(CONFIG_8xx_CONS_SMC1) || defined(CONFIG_8xx_CONS_SMC2)
 	return &serial_smc_device;
@@ -64,6 +64,8 @@ struct serial_device *default_serial_console (void)
 #error No default console
 #endif
 }
+
+struct serial_device *default_serial_console(void) __attribute__((weak, alias("__default_serial_console")));
 #endif
 
 int serial_register (struct serial_device *dev)
-- 
1.5.3

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

* [U-Boot-Users] [PATCH RESEND] serial: Make default_serial_console() a weak function
  2007-12-27 15:57 [U-Boot-Users] [PATCH RESEND] serial: Make default_serial_console() a weak function Matthias Fuchs
@ 2008-01-09 12:29 ` Wolfgang Denk
  0 siblings, 0 replies; 2+ messages in thread
From: Wolfgang Denk @ 2008-01-09 12:29 UTC (permalink / raw)
  To: u-boot

In message <200712271657.23383.matthias.fuchs@esd-electronics.com> you wrote:
> With this patch it is possible to reimplement default_serial_console()
> in board specific code. This will be done in the upcomming PMC440
> U-Boot port. This also allows the lwmon board maintainer to
> remove the '#if !defined(CONFIG_LWMON) ...' from common/serial.c.
> 
> Signed-off-by: Matthias Fuchs <matthias.fuchs@esd-electronics.com>

Applied, thanks.

Best regards,

Wolfgang Denk

-- 
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
After Goliath's defeat, giants ceased to command respect.
- Freeman Dyson

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

end of thread, other threads:[~2008-01-09 12:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-12-27 15:57 [U-Boot-Users] [PATCH RESEND] serial: Make default_serial_console() a weak function Matthias Fuchs
2008-01-09 12:29 ` Wolfgang Denk

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox