* [PATCH] Fix compilation error of drivers/staging/panel/panel.c w/ custom lcd charset
@ 2009-12-15 5:21 Peter Huewe
2009-12-15 21:19 ` Willy Tarreau
0 siblings, 1 reply; 2+ messages in thread
From: Peter Huewe @ 2009-12-15 5:21 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: devel, Willy Tarreau, Sudhakar Rajashekhara, Costantino Leandro,
linux-kernel, Peter Huewe
When compiling panel.c with a DEFAULT_LCD_CHARSET it fails to compile
with the following error message:
drivers/staging/panel/panel.c: In function >>lcd_init<<:
drivers/staging/panel/panel.c:1396: error: expected expression before
>>;<< token
drivers/staging/panel/panel.c:1475: error: expected expression before
>>;<< token
make[3]: *** [drivers/staging/panel/panel.o] error 1
make[2]: *** [drivers/staging/panel] error 2
make[1]: *** [drivers/staging] error 2
The config used was:
CONFIG_PANEL=m
CONFIG_PANEL_PARPORT=0
CONFIG_PANEL_PROFILE=0
CONFIG_PANEL_KEYPAD=0
CONFIG_PANEL_LCD=1
CONFIG_PANEL_LCD_HEIGHT=2
CONFIG_PANEL_LCD_WIDTH=20
CONFIG_PANEL_LCD_BWIDTH=40
CONFIG_PANEL_LCD_HWIDTH=64
CONFIG_PANEL_LCD_CHARSET=0
CONFIG_PANEL_LCD_PROTO=0
CONFIG_PANEL_LCD_PIN_E=14
CONFIG_PANEL_LCD_PIN_RS=17
CONFIG_PANEL_LCD_PIN_RW=16
CONFIG_PANEL_LCD_PIN_BL=0
This patch fixes both errors, as it fixes the define
Patch against current linux-next tree at Tue Dec 15 06:07:01 2009 +0100
Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
---
drivers/staging/panel/panel.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/staging/panel/panel.c b/drivers/staging/panel/panel.c
index f98a524..95c93e8 100644
--- a/drivers/staging/panel/panel.c
+++ b/drivers/staging/panel/panel.c
@@ -378,7 +378,7 @@ static unsigned char lcd_bits[LCD_PORTS][LCD_BITS][BIT_STATES];
#ifdef CONFIG_PANEL_LCD_CHARSET
#undef DEFAULT_LCD_CHARSET
-#define DEFAULT_LCD_CHARSET
+#define DEFAULT_LCD_CHARSET CONFIG_PANEL_LCD_CHARSET
#endif
#endif /* DEFAULT_PROFILE == 0 */
--
1.6.4.4
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] Fix compilation error of drivers/staging/panel/panel.c w/ custom lcd charset
2009-12-15 5:21 [PATCH] Fix compilation error of drivers/staging/panel/panel.c w/ custom lcd charset Peter Huewe
@ 2009-12-15 21:19 ` Willy Tarreau
0 siblings, 0 replies; 2+ messages in thread
From: Willy Tarreau @ 2009-12-15 21:19 UTC (permalink / raw)
To: Peter Huewe
Cc: Greg Kroah-Hartman, devel, Sudhakar Rajashekhara,
Costantino Leandro, linux-kernel
On Tue, Dec 15, 2009 at 06:21:45AM +0100, Peter Huewe wrote:
> When compiling panel.c with a DEFAULT_LCD_CHARSET it fails to compile
> with the following error message:
> drivers/staging/panel/panel.c: In function >>lcd_init<<:
> drivers/staging/panel/panel.c:1396: error: expected expression before
> >>;<< token
> drivers/staging/panel/panel.c:1475: error: expected expression before
> >>;<< token
> make[3]: *** [drivers/staging/panel/panel.o] error 1
> make[2]: *** [drivers/staging/panel] error 2
> make[1]: *** [drivers/staging] error 2
(...)
> #ifdef CONFIG_PANEL_LCD_CHARSET
> #undef DEFAULT_LCD_CHARSET
> -#define DEFAULT_LCD_CHARSET
> +#define DEFAULT_LCD_CHARSET CONFIG_PANEL_LCD_CHARSET
> #endif
Wow! I don't understand how this managed to slip through the various
tests for that long. That code is the the same in my 2.4 driver too,
so that means it has never worked for the last 5 years !
Obvious ACK from me, but please take a quick look at the place
where this define is used to ensure that any expected setting of
CONFIG_PANEL_LCD_CHARSET will not result in some other cryptic
error messages being sent to the user.
Thanks!
Willy
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-12-15 21:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-15 5:21 [PATCH] Fix compilation error of drivers/staging/panel/panel.c w/ custom lcd charset Peter Huewe
2009-12-15 21:19 ` Willy Tarreau
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®