drm/amd/display: Fix OLED brightness control on eDP
authorRoman Li <Roman.Li@amd.com>
Wed, 17 Nov 2021 15:05:36 +0000 (10:05 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 18 Nov 2021 03:27:51 +0000 (22:27 -0500)
commitdab60582685aabdae2d4ff7ce716456bd0dc7a0f
treef7faae71b30e3647d339ac63640989f8e5f52c55
parentbe83a5676767c99c2417083c29d42aa1e109a69d
drm/amd/display: Fix OLED brightness control on eDP

[Why]
After commit ("drm/amdgpu/display: add support for multiple backlights")
number of eDPs is defined while registering backlight device.
However the panel's extended caps get updated once before register call.
That leads to regression with extended caps like oled brightness control.

[How]
Update connector ext caps after register_backlight_device

Fixes: 7fd13baeb7a3a4 ("drm/amdgpu/display: add support for multiple backlights")
Link: https://www.reddit.com/r/AMDLaptops/comments/qst0fm/after_updating_to_linux_515_my_brightness/
Signed-off-by: Roman Li <Roman.Li@amd.com>
Tested-by: Samuel Čavoj <samuel@cavoj.net>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Jasdeep Dhillon <Jasdeep.Dhillon@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c