From: Ville Syrjälä Date: Wed, 11 Oct 2017 14:58:11 +0000 (+0300) Subject: modetest: Allow full testing of primary planes X-Git-Tag: android-x86-8.1-r1~313 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=ba68d7bf600125f2755a5b3d6b1a17e8a130ba36;p=android-x86%2Fexternal-libdrm.git modetest: Allow full testing of primary planes Allow the user to override the default configuration set by setcrtc for the primary plane. On some hardware primary planes can be freely positioned/sized, and it'd be nice if we can actually test that feature. Signed-off-by: Ville Syrjälä --- diff --git a/tests/modetest/modetest.c b/tests/modetest/modetest.c index 8ad4766f..62d93327 100644 --- a/tests/modetest/modetest.c +++ b/tests/modetest/modetest.c @@ -1091,7 +1091,8 @@ static int set_plane(struct device *dev, struct plane_arg *p) if (!format_support(ovr, p->fourcc)) continue; - if ((ovr->possible_crtcs & (1 << pipe)) && !ovr->crtc_id) { + if ((ovr->possible_crtcs & (1 << pipe)) && + (ovr->crtc_id == 0 || ovr->crtc_id == p->crtc_id)) { plane_id = ovr->plane_id; break; }