linux-mdss-dsi-panel-driver-generator icon indicating copy to clipboard operation
linux-mdss-dsi-panel-driver-generator copied to clipboard

htc: parse htc-fmt,mdss-dsi-on-command, htc-fmt,mdss-dsi-off-command

Open valerierx opened this issue 1 year ago • 3 comments

On HTC platforms that use Qualcomm SoCs, mdss_dsi_parse_dcs_cmds is not used to parse the panels init sequence, which is defined with htc-fmt,mdss-dsi-on-command, htc-fmt,mdss-dsi-off-command and htc-fmt,display-on-cmds. Replacing htc-fmt with qcom does not work and causes the following error:

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/valerie/Git/linux-mdss-dsi-panel-driver-generator/./lmdpdg.py", line 77, in <module>
    panel = Panel.parse(fdt, offset)
            ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/valerie/Git/linux-mdss-dsi-panel-driver-generator/panel.py", line 334, in parse
    return name and Panel(name.as_str(), fdt, node)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/valerie/Git/linux-mdss-dsi-panel-driver-generator/panel.py", line 273, in __init__
    'on': CommandSequence(fdt, mode_node, 'on'),
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/valerie/Git/linux-mdss-dsi-panel-driver-generator/panel.py", line 166, in __init__
    payload = bytes(next(itr) for _ in range(0, dlen))
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: generator raised StopIteration

Here are the properties called: https://github.com/rom4nik/kernel_release-a51ul-3.10.28-g1e0287c/blob/master/drivers/video/msm/mdss/mdss_dsi_panel.c#L1259

Here are the properties parsed: https://github.com/rom4nik/kernel_release-a51ul-3.10.28-g1e0287c/blob/master/drivers/video/msm/mdss/mdss_htc_util.c#L195

And here is the downstream panel DTSI: https://github.com/rom4nik/kernel_release-a51ul-3.10.28-g1e0287c/blob/master/arch/arm/boot/dts/qcom/dsi-panel-a51.dtsi

valerierx avatar Apr 22 '24 17:04 valerierx

Better link this function here https://github.com/rom4nik/kernel_release-a51ul-3.10.28-g1e0287c/blob/b3d118eff02b0a30c930bbf2a3e09e05ee5ac266/drivers/video/msm/mdss/mdss_htc_util.c#L195 ? Since this is where the property actually gets parsed by downstream.

z3ntu avatar Apr 23 '24 09:04 z3ntu

Better link this function here https://github.com/rom4nik/kernel_release-a51ul-3.10.28-g1e0287c/blob/b3d118eff02b0a30c930bbf2a3e09e05ee5ac266/drivers/video/msm/mdss/mdss_htc_util.c#L195 ? Since this is where the property actually gets parsed by downstream.

You're right, forgot to include it.

valerierx avatar Apr 23 '24 20:04 valerierx

I think this is a perfect candidate to add to #36?

MarijnS95 avatar May 16 '24 20:05 MarijnS95