Skip to content

Commit 3231573

Browse files
tombaAndrzej Hajda
authored andcommitted
drm/bridge: tc358767: read display_props in get_modes()
We need to know the link bandwidth to filter out modes we cannot support, so we need to have read the display props before doing the filtering. To ensure we have up to date display props, call tc_get_display_props() in the beginning of tc_connector_get_modes(). Signed-off-by: Tomi Valkeinen <[email protected]> Reviewed-by: Andrzej Hajda <[email protected]> Signed-off-by: Andrzej Hajda <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 46648a3 commit 3231573

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

drivers/gpu/drm/bridge/tc358767.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1188,6 +1188,13 @@ static int tc_connector_get_modes(struct drm_connector *connector)
11881188
struct tc_data *tc = connector_to_tc(connector);
11891189
struct edid *edid;
11901190
unsigned int count;
1191+
int ret;
1192+
1193+
ret = tc_get_display_props(tc);
1194+
if (ret < 0) {
1195+
dev_err(tc->dev, "failed to read display props: %d\n", ret);
1196+
return 0;
1197+
}
11911198

11921199
if (tc->panel && tc->panel->funcs && tc->panel->funcs->get_modes) {
11931200
count = tc->panel->funcs->get_modes(tc->panel);

0 commit comments

Comments
 (0)