drm/amd: Add power_saving_policy drm property to eDP connectors
authorMario Limonciello <mario.limonciello@amd.com>
Wed, 3 Jul 2024 05:17:22 +0000 (00:17 -0500)
committerHamza Mahfooz <hamza.mahfooz@amd.com>
Wed, 10 Jul 2024 21:00:07 +0000 (17:00 -0400)
commit9d8c094ddab05db88d183ba82e23be807848cad8
tree4c54622eff766634aa8bb4e0e62b869dc21017c4
parent76299a557f36d624ca32500173ad7856e1ad93c0
drm/amd: Add power_saving_policy drm property to eDP connectors

When the `power_saving_policy` property is set to bit mask
"Require color accuracy" ABM should be disabled immediately and
any requests by sysfs to update will return an -EBUSY error.

When the `power_saving_policy` property is set to bit mask
"Require low latency" PSR should be disabled.

When the property is restored to an empty bit mask ABM and PSR
can be enabled again.

Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
Reviewed-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Hamza Mahfooz <hamza.mahfooz@amd.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240703051722.328-3-mario.limonciello@amd.com
drivers/gpu/drm/amd/amdgpu/amdgpu_display.c
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h