Message ID | 20190603210601.30857-6-igor.opaniuk@gmail.com |
---|---|
State | Accepted |
Commit | a589107d4fa80143acfcb5188b40d58fe6a885fe |
Delegated to: | Anatolij Gustschin |
Headers | show |
Series | Convert mxsfb to DM_VIDEO | expand |
Hi Igor, On Mon, Jun 3, 2019 at 6:06 PM Igor Opaniuk <igor.opaniuk@gmail.com> wrote: > +&lcdif { > + u-boot,dm-pre-reloc; > + status = "okay"; > + > + display-timings { > + native-mode = <&timing_vga>; > + > + /* Standard VGA timing */ > + timing_vga: 640x480 { > + u-boot,dm-pre-reloc; > + clock-frequency = <25175000>; > + hactive = <640>; > + vactive = <480>; > + hback-porch = <48>; > + hfront-porch = <16>; > + vback-porch = <33>; > + vfront-porch = <10>; > + hsync-len = <96>; > + vsync-len = <2>; > + > + de-active = <1>; > + hsync-active = <0>; > + vsync-active = <0>; > + pixelclk-active = <0> This is the deprecated style mxsfb fbdev binding. In the kernel we no longer use this style as documented in Documentation/devicetree/bindings/display/mxsfb.txt If we follow this route in U-Boot then we will diverge from the kernel recommended bindings.
Hi Fabio, On Wed, Jun 5, 2019 at 1:06 AM Fabio Estevam <festevam@gmail.com> wrote: > > Hi Igor, > > On Mon, Jun 3, 2019 at 6:06 PM Igor Opaniuk <igor.opaniuk@gmail.com> wrote: > > > +&lcdif { > > + u-boot,dm-pre-reloc; > > + status = "okay"; > > + > > + display-timings { > > + native-mode = <&timing_vga>; > > + > > + /* Standard VGA timing */ > > + timing_vga: 640x480 { > > + u-boot,dm-pre-reloc; > > + clock-frequency = <25175000>; > > + hactive = <640>; > > + vactive = <480>; > > + hback-porch = <48>; > > + hfront-porch = <16>; > > + vback-porch = <33>; > > + vfront-porch = <10>; > > + hsync-len = <96>; > > + vsync-len = <2>; > > + > > + de-active = <1>; > > + hsync-active = <0>; > > + vsync-active = <0>; > > + pixelclk-active = <0> > > This is the deprecated style mxsfb fbdev binding. > > In the kernel we no longer use this style as documented in > Documentation/devicetree/bindings/display/mxsfb.txt > > If we follow this route in U-Boot then we will diverge from the kernel > recommended bindings. Initially I copy-pasted the whole DT node "as it is" from the linux kernel dts, but found out that existing DT wrapper for parsing display timings (ofnode_decode_display_timing())) isn't able to parse it properly, so I just changed it to conform the same structure as similar nodes in other DTS files. Thanks for letting me know, probably ofnode_decode_display_timing() implementation should be adjusted as well. Regards, Igor
Hi Fabio, On Wed, Jun 5, 2019 at 4:29 PM Igor Opaniuk <igor.opaniuk@gmail.com> wrote: > > Hi Fabio, > > On Wed, Jun 5, 2019 at 1:06 AM Fabio Estevam <festevam@gmail.com> wrote: > > > > Hi Igor, > > > > On Mon, Jun 3, 2019 at 6:06 PM Igor Opaniuk <igor.opaniuk@gmail.com> wrote: > > > > > +&lcdif { > > > + u-boot,dm-pre-reloc; > > > + status = "okay"; > > > + > > > + display-timings { > > > + native-mode = <&timing_vga>; > > > + > > > + /* Standard VGA timing */ > > > + timing_vga: 640x480 { > > > + u-boot,dm-pre-reloc; > > > + clock-frequency = <25175000>; > > > + hactive = <640>; > > > + vactive = <480>; > > > + hback-porch = <48>; > > > + hfront-porch = <16>; > > > + vback-porch = <33>; > > > + vfront-porch = <10>; > > > + hsync-len = <96>; > > > + vsync-len = <2>; > > > + > > > + de-active = <1>; > > > + hsync-active = <0>; > > > + vsync-active = <0>; > > > + pixelclk-active = <0> > > > > This is the deprecated style mxsfb fbdev binding. > > > > In the kernel we no longer use this style as documented in > > Documentation/devicetree/bindings/display/mxsfb.txt > > > > If we follow this route in U-Boot then we will diverge from the kernel > > recommended bindings. > > Initially I copy-pasted the whole DT node "as it is" from the linux > kernel dts, but found out that existing > DT wrapper for parsing display timings > (ofnode_decode_display_timing())) isn't able to parse it properly, > so I just changed it to conform the same structure as similar nodes in > other DTS files. > > Thanks for letting me know, probably ofnode_decode_display_timing() > implementation should > be adjusted as well. Nevermind, I've double-checked ofnode_decode_display_timing() implementation and all instances of display-timings nodes, it definitely should be able parse the same structure as defined in the Linux devicetree bindings. Probably I just messed up with something. > Regards, > Igor > > > > -- > Best regards - Freundliche GrĂ¼sse - Meilleures salutations > > Igor Opaniuk > > mailto: igor.opaniuk@gmail.com > skype: igor.opanyuk > +380 (93) 836 40 67 > http://ua.linkedin.com/in/iopaniuk
diff --git a/arch/arm/dts/imx7-colibri-emmc.dts b/arch/arm/dts/imx7-colibri-emmc.dts index efd600091d..8db2a62707 100644 --- a/arch/arm/dts/imx7-colibri-emmc.dts +++ b/arch/arm/dts/imx7-colibri-emmc.dts @@ -11,8 +11,10 @@ compatible = "toradex,imx7d-colibri-emmc", "fsl,imx7d"; aliases { + u-boot,dm-pre-reloc; mmc0 = &usdhc3; mmc1 = &usdhc1; + display1 = &lcdif; }; chosen { diff --git a/arch/arm/dts/imx7-colibri.dtsi b/arch/arm/dts/imx7-colibri.dtsi index a85702f519..81717c233d 100644 --- a/arch/arm/dts/imx7-colibri.dtsi +++ b/arch/arm/dts/imx7-colibri.dtsi @@ -111,3 +111,31 @@ >; }; }; + +&lcdif { + u-boot,dm-pre-reloc; + status = "okay"; + + display-timings { + native-mode = <&timing_vga>; + + /* Standard VGA timing */ + timing_vga: 640x480 { + u-boot,dm-pre-reloc; + clock-frequency = <25175000>; + hactive = <640>; + vactive = <480>; + hback-porch = <48>; + hfront-porch = <16>; + vback-porch = <33>; + vfront-porch = <10>; + hsync-len = <96>; + vsync-len = <2>; + + de-active = <1>; + hsync-active = <0>; + vsync-active = <0>; + pixelclk-active = <0>; + }; + }; +};