diff --git a/dtsi.py b/dtsi.py index e82dceb..9e08275 100644 --- a/dtsi.py +++ b/dtsi.py @@ -35,6 +35,10 @@ def generate_panel_dtsi(p: Panel, options: Options) -> None: ''') f.write(f'''\ &mdss_dsi0 {{ + pinctrl-0 = <&mdss_default>; + pinctrl-1 = <&mdss_sleep>; + pinctrl-names = "default", "sleep"; + panel@0 {{ compatible = "{options.compatible}"; reg = <0>; @@ -68,4 +72,22 @@ def generate_panel_dtsi(p: Panel, options: Options) -> None: &mdss_dsi0_phy { phy-type = ; }; +''') + + f.write(''' +&tlmm { + mdss_default: mdss-default-state { + pins = "gpioXY"; + function = "gpio"; + drive-strength = <8>; + bias-disable; + }; + + mdss_sleep: mdss-sleep-state { + pins = "gpioXY"; + function = "gpio"; + drive-strength = <2>; + bias-pull-down; + }; +}; ''')