Firefly Open Source Community

   Login   |   Register   |
New_Topic
Print Previous Topic Next Topic

[Linux] Kernel 5.x, LVDS, rockchipdrm problem

73

Credits

0

Prestige

0

Contribution

registered members

Rank: 2

Credits
73

【Linux】 Kernel 5.x, LVDS, rockchipdrm problem

Posted at 2/9/2020 09:46:18      View:5481 | Replies:2        Print      Only Author   [Copy Link] 1#
Hello! Has anyone tried to run the 5.x kernel with lvds panel support? I can't get lvds to work ( I have enabled lvds in DT, but when rockchipdrm module is loading I get this messages:

  1. [   29.355853] rockchip-vop ff930000.vop: Adding to iommu group 0
  2. [   29.362659] rockchip-vop ff940000.vop: Adding to iommu group 1
  3. [   29.371731] rockchip-drm display-subsystem: bound ff930000.vop (ops vop_component_ops [rockchipdrm])
  4. [   29.382206] rockchip-drm display-subsystem: bound ff940000.vop (ops vop_component_ops [rockchipdrm])
  5. [   29.392482] rockchip-lvds ff96c000.lvds: [drm:rockchip_lvds_bind [rockchipdrm]] *ERROR* failed to find panel and bridge node
  6. [   29.405058] rockchip-drm display-subsystem: failed to bind ff96c000.lvds (ops rockchip_lvds_component_ops [rockchipdrm]): -517
  7. [   29.417924] rockchip-drm display-subsystem: master bind failed: -517
Copy the code


DTS:
  1.        
  2. / {
  3. ...
  4. lvds_panel: lvds-panel {
  5.                 compatible = "simple-panel";
  6.                 enable-gpios = <&gpio7 3 GPIO_ACTIVE_HIGH>;
  7.                 bus-format = <0x1009>;
  8.                 rockchip,data-mapping = "vesa";
  9.                 rockchip,data-width = <24>;
  10.                 rockchip,output = "lvds";
  11.                 status = "okay";

  12.                 display-timings {
  13.                         native-mode = <&timing0>;

  14.                         timing0: timing0 {
  15.                                 clock-frequency = <85000000>;
  16.                                 hactive = <1280>;
  17.                                 vactive = <480>;
  18.                                 hback-porch = <24>;
  19.                                 hfront-porch = <368>;
  20.                                 vback-porch = <9>;
  21.                                 vfront-porch = <33>;
  22.                                 hsync-len = <16>;
  23.                                 vsync-len = <3>;
  24.                                 hsync-active = <0>;
  25.                                 vsync-active = <0>;
  26.                                 de-active = <0>;
  27.                                 pixelclk-active = <0>;
  28.                         };
  29.                 };

  30.                 ports {
  31.                         port {
  32.                                 panel_in_lvds: endpoint {
  33.                                         remote-endpoint = <&lvds_out_panel>;
  34.                                 };
  35.                         };
  36.                 };
  37.         };
  38. ...
  39. };

  40. &lvds {
  41.         rockchip,output = "lvds";
  42.         rockchip,panel = <&lvds_panel>;
  43.         status = "okay";

  44.         ports {
  45.                 lvds_out: port@1 {
  46.                         reg = <1>;

  47.                         #address-cells = <1>;
  48.                         #size-cells = <0>;

  49.                         lvds_out_panel: endpoint@0 {
  50.                                 reg = <0>;
  51.                                 remote-endpoint = <&panel_in_lvds>;
  52.                         };
  53.                 };
  54.         };
  55. };
Copy the code
Reply

Use props Report

14

Credits

0

Prestige

0

Contribution

new registration

Rank: 1

Credits
14
Posted at 4/23/2021 09:20:47        Only Author  2#
可能原因:
1.dts配置节点里面compatible = "panel-simple";这个没有起到作用;
2.由于enable-gpios 配置错误或者被其他节点占用;
3.没有配置背光节点。
Reply

Use props Report

14

Credits

0

Prestige

0

Contribution

new registration

Rank: 1

Credits
14
Posted at 4/23/2021 09:27:03        Only Author  3#
举例(平台RK3326+Linux 4.4):
backlight: backlight {
                compatible = "pwm-backlight";
                pwms = <&pwm1 0 25000 0>;
                brightness-levels = <
                          0   1   2   3   4   5   6   7
                        (省略N行)
                        248 249 250 251 252 253 254 255>;
                default-brightness-level = <200>;
                enable-gpios = <&gpio3 RK_PC0 GPIO_ACTIVE_HIGH>;
        };

panel {
                status = "okay";
                compatible = "simple-panel";
                backlight = <&backlight>;
                power-supply = <&vcc_3v0>;
                init-delay-ms = <20>;

                enable-delay-ms = <20>;
                prepare-delay-ms = <20>;
                unprepare-delay-ms = <20>;
                disable-delay-ms = <20>;
                bus-format = <MEDIA_BUS_FMT_RGB888_1X7X4_SPWG>;
                enable-gpios = <&gpio3 RK_PB5 GPIO_ACTIVE_HIGH>;
                standby-gpios = <&gpio3 RK_PB6 GPIO_ACTIVE_HIGH>;
                reset-gpios = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>;
                width-mm = <217>;
                height-mm = <136>;
                rockchip,output = "lvds";

                display-timings {
                        native-mode = <&timing0>;

                        timing0: timing0 {
                                clock-frequency = <46000000>;
                                hactive = <1024>;
                                vactive = <600>;
                                hback-porch = <90>;
                                hfront-porch = <160>;
                                vback-porch = <13>;
                                vfront-porch = <12>;
                                hsync-len = <70>;
                                vsync-len = <10>;
                                hsync-active = <0>;
                                vsync-active = <0>;
                                de-active = <0>;
                                pixelclk-active = <0>;

                        };
                };

                port {
                        panel_in_lvds: endpoint {
                                remote-endpoint = <&lvds_out_panel>;
                        };
                };

        };
Reply

Use props Report

You need to log in before you can reply Login | Register

This forum Credits Rules

Quick Reply Back to top Back to list