Re: [PATCHv7 2/3] ARM: dts: Add support for i.MX6 UltraLite DART Variscite Customboard

From: Oliver Graute
Date: Wed Jul 08 2020 - 09:12:08 EST


On 12/11/19, Fabio Estevam wrote:
> Hi Oliver,
>
> On Tue, Nov 12, 2019 at 4:22 PM Oliver Graute <oliver.graute@xxxxxxxxx> wrote:
>
> > +&lcdif {
> > + pinctrl-names = "default";
> > + pinctrl-0 = <&pinctrl_lcdif>;
> > + display = <&display0>;
> > + status = "okay";
> > +
> > + display0: display0 {
> > + bits-per-pixel = <16>;
> > + bus-width = <24>;
> > +
> > + display-timings {
> > + native-mode = <&timing0>;
> > + timing0: timing0 {
> > + clock-frequency =<35000000>;
> > + hactive = <800>;
> > + vactive = <480>;
> > + hfront-porch = <40>;
> > + hback-porch = <40>;
> > + hsync-len = <48>;
> > + vback-porch = <29>;
> > + vfront-porch = <13>;
> > + vsync-len = <3>;
> > + hsync-active = <0>;
> > + vsync-active = <0>;
> > + de-active = <1>;
> > + pixelclk-active = <0>;
> > + };
> > + };
> > + };
> > +};
>
> You are using the deprecated bindings.
>
> Please switch to the DRM bindings as stated at
> Documentation/devicetree/bindings/display/mxsfb.txt
>
> You should also add your panel to the simple panel driver.


ok thx for you comments, coming back to this. I now added this to
panel-simple.c. Is this the way to go?

Best Regards,

Oliver

diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/panel/panel-simple.c
index c1374be..c2f20ac 100644
--- a/drivers/gpu/drm/panel/panel-simple.c
+++ b/drivers/gpu/drm/panel/panel-simple.c
@@ -3139,6 +3139,29 @@ static const struct panel_desc satoz_sat050at40h12r2 = {
.connector_type = DRM_MODE_CONNECTOR_LVDS,
};

+static const struct display_timing sgd_gktw70sdad1sd_timing = {
+ .pixelclock = {35000000, 35000000, 35000000},
+ .hactive = { 800, 800, 800},
+ .hfront_porch = {39, 39, 39},
+ .hback_porch = {39, 39, 39},
+ .hsync_len = {48, 48, 48},
+ .vactive = {480, 480, 480},
+ .vfront_porch = {13, 13, 13},
+ .vback_porch = {29, 29, 29},
+ .vsync_len = {3, 3, 3},
+};
+
+static const struct panel_desc sgd_gktw70sdad1sd = {
+ .timings = &sgd_gktw70sdad1sd_timing,
+ .num_timings = 1,
+ .bpc = 8,
+ .size = {
+ .width = 153,
+ .height = 86,
+ },
+ .connector_type = DRM_MODE_CONNECTOR_DPI,
+};
+
static const struct drm_display_mode sharp_ld_d5116z01b_mode = {
.clock = 168480,
.hdisplay = 1920,
@@ -3999,6 +4022,9 @@ static const struct of_device_id platform_of_match[] = {
.compatible = "satoz,sat050at40h12r2",
.data = &satoz_sat050at40h12r2,
}, {
+ .compatible = "sgd,gktw70sdad1sd",
+ .data = &sgd_gktw70sdad1sd,
+ }, {
.compatible = "sharp,ld-d5116z01b",