[U-Boot] [PATCH 2/8] pxa_lcd: make lcd_enable() a weak pointer

Mike Dunn
2013-04-07T16:40:59Z

Make lcd_init() a weak pointer aliased to the current (and currently empty)
lcd_init(), so that boards can overload it if necessary. The palmtreo680 board
needs to wiggle some gpios and configure the pwm controller in order to get the
lcd and its backlight working.

Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
---
drivers/video/pxa_lcd.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/drivers/video/pxa_lcd.c b/drivers/video/pxa_lcd.c
index d5fbe7b..fd848ef 100644
--- a/drivers/video/pxa_lcd.c
+++ b/drivers/video/pxa_lcd.c
@@ -410,10 +410,14 @@ void lcd_initcolregs (void)
#endif /* LCD_MONOCHROME */

/*----------------------------------------------------------------------*/
-void lcd_enable (void)
+void __lcd_enable(void)
{
}

+void lcd_enable(void)
+ __attribute__((weak, alias("__lcd_enable")));
+
+
/************************************************************************/
/* ** PXA255 specific routines */
/************************************************************************/
--
1.7.8.6