summaryrefslogtreecommitdiff
path: root/include/drm
diff options
context:
space:
mode:
authorMario Limonciello <mario.limonciello@amd.com>2024-07-03 00:17:21 -0500
committerHamza Mahfooz <hamza.mahfooz@amd.com>2024-07-10 16:58:19 -0400
commit76299a557f36d624ca32500173ad7856e1ad93c0 (patch)
tree0b115f5017673d31401aca98cd5610a10528089f /include/drm
parent0e7f4e6a20d550252c4f355d5a303b1d9c8ff052 (diff)
drm: Introduce 'power saving policy' drm property
The `power saving policy` DRM property is an optional property that can be added to a connector by a driver. This property is for compositors to indicate intent of policy of whether a driver can use power saving features that may compromise the experience intended by the compositor. Acked-by: Leo Li <sunpeng.li@amd.com> Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Signed-off-by: Hamza Mahfooz <hamza.mahfooz@amd.com> Link: https://patchwork.freedesktop.org/patch/msgid/20240703051722.328-2-mario.limonciello@amd.com
Diffstat (limited to 'include/drm')
-rw-r--r--include/drm/drm_connector.h2
-rw-r--r--include/drm/drm_mode_config.h5
2 files changed, 7 insertions, 0 deletions
diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h
index e3fa43291f44..5ad735253413 100644
--- a/include/drm/drm_connector.h
+++ b/include/drm/drm_connector.h
@@ -2267,6 +2267,8 @@ int drm_mode_create_dp_colorspace_property(struct drm_connector *connector,
u32 supported_colorspaces);
int drm_mode_create_content_type_property(struct drm_device *dev);
int drm_mode_create_suggested_offset_properties(struct drm_device *dev);
+int drm_mode_create_power_saving_policy_property(struct drm_device *dev,
+ uint64_t supported_policies);
int drm_connector_set_path_property(struct drm_connector *connector,
const char *path);
diff --git a/include/drm/drm_mode_config.h b/include/drm/drm_mode_config.h
index ab0f167474b1..150f9a3b649f 100644
--- a/include/drm/drm_mode_config.h
+++ b/include/drm/drm_mode_config.h
@@ -969,6 +969,11 @@ struct drm_mode_config {
*/
struct drm_atomic_state *suspend_state;
+ /**
+ * @power_saving_policy: bitmask for power saving policy requests.
+ */
+ struct drm_property *power_saving_policy;
+
const struct drm_mode_config_helper_funcs *helper_private;
};