Porting of unblank_delay devicetree setting to "i.MX6 Linux Release B2020.04 (Buildroot)"., Physical background

  • Hello,


    I want to port the unblank_delay=200 setting of "i.MX6 Linux Release B2020.04 (Buildroot)". Meanwhile i switched to using the panel-lvds devicenode. How can this be done?



    Thank you in advance.



    Greetings,


    André Wagner



    PS: What did this setting exactly on the physical level with the regulator and pwm of the backlight and the display itself? I found something already affecting this in drivers/video/backlight/pwm_bl.c

  • Yes of cause, here the decompiled devicetree where I set the delay to 20s:


    backlight_ldb {

    compatible = "regulator-fixed";

    regulator-name = "ldb-bl";

    gpio = <0x12 0x08 0x00>;

    regulator-min-microvolt = <0x325aa0>;

    regulator-max-microvolt = <0x325aa0>;

    enable-active-high;

    phandle = <0x6f>;

    };


    backlight_ldb {

    compatible = "pwm-backlight";

    power-supply = <0x6f>;

    post-pwm-on-delay-ms = <0x4e20>;

    pwms = <0x70 0x00 0x4c4b40 0x00>;

    brightness-levels = <0x00 0x01 0x05 0x0a 0x12 0x1c 0x29 0x38 0x49 0x5c 0x71 0x89 0xa3 0xc0 0xde 0xff>;

    default-brightness-level = <0x0e>;

    fb-names = "ldb0\0ldb1";

    phandle = <0x73>;

    };


    panel-lvds0 {

    compatible = "panel-lvds";

    data-mapping = "vesa-24";

    width-mm = <0x9a>;

    height-mm = <0x56>;

    backlight = <0x73>;

    power-supply = <0x03>;


    panel-timing {

    clock-frequency = <0x25f4cc0>;

    hactive = <0x320>;

    vactive = <0x258>;

    hback-porch = <0x58>;

    hfront-porch = <0x28>;

    hsync-len = <0x80>;

    vback-porch = <0x14>;

    vfront-porch = <0x06>;

    vsync-len = <0x02>;

    hsync-active = <0x00>;

    vsync-active = <0x00>;

    de-active = <0x01>;

    pixelclk-active = <0x00>;

    };


    port {


    endpoint {

    remote-endpoint = <0x74>;

    phandle = <0x07>;

    };

    };

    };

  • With setting the delay to 20s I see first the white flicker and then black for 20s. I looked in the pwm-backlight code in pwm_bl.c. When I understood right the delay is setting the gpio defined in its devicetree node property enable-gpio (which is not set in the armstone devicetree at all) after the delay set in node property post-pwm-on-delay-ms.


    Is it perhaps a solution to move the gpio node of regulator fixed to pwm-backlight enable-gpio?

    So switching from gpio->regulator->backlight to gpio->backlight?


    Greetings,

    André Wagner