mirror of
https://github.com/genodelabs/genode.git
synced 2025-02-22 02:16:44 +00:00
intel/display: handle all connectors disabled case
If all connectors are set to disabled by configuration, the connectors stayed enabled since the new configuration reveals no preferred or minimal resolution/mode. Instead, use the last set resolution in order to get to the disabling code.
This commit is contained in:
parent
d6da06913e
commit
0f70cafb91
@ -262,7 +262,7 @@ append config {
|
|||||||
</route>
|
</route>
|
||||||
</start>}
|
</start>}
|
||||||
|
|
||||||
append_if $use_fb_controller {
|
append_if $use_fb_controller config {
|
||||||
<start name="intel_fb_controller" priority="-1">
|
<start name="intel_fb_controller" priority="-1">
|
||||||
<resource name="RAM" quantum="1M"/>
|
<resource name="RAM" quantum="1M"/>
|
||||||
<config>
|
<config>
|
||||||
|
@ -153,7 +153,7 @@ static void preferred_mode(struct drm_device const * const dev,
|
|||||||
}
|
}
|
||||||
drm_connector_list_iter_end(&conn_iter);
|
drm_connector_list_iter_end(&conn_iter);
|
||||||
|
|
||||||
/* no modes on any connector, happens during early bootup */
|
/* no mode due to early bootup or all connectors are disabled by config */
|
||||||
if (!min_mode->hdisplay || !min_mode->vdisplay)
|
if (!min_mode->hdisplay || !min_mode->vdisplay)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@ -245,9 +245,17 @@ static bool reconfigure(struct drm_client_dev * const dev)
|
|||||||
|
|
||||||
preferred_mode(dev->dev, &mode_preferred, &mode_minimum);
|
preferred_mode(dev->dev, &mode_preferred, &mode_minimum);
|
||||||
|
|
||||||
/* no valid modes on any connector on early boot */
|
if (!mode_minimum.hdisplay || !mode_minimum.vdisplay) {
|
||||||
if (!mode_minimum.hdisplay || !mode_minimum.vdisplay)
|
/* no valid modes on any connector on early boot */
|
||||||
return false;
|
if (!dumb_fb.fb_id)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
/* valid connectors but all are disabled by config */
|
||||||
|
mode_minimum.hdisplay = dumb_fb.width;
|
||||||
|
mode_minimum.vdisplay = dumb_fb.height;
|
||||||
|
mode_preferred = mode_minimum;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
if (mode_larger(&mode_preferred, &mode_minimum))
|
if (mode_larger(&mode_preferred, &mode_minimum))
|
||||||
mode_real = mode_preferred;
|
mode_real = mode_preferred;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user