From: Imre Deak Subject: [PATCH 03/22] flip_test: reset the state for each test run Date: Tue, 16 Oct 2012 17:34:37 +0300 Message-ID: <1350398096-3649-4-git-send-email-imre.deak@intel.com> References: <1350398096-3649-1-git-send-email-imre.deak@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mga14.intel.com (mga14.intel.com [143.182.124.37]) by gabe.freedesktop.org (Postfix) with ESMTP id 8E7419F378 for ; Tue, 16 Oct 2012 07:35:07 -0700 (PDT) In-Reply-To: <1350398096-3649-1-git-send-email-imre.deak@intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org Each test run needs a clean state. Signed-off-by: Imre Deak --- tests/flip_test.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tests/flip_test.c b/tests/flip_test.c index d018c50..b338448 100644 --- a/tests/flip_test.c +++ b/tests/flip_test.c @@ -546,11 +546,13 @@ static int run_test(int duration, int flags) /* Find any connected displays */ for (c = 0; c < resources->count_connectors; c++) { - memset(&o, 0, sizeof(o)); - o.id = resources->connectors[c]; - o.flags = flags; - for (i = 0; i < resources->count_crtcs; i++) + for (i = 0; i < resources->count_crtcs; i++) { + memset(&o, 0, sizeof(o)); + o.id = resources->connectors[c]; + o.flags = flags; + flip_mode(&o, resources->crtcs[i], duration); + } } drmModeFreeResources(resources); -- 1.7.9.5