Commit 83023ffd authored by Peter Hutterer's avatar Peter Hutterer

xfree86: use the DDC size if either width or height of DisplaySize is bogus.

If either width or height of DisplaySize is invalid, assume that the
configuration is invalid and use the DDC-reported values instead.

See Comment 9, Bug 9758.
http://bugs.freedesktop.org/show_bug.cgi?id=9758#c9Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
Acked-by: default avatarDave Airlie <airlied@redhat.com>
parent f772014c
......@@ -957,7 +957,7 @@ xf86EdidMonitorSet(int scrnIndex, MonPtr Monitor, xf86MonPtr DDC)
quirks = xf86DDCDetectQuirks(scrnIndex, DDC, FALSE);
if (Monitor->widthmm <= 0 && Monitor->heightmm <= 0) {
if (Monitor->widthmm <= 0 || Monitor->heightmm <= 0) {
Monitor->widthmm = 10 * DDC->features.hsize;
Monitor->heightmm = 10 * DDC->features.vsize;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment