2020-08-19 10:13:47

by Lubomir Rintel

[permalink] [raw]
Subject: [PATCH 0/2] drm/panel: Add support for Innolux LS075AT011

Hi,

Please take a look at the patches chanied to this message and consider
applying them. They add description of the display panel found on OLPC
laptops to the simple panel driver.

There is no datasheet for the hardware and thus the timings were
determined on a best effort basis. The clock range is gotten from the
data sheet of the display controller [1] and the other timings are what
OLPC laptops actually use. The panel seems to cope with different sync
timings, but I'm not sure wherher there's any value in attempting to
figure out what range is actually permissible.

I could not figure out the right definitions for the connector and the
bus format. I'm not sure how necessary they are, but at least the
drm-panel driver insists on connector type being defined so I picked
LVDS because that seems to be used for internal laptop screens.

The signalling is not actually differential. It uses TTL levels with
data sampled on rising and falling clock edges; sort of like this (taken
from [1], P.20):

__
FSTH / \_______________________________________
____ ____ ____ ____ __
FCLK / \____/ \____/ \____/ \____/
____ ____ ____ ____ ____ ____ ____
FD00 ........X____X____X____X____X____X____X____
____ ____ ____ ____ ____ ____ ____
FD01 ........X____X____X____X____X____X____X____
____ ____ ____ ____ ____ ____ ____
FD10 ........X____X____X____X____X____X____X____
____ ____ ____ ____ ____ ____ ____
FD11 ........X____X____X____X____X____X____X____
____ ____ ____ ____ ____ ____ ____
FD20 ........X____X____X____X____X____X____X____
____ ____ ____ ____ ____ ____ ____
FD21 ........X____X____X____X____X____X____X____
| | | |
data 1 data 2 ...
(2x6bit) (2x6bit)

I believe the data just carries brightness because each pixel on the
panel has a fixed color; with the red, green and blue pixels organized
in a pattern [2]. (The HX8837 that drives the color does the conversion
from RGB).

Tested on an OLPC XO-1.75 laptop. XO-1 and XO-1.5 use the same hardware,
but their display controllers are not supported by DRM at the moment.

[1] http://wiki.laptop.org/images/0/09/DCON_datasheet_HX8837-A.pdf
[2] http://wiki.laptop.org/go/Display

Thank you!
Lubo



2020-08-19 10:14:08

by Lubomir Rintel

[permalink] [raw]
Subject: [PATCH 2/2] drm/panel: simple: Add support for Innolux LS075AT011

This adds support for the Innolux LS075AT011 7.5" 1200x900 panel. There's
no public data sheet for the panel -- the values have been taken from Open
Firmware and the documentation for the display controller that drives
the panel and tested on the OLPC laptop.

Signed-off-by: Lubomir Rintel <[email protected]>
---
drivers/gpu/drm/panel/panel-simple.c | 27 +++++++++++++++++++++++++++
1 file changed, 27 insertions(+)

diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/panel/panel-simple.c
index cb6550d37e858..dfc69457ed2d4 100644
--- a/drivers/gpu/drm/panel/panel-simple.c
+++ b/drivers/gpu/drm/panel/panel-simple.c
@@ -2121,6 +2121,30 @@ static const struct panel_desc innolux_g121x1_l03 = {
},
};

+static const struct display_timing innolux_ls075at011_timing = {
+ .pixelclock = { 56000000, 57000000, 58000000 },
+ .hactive = { 1200, 1200, 1200 },
+ .hfront_porch = { 26, 26, 26 },
+ .hback_porch = { 24, 24, 24 },
+ .hsync_len = { 6, 6, 6 },
+ .vactive = { 900, 900, 900 },
+ .vfront_porch = { 4, 4, 4 },
+ .vback_porch = { 5, 5, 5 },
+ .vsync_len = { 3, 3, 3 },
+ .flags = DISPLAY_FLAGS_VSYNC_LOW | DISPLAY_FLAGS_HSYNC_LOW,
+};
+
+static const struct panel_desc innolux_ls075at011 = {
+ .timings = &innolux_ls075at011_timing,
+ .num_timings = 1,
+ .bpc = 8,
+ .size = {
+ .width = 152,
+ .height = 115,
+ },
+ .connector_type = DRM_MODE_CONNECTOR_LVDS,
+};
+
/*
* Datasheet specifies that at 60 Hz refresh rate:
* - total horizontal time: { 1506, 1592, 1716 }
@@ -3907,6 +3931,9 @@ static const struct of_device_id platform_of_match[] = {
}, {
.compatible = "innolux,g121x1-l03",
.data = &innolux_g121x1_l03,
+ }, {
+ .compatible = "innolux,ls075at011",
+ .data = &innolux_ls075at011,
}, {
.compatible = "innolux,n116bge",
.data = &innolux_n116bge,
--
2.26.2

2020-08-19 10:16:27

by Lubomir Rintel

[permalink] [raw]
Subject: [PATCH 1/2] dt-bindings: display: simple: add Innolux LS075AT011

Add the Innolux LS075AT011 7.5" (1200x900) color/reflective LCD panel to
the panel-simple compatible list. This panel is used in the OLPC laptops.

Signed-off-by: Lubomir Rintel <[email protected]>
---
.../devicetree/bindings/display/panel/panel-simple.yaml | 2 ++
1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml b/Documentation/devicetree/bindings/display/panel/panel-simple.yaml
index 6deeeed59e59f..cad63a639e258 100644
--- a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml
+++ b/Documentation/devicetree/bindings/display/panel/panel-simple.yaml
@@ -153,6 +153,8 @@ properties:
- innolux,g121i1-l01
# Innolux Corporation 12.1" G121X1-L03 XGA (1024x768) TFT LCD panel
- innolux,g121x1-l03
+ # Innolux LS075AT011 7.5" (1200x900) color/reflective LCD panel
+ - innolux,ls075at011
# Innolux Corporation 11.6" WXGA (1366x768) TFT LCD panel
- innolux,n116bge
# InnoLux 15.6" WXGA TFT LCD panel
--
2.26.2

2020-08-25 21:54:32

by Rob Herring

[permalink] [raw]
Subject: Re: [PATCH 1/2] dt-bindings: display: simple: add Innolux LS075AT011

On Wed, 19 Aug 2020 12:12:05 +0200, Lubomir Rintel wrote:
> Add the Innolux LS075AT011 7.5" (1200x900) color/reflective LCD panel to
> the panel-simple compatible list. This panel is used in the OLPC laptops.
>
> Signed-off-by: Lubomir Rintel <[email protected]>
> ---
> .../devicetree/bindings/display/panel/panel-simple.yaml | 2 ++
> 1 file changed, 2 insertions(+)
>

Acked-by: Rob Herring <[email protected]>

2020-10-17 10:40:24

by Sam Ravnborg

[permalink] [raw]
Subject: Re: [PATCH 2/2] drm/panel: simple: Add support for Innolux LS075AT011

Hi Lubomir.

Sorry for the late feedback!

On Wed, Aug 19, 2020 at 12:12:06PM +0200, Lubomir Rintel wrote:
> This adds support for the Innolux LS075AT011 7.5" 1200x900 panel. There's
> no public data sheet for the panel -- the values have been taken from Open
> Firmware and the documentation for the display controller that drives
> the panel and tested on the OLPC laptop.
>
> Signed-off-by: Lubomir Rintel <[email protected]>
> ---
> drivers/gpu/drm/panel/panel-simple.c | 27 +++++++++++++++++++++++++++
> 1 file changed, 27 insertions(+)
>
> diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/panel/panel-simple.c
> index cb6550d37e858..dfc69457ed2d4 100644
> --- a/drivers/gpu/drm/panel/panel-simple.c
> +++ b/drivers/gpu/drm/panel/panel-simple.c
> @@ -2121,6 +2121,30 @@ static const struct panel_desc innolux_g121x1_l03 = {
> },
> };
>
> +static const struct display_timing innolux_ls075at011_timing = {
> + .pixelclock = { 56000000, 57000000, 58000000 },
> + .hactive = { 1200, 1200, 1200 },
> + .hfront_porch = { 26, 26, 26 },
> + .hback_porch = { 24, 24, 24 },
> + .hsync_len = { 6, 6, 6 },
> + .vactive = { 900, 900, 900 },
> + .vfront_porch = { 4, 4, 4 },
> + .vback_porch = { 5, 5, 5 },
> + .vsync_len = { 3, 3, 3 },
> + .flags = DISPLAY_FLAGS_VSYNC_LOW | DISPLAY_FLAGS_HSYNC_LOW,
> +};
> +
> +static const struct panel_desc innolux_ls075at011 = {
> + .timings = &innolux_ls075at011_timing,
> + .num_timings = 1,
> + .bpc = 8,
> + .size = {
> + .width = 152,
> + .height = 115,
> + },
> + .connector_type = DRM_MODE_CONNECTOR_LVDS,
> +};
For LVDS panels following info is mandatory:
.bus_flags
.bus_format

You have .bpc - so this part is OK.

See the checks in panel_simple_probe() - thay are not allowed to trigger
for any new panels.

Sam