Re: [U-Boot] [PATCH 8/8] nhk8815: added lcd support

Dear Alessandro Rubini,
In message <109a8c9f77c98641a8a02c4346cd2c7d2cc6794f.1255086085.git.rubini@ unipv.it> you wrote:
From: Alessandro Rubini rubini@unipv.it
...
+void lcd_enable(void) +{
- printf("%s:%s\n", __FILE__, __func__);
- int i;
Please no declarations in the middle of code.
And probably this should be debug() instead of printf() ?
+int nhk8815_backlight_on(void) +{
- printf("%s:%s\n", __FILE__, __func__);
- int i;
Ditto, 2x.
diff --git a/board/st/nhk8815/nhk8815.c b/board/st/nhk8815/nhk8815.c index efeb0d2..ded7681 100644 --- a/board/st/nhk8815/nhk8815.c +++ b/board/st/nhk8815/nhk8815.c @@ -107,6 +107,7 @@ int board_eth_init(bd_t *bis) #endif
extern int nhk8815_keypad_init(void); /* ./keypad.c */ +extern int nhk8815_backlight_on(void); /* in ./lcd.c */
Please move prototype decl;arations to some header file.
Best regards,
Wolfgang Denk

I'm almost done with the requested changes on this patch set, will post V2 this evening after re-running ./makeall as needed.
I've a question, though:
+extern int nhk8815_backlight_on(void); /* in ./lcd.c */
Please move prototype decl;arations to some header file.
Unfortunately, there is no suitable file. It's just that I split code related to different drivers in different files, for better housekeeping. These two are called nhk8815-something as they are board-specific anyways.
Should I create a local header file in this same board directory, with just the two prototypes? Or "ifndef __ASSEMBLY__ in the board config file is better? I'd better ask first to avoid a V3 just for this detail.
Thanks /alessandro
participants (2)
-
Alessandro Rubini
-
Wolfgang Denk