summaryrefslogtreecommitdiffstats
path: root/include/drm
diff options
context:
space:
mode:
authorMaxime Ripard <maxime@cerno.tech>2022-11-17 10:28:50 +0100
committerMaxime Ripard <maxime@cerno.tech>2022-11-24 12:42:39 +0100
commitd4613e3e50d34bc30ea384b8bf9560e874451640 (patch)
treec7d0c78c254cb0f890afb65e257729e1b998cf63 /include/drm
parent4fcd238560ee6724d6edcae95820bdf7f2e40ab1 (diff)
downloadlinux-stable-d4613e3e50d34bc30ea384b8bf9560e874451640.tar.gz
linux-stable-d4613e3e50d34bc30ea384b8bf9560e874451640.tar.bz2
linux-stable-d4613e3e50d34bc30ea384b8bf9560e874451640.zip
drm/connector: Add a function to lookup a TV mode by its name
As part of the command line parsing rework coming in the next patches, we'll need to lookup drm_connector_tv_mode values by their name, already defined in drm_tv_mode_enum_list. In order to avoid any code duplication, let's do a function that will perform a lookup of a TV mode name and return its value. Reviewed-by: Noralf Trønnes <noralf@tronnes.org> Tested-by: Mateusz Kwiatkowski <kfyatek+publicgit@gmail.com> Acked-in-principle-or-something-like-that-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: https://lore.kernel.org/r/20220728-rpi-analog-tv-properties-v10-7-256dad125326@cerno.tech Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Diffstat (limited to 'include/drm')
-rw-r--r--include/drm/drm_connector.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h
index efa32e88a5b7..3390b93b07e9 100644
--- a/include/drm/drm_connector.h
+++ b/include/drm/drm_connector.h
@@ -1878,6 +1878,8 @@ const char *drm_get_dp_subconnector_name(int val);
const char *drm_get_content_protection_name(int val);
const char *drm_get_hdcp_content_type_name(int val);
+int drm_get_tv_mode_from_name(const char *name, size_t len);
+
int drm_mode_create_dvi_i_properties(struct drm_device *dev);
void drm_connector_attach_dp_subconnector_property(struct drm_connector *connector);