Re: Backlight control broken on UM325 (OLED) on 5.15 (bisected)
From: Alex Deucher
Date: Mon Nov 15 2021 - 10:45:47 EST
On Mon, Nov 15, 2021 at 2:35 AM Samuel Čavoj <samuel@xxxxxxxxx> wrote:
>
> Hello,
>
> the backlight control no longer works on my ASUS UM325 (Ryzen 5700U)
> OLED laptop. I have bisected the breakage to commit 7fd13baeb7a3a48.
>
> commit 7fd13baeb7a3a48cae12c36c52f06bf4e9e7d728 (HEAD, refs/bisect/bad)
> Author: Alex Deucher <alexander.deucher@xxxxxxx>
> Date: Thu Jul 8 16:31:10 2021 -0400
>
> drm/amdgpu/display: add support for multiple backlights
>
> On platforms that support multiple backlights, register
> each one separately. This lets us manage them independently
> rather than registering a single backlight and applying the
> same settings to both.
>
> v2: fix typo:
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
>
> Reviewed-by: Roman Li <Roman.Li@xxxxxxx>
> Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx>
>
> I have encountered another user with the same issue on reddit[0].
>
> The node in /sys/class/backlight exists, writing to it just does
> nothing. I would be glad to help debugging the issue. Thank you very
> much.
That patch adds support for systems with multiple backlights. Do you
have multiple backlight devices now? If so, does the other one work?
Can you also try this patch?
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c
b/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c
index 4811b0faafd9..67163c9d49e6 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c
@@ -854,8 +854,8 @@ int amdgpu_acpi_init(struct amdgpu_device *adev)
if (amdgpu_device_has_dc_support(adev)) {
#if defined(CONFIG_DRM_AMD_DC)
struct amdgpu_display_manager *dm = &adev->dm;
- if (dm->backlight_dev[0])
- atif->bd = dm->backlight_dev[0];
+ if (dm->backlight_dev[1])
+ atif->bd = dm->backlight_dev[1];
#endif
} else {
struct drm_encoder *tmp;
Alex
>
> Regards,
> Samuel Čavoj
>
> [0]: https://www.reddit.com/r/AMDLaptops/comments/qst0fm/after_updating_to_linux_515_my_brightness/