* [PATCH] staging: panel: fix lcd type
@ 2015-03-24 4:48 Sudip Mukherjee
2015-03-24 7:04 ` Willy Tarreau
0 siblings, 1 reply; 4+ messages in thread
From: Sudip Mukherjee @ 2015-03-24 4:48 UTC (permalink / raw)
To: Willy Tarreau, Greg Kroah-Hartman; +Cc: Sudip Mukherjee, devel, linux-kernel
the lcd type as defined in the Kconfig is not matching in the code.
as a result the rs, rw and en pins were getting interchanged.
Kconfig defines the value of PANEL_LCD to be 1 if we select custom
configuration but in the code LCD_TYPE_CUSTOM is defined as 5.
my hardware is LCD_TYPE_CUSTOM, but the pins were assigned to it
as pins of LCD_TYPE_OLD, and it was not working.
Now values are corrected with referenece to the values defined in
Kconfig and it is working.
checked on JHD204A lcd with LCD_TYPE_CUSTOM configuration.
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
---
I traced the code till 2.6.32.2 and it was same problem in lcd_init(),
it can work only if we have configured for custom lcd type with
connections similar to the connections of LCD_TYPE_OLD.
drivers/staging/panel/panel.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/panel/panel.c b/drivers/staging/panel/panel.c
index 16fee49..4ffff2e 100644
--- a/drivers/staging/panel/panel.c
+++ b/drivers/staging/panel/panel.c
@@ -314,11 +314,11 @@ static unsigned char lcd_bits[LCD_PORTS][LCD_BITS][BIT_STATES];
* LCD types
*/
#define LCD_TYPE_NONE 0
-#define LCD_TYPE_OLD 1
-#define LCD_TYPE_KS0074 2
-#define LCD_TYPE_HANTRONIX 3
-#define LCD_TYPE_NEXCOM 4
-#define LCD_TYPE_CUSTOM 5
+#define LCD_TYPE_CUSTOM 1
+#define LCD_TYPE_OLD 2
+#define LCD_TYPE_KS0074 3
+#define LCD_TYPE_HANTRONIX 4
+#define LCD_TYPE_NEXCOM 5
/*
* keypad types
--
1.8.1.2
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] staging: panel: fix lcd type
2015-03-24 4:48 [PATCH] staging: panel: fix lcd type Sudip Mukherjee
@ 2015-03-24 7:04 ` Willy Tarreau
2015-03-24 7:52 ` Sudip Mukherjee
0 siblings, 1 reply; 4+ messages in thread
From: Willy Tarreau @ 2015-03-24 7:04 UTC (permalink / raw)
To: Sudip Mukherjee; +Cc: Greg Kroah-Hartman, devel, linux-kernel
Hi Sudip!
On Tue, Mar 24, 2015 at 10:18:10AM +0530, Sudip Mukherjee wrote:
> the lcd type as defined in the Kconfig is not matching in the code.
> as a result the rs, rw and en pins were getting interchanged.
> Kconfig defines the value of PANEL_LCD to be 1 if we select custom
> configuration but in the code LCD_TYPE_CUSTOM is defined as 5.
>
> my hardware is LCD_TYPE_CUSTOM, but the pins were assigned to it
> as pins of LCD_TYPE_OLD, and it was not working.
> Now values are corrected with referenece to the values defined in
> Kconfig and it is working.
> checked on JHD204A lcd with LCD_TYPE_CUSTOM configuration.
>
> Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
OK but you also need to hange the MODULE_PARM_DESC(lcd_type) to
match these new settings. Given that this is a bug, you can even
think about adding a Cc: stable tag.
Thanks,
Willy
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] staging: panel: fix lcd type
2015-03-24 7:04 ` Willy Tarreau
@ 2015-03-24 7:52 ` Sudip Mukherjee
2015-03-24 8:34 ` Willy Tarreau
0 siblings, 1 reply; 4+ messages in thread
From: Sudip Mukherjee @ 2015-03-24 7:52 UTC (permalink / raw)
To: Willy Tarreau; +Cc: Greg Kroah-Hartman, devel, linux-kernel
On Tue, Mar 24, 2015 at 08:04:11AM +0100, Willy Tarreau wrote:
> Hi Sudip!
>
> On Tue, Mar 24, 2015 at 10:18:10AM +0530, Sudip Mukherjee wrote:
> > the lcd type as defined in the Kconfig is not matching in the code.
> > as a result the rs, rw and en pins were getting interchanged.
> > Kconfig defines the value of PANEL_LCD to be 1 if we select custom
> > configuration but in the code LCD_TYPE_CUSTOM is defined as 5.
> >
> > my hardware is LCD_TYPE_CUSTOM, but the pins were assigned to it
> > as pins of LCD_TYPE_OLD, and it was not working.
> > Now values are corrected with referenece to the values defined in
> > Kconfig and it is working.
> > checked on JHD204A lcd with LCD_TYPE_CUSTOM configuration.
> >
> > Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
>
> OK but you also need to hange the MODULE_PARM_DESC(lcd_type) to
> match these new settings. Given that this is a bug, you can even
> think about adding a Cc: stable tag.
i missed seeing that MODULE_PARM_DESC. i wanted to have your
confirmation first before ccing stable.
will cc stable in v2.
but before that i think i need to read the Documentation about how to
cc stable for those many stable versions till 2.6.32
regards
sudip
>
> Thanks,
> Willy
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] staging: panel: fix lcd type
2015-03-24 7:52 ` Sudip Mukherjee
@ 2015-03-24 8:34 ` Willy Tarreau
0 siblings, 0 replies; 4+ messages in thread
From: Willy Tarreau @ 2015-03-24 8:34 UTC (permalink / raw)
To: Sudip Mukherjee; +Cc: Greg Kroah-Hartman, devel, linux-kernel
On Tue, Mar 24, 2015 at 01:22:16PM +0530, Sudip Mukherjee wrote:
> On Tue, Mar 24, 2015 at 08:04:11AM +0100, Willy Tarreau wrote:
> > Hi Sudip!
> >
> > On Tue, Mar 24, 2015 at 10:18:10AM +0530, Sudip Mukherjee wrote:
> > > the lcd type as defined in the Kconfig is not matching in the code.
> > > as a result the rs, rw and en pins were getting interchanged.
> > > Kconfig defines the value of PANEL_LCD to be 1 if we select custom
> > > configuration but in the code LCD_TYPE_CUSTOM is defined as 5.
> > >
> > > my hardware is LCD_TYPE_CUSTOM, but the pins were assigned to it
> > > as pins of LCD_TYPE_OLD, and it was not working.
> > > Now values are corrected with referenece to the values defined in
> > > Kconfig and it is working.
> > > checked on JHD204A lcd with LCD_TYPE_CUSTOM configuration.
> > >
> > > Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
> >
> > OK but you also need to hange the MODULE_PARM_DESC(lcd_type) to
> > match these new settings. Given that this is a bug, you can even
> > think about adding a Cc: stable tag.
> i missed seeing that MODULE_PARM_DESC. i wanted to have your
> confirmation first before ccing stable.
>
> will cc stable in v2.
> but before that i think i need to read the Documentation about how to
> cc stable for those many stable versions till 2.6.32
Just put this before your signed-off-by at the bottom fo the commit message :
Cc: <stable@vger.kernel.org> # 2.6.32+
Willy
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-03-24 8:34 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-24 4:48 [PATCH] staging: panel: fix lcd type Sudip Mukherjee
2015-03-24 7:04 ` Willy Tarreau
2015-03-24 7:52 ` Sudip Mukherjee
2015-03-24 8:34 ` Willy Tarreau
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.