Hello Wolfgang,
On 21.04.20 16:50, Wolfgang Kamp - datakamp wrote:
I found out that the panel backlight enable function in libgfxinit for Broxton platform (Intel x5-E3940) will not work for me. The Backlight Enabling Sequence Description in the Intel document Doc Ref # IHD-OS-BXT-Vol 7-05.17 says:
- Set frequency and duty cycle in BLC_PWM_FREQ Frequency and BLC_PWM_DUTY Duty Cycle.
- Enable PWM output and set polarity in BLC_PWM_CTL PWM Enable and PWM Polarity.
It is also necessary to set Bit 2 in the PP_CONTROL register to "1" to enable Backlight Power.
did you confirm this additional step by testing? I have only tested one board so far. It uses the second set of panel registers and I can control the PWM output just fine _without_ touching PP_CONTROL.
In "hw-gfx-gma-panel.adb" in the function Backlight_On only BXT_BLC_PWM_CTL_ENABLE will be set and PP_CONTROL setting is excluded through the If statement. Also I can't find any call of the Set_Backlight function and I'm missing the setting of the PWM frequency divider in this function. Most panels will work with 200Hz PWM.
`libgfxinit` is not designed as firmware and expects that board/panel specific settings are already performed by the firmware. I have just pushed a patch [1] to add the missing configuration in coreboot. It needs to be configured in the devicetree.
Hope that helps, Nico