From 3ddc799fbf04e1c7c482c0879aa506c3c7a12c04 Mon Sep 17 00:00:00 2001 From: "Lan, Hai" Date: Mon, 6 Jun 2011 19:16:26 -0700 Subject: [PATCH] testdisplay: fix possible_crtcs check so LVDS works When using testdisplay on GM965 and Pineview with LVDS, it will fail to set a mode because the first unused crtc can't be used for LVDS. So check the possible_crtcs to make sure the crtc can be used. Signed-off-by: Hai Lan --- tests/testdisplay.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/testdisplay.c b/tests/testdisplay.c index 1efc6e5..a01d633 100644 --- a/tests/testdisplay.c +++ b/tests/testdisplay.c @@ -310,7 +310,7 @@ static void connector_find_preferred_mode(struct connector *c) /* Find first CRTC not in use */ for (i = 0; i < resources->count_crtcs; i++) { - if (resources->crtcs[i]) + if (resources->crtcs[i] && (c->encoder->possible_crtcs & (1<crtc = resources->crtcs[i]; -- 2.7.4