Move DRM's HMDI helpers into the display/ subdirectoy and add it to DRM's display helpers. Update all affected drivers. No functional changes. The HDMI helpers were implemented in the EDID and connector code, but are actually unrelated. With the move to the display-helper library, we can remove the dependency on drm_edid.{c,h} in some driver's HDMI source files. Several of the HDMI helpers remain in EDID code because both share parts of their implementation internally. With better refractoring of the EDID code, those HDMI helpers could be moved into the display-helper library as well. v3: * fix Kconfig dependencies (Javier) v2: * reduce HDMI helpers to avoid exporting functions (Jani) * fix include statements (Jani, Javier) * update Kconfig symbols
Showing the changes to include (3 of 19 files). Show all
Unified · Split
| @@ -0,0 +1,27 @@ | |||
| 1 | /* SPDX-License-Identifier: MIT */ | ||
| 2 | |||
| 3 | #ifndef DRM_HDMI_HELPER | ||
| 4 | #define DRM_HDMI_HELPER | ||
| 5 | |||
| 6 | #include <linux/hdmi.h> | ||
| 7 | |||
| 8 | struct drm_connector; | ||
| 9 | struct drm_connector_state; | ||
| 10 | struct drm_display_mode; | ||
| 11 | |||
| 12 | void | ||
| 13 | drm_hdmi_avi_infoframe_colorimetry(struct hdmi_avi_infoframe *frame, | ||
| 14 | const struct drm_connector_state *conn_state); | ||
| 15 | |||
| 16 | void | ||
| 17 | drm_hdmi_avi_infoframe_bars(struct hdmi_avi_infoframe *frame, | ||
| 18 | const struct drm_connector_state *conn_state); | ||
| 19 | |||
| 20 | int | ||
| 21 | drm_hdmi_infoframe_set_hdr_metadata(struct hdmi_drm_infoframe *frame, | ||
| 22 | const struct drm_connector_state *conn_state); | ||
| 23 | |||
| 24 | void drm_hdmi_avi_infoframe_content_type(struct hdmi_avi_infoframe *frame, | ||
| 25 | const struct drm_connector_state *conn_state); | ||
| 26 | |||
| 27 | #endif | ||
| @@ -1784,9 +1784,6 @@ int drm_mode_create_aspect_ratio_property(struct drm_device *dev); · 1783 unmodified lines | |||
| 1784 | int drm_mode_create_hdmi_colorspace_property(struct drm_connector *connector); | 1784 | int drm_mode_create_hdmi_colorspace_property(struct drm_connector *connector); |
| 1785 | int drm_mode_create_dp_colorspace_property(struct drm_connector *connector); | 1785 | int drm_mode_create_dp_colorspace_property(struct drm_connector *connector); |
| 1786 | int drm_mode_create_content_type_property(struct drm_device *dev); | 1786 | int drm_mode_create_content_type_property(struct drm_device *dev); |
| 1787 | void drm_hdmi_avi_infoframe_content_type(struct hdmi_avi_infoframe *frame, | ||
| 1788 | const struct drm_connector_state *conn_state); | ||
| 1789 | |||
| 1790 | int drm_mode_create_suggested_offset_properties(struct drm_device *dev); | 1787 | int drm_mode_create_suggested_offset_properties(struct drm_device *dev); |
| 1791 | 1788 | ||
| 1792 | int drm_connector_set_path_property(struct drm_connector *connector, | 1789 | int drm_connector_set_path_property(struct drm_connector *connector, |
| @@ -400,24 +400,12 @@ drm_hdmi_vendor_infoframe_from_display_mode(struct hdmi_vendor_infoframe *frame, · 399 unmodified lines | |||
| 400 | const struct drm_connector *connector, | 400 | const struct drm_connector *connector, |
| 401 | const struct drm_display_mode *mode); | 401 | const struct drm_display_mode *mode); |
| 402 | 402 | ||
| 403 | void | ||
| 404 | drm_hdmi_avi_infoframe_colorimetry(struct hdmi_avi_infoframe *frame, | ||
| 405 | const struct drm_connector_state *conn_state); | ||
| 406 | |||
| 407 | void | ||
| 408 | drm_hdmi_avi_infoframe_bars(struct hdmi_avi_infoframe *frame, | ||
| 409 | const struct drm_connector_state *conn_state); | ||
| 410 | |||
| 411 | void | 403 | void |
| 412 | drm_hdmi_avi_infoframe_quant_range(struct hdmi_avi_infoframe *frame, | 404 | drm_hdmi_avi_infoframe_quant_range(struct hdmi_avi_infoframe *frame, |
| 413 | const struct drm_connector *connector, | 405 | const struct drm_connector *connector, |
| 414 | const struct drm_display_mode *mode, | 406 | const struct drm_display_mode *mode, |
| 415 | enum hdmi_quantization_range rgb_quant_range); | 407 | enum hdmi_quantization_range rgb_quant_range); |
| 416 | 408 | ||
| 417 | int | ||
| 418 | drm_hdmi_infoframe_set_hdr_metadata(struct hdmi_drm_infoframe *frame, | ||
| 419 | const struct drm_connector_state *conn_state); | ||
| 420 | |||
| 421 | /** | 409 | /** |
| 422 | * drm_eld_mnl - Get ELD monitor name length in bytes. | 410 | * drm_eld_mnl - Get ELD monitor name length in bytes. |
| 423 | * @eld: pointer to an eld memory structure with mnl set | 411 | * @eld: pointer to an eld memory structure with mnl set |