Skip to content

Commit 7230362

Browse files
committed
drm/amdgpu/display: restore the backlight on modeset (v2)
To stay consistent with the user's setting. v2: rebase on multi-eDP support Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/1337 Reviewed-by: Harry Wentland <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
1 parent 3d6c916 commit 7230362

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9093,6 +9093,12 @@ static void amdgpu_dm_atomic_commit_tail(struct drm_atomic_state *state)
90939093
/* Update audio instances for each connector. */
90949094
amdgpu_dm_commit_audio(dev, state);
90959095

9096+
#if defined(CONFIG_BACKLIGHT_CLASS_DEVICE) || \
9097+
defined(CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE)
9098+
/* restore the backlight level */
9099+
if (dm->backlight_dev)
9100+
amdgpu_dm_backlight_set_level(dm, dm->brightness[0]);
9101+
#endif
90969102
/*
90979103
* send vblank event on all events not handled in flip and
90989104
* mark consumed event for drm_atomic_helper_commit_hw_done

0 commit comments

Comments
 (0)