diff options
author | Jani Nikula <jani.nikula@intel.com> | 2024-01-23 22:37:08 +0300 |
---|---|---|
committer | Jani Nikula <jani.nikula@intel.com> | 2024-02-08 18:10:44 +0300 |
commit | f7930e64c1ebaf98f499769137f9c7ef767d7ed4 (patch) | |
tree | 22c6bec5ad93f99676e3f73c590560cc1c4f04c7 | |
parent | d807ad80d811ba0c22adfd871e2a46491f80d6e2 (diff) | |
download | linux-f7930e64c1ebaf98f499769137f9c7ef767d7ed4.tar.xz |
drm/bridge: switch to drm_bridge_edid_read()
Prefer using the struct drm_edid based functions.
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/704941568475e6e0e40d99a595a67e887949a30f.1706038510.git.jani.nikula@intel.com
-rw-r--r-- | drivers/gpu/drm/drm_bridge_connector.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/gpu/drm/drm_bridge_connector.c b/drivers/gpu/drm/drm_bridge_connector.c index 3acd67021ec6..982552c9f92c 100644 --- a/drivers/gpu/drm/drm_bridge_connector.c +++ b/drivers/gpu/drm/drm_bridge_connector.c @@ -239,27 +239,27 @@ static int drm_bridge_connector_get_modes_edid(struct drm_connector *connector, struct drm_bridge *bridge) { enum drm_connector_status status; - struct edid *edid; + const struct drm_edid *drm_edid; int n; status = drm_bridge_connector_detect(connector, false); if (status != connector_status_connected) goto no_edid; - edid = drm_bridge_get_edid(bridge, connector); - if (!drm_edid_is_valid(edid)) { - kfree(edid); + drm_edid = drm_bridge_edid_read(bridge, connector); + if (!drm_edid_valid(drm_edid)) { + drm_edid_free(drm_edid); goto no_edid; } - drm_connector_update_edid_property(connector, edid); - n = drm_add_edid_modes(connector, edid); + drm_edid_connector_update(connector, drm_edid); + n = drm_edid_connector_add_modes(connector); - kfree(edid); + drm_edid_free(drm_edid); return n; no_edid: - drm_connector_update_edid_property(connector, NULL); + drm_edid_connector_update(connector, NULL); return 0; } |