From patchwork Mon Aug 24 16:34:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Emil Velikov X-Patchwork-Id: 7065661 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 890F79F434 for ; Mon, 24 Aug 2015 16:30:35 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 093FA2078B for ; Mon, 24 Aug 2015 16:30:32 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 8A40820788 for ; Mon, 24 Aug 2015 16:30:29 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 8C90672088; Mon, 24 Aug 2015 09:30:26 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wi0-f180.google.com (mail-wi0-f180.google.com [209.85.212.180]) by gabe.freedesktop.org (Postfix) with ESMTPS id CB6786E9FB for ; Mon, 24 Aug 2015 09:30:20 -0700 (PDT) Received: by wicne3 with SMTP id ne3so77334698wic.0 for ; Mon, 24 Aug 2015 09:30:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=z9DRZ3jkm7bqrSz1ip6VsrHB0/vYbv6Z460fOoMd8xY=; b=N2v71qIPWQiwLFS+JvNOM6EhgiUP/zdCAZaFxmL05I68QHKx8oY7W+uV9o8xYr/cLy /oQUa0fFBUMCsq2WwwjTuhkZ/W6hu21hTQNFA3K359QzxiEBL9dZFaG0KyTEeBECV568 PL9sTzKDkt43qLqMJGUUn7dizhfBdirT+y027lskrZjvOaa0mMPbaxt+mLPN+hUXNY9j bfyEKH8TOkyZoEiDvDuevO7WrChITiJ8n0Yu3+ohvfkhrPaPU5YX7KHCFNWtCo9CaT2O OiVEMMZo4tVn1UMCaJ16z1wqLJ3X5ujUE6BJK3f4Y3Ht8IQdyLfCIM8JuQClbdnfmVHo 4otA== X-Received: by 10.180.81.100 with SMTP id z4mr30454095wix.8.1440433819625; Mon, 24 Aug 2015 09:30:19 -0700 (PDT) Received: from arch-x220.localdomain (cpc12-croy20-2-0-cust52.croy.cable.virginm.net. [82.44.54.53]) by smtp.gmail.com with ESMTPSA id ll1sm16885984wic.14.2015.08.24.09.30.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 24 Aug 2015 09:30:19 -0700 (PDT) From: Emil Velikov To: dri-devel@lists.freedesktop.org Subject: [PATCH libdrm 14/17] tests/amdgpu: ensure tests work by using c99 initializers Date: Mon, 24 Aug 2015 17:34:17 +0100 Message-Id: <1440434060-31347-14-git-send-email-emil.l.velikov@gmail.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1440434060-31347-1-git-send-email-emil.l.velikov@gmail.com> References: <1440434060-31347-1-git-send-email-emil.l.velikov@gmail.com> Cc: Alex Deucher , Leo Liu , emil.l.velikov@gmail.com X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP In the latest version of CUnit the fourth parameter of the CU_SuiteInfo struct is pSetUpFunc rather than *pTests. Seems like the CUnit ABI broke at some point, so let's the the robust thing and use c99 designated initializers to correctly populate the struct(s). Cc: Alex Deucher Cc: Leo Liu Signed-off-by: Emil Velikov Reviewed-by: Alex Deucher --- tests/amdgpu/amdgpu_test.c | 32 ++++++++++++++++++++++++-------- 1 file changed, 24 insertions(+), 8 deletions(-) diff --git a/tests/amdgpu/amdgpu_test.c b/tests/amdgpu/amdgpu_test.c index 6568990..71f357c 100644 --- a/tests/amdgpu/amdgpu_test.c +++ b/tests/amdgpu/amdgpu_test.c @@ -58,14 +58,30 @@ int drm_amdgpu[MAX_CARDS_SUPPORTED]; /** The table of all known test suites to run */ static CU_SuiteInfo suites[] = { - { "Basic Tests", suite_basic_tests_init, - suite_basic_tests_clean, basic_tests }, - { "BO Tests", suite_bo_tests_init, - suite_bo_tests_clean, bo_tests }, - { "CS Tests", suite_cs_tests_init, - suite_cs_tests_clean, cs_tests }, - { "VCE Tests", suite_vce_tests_init, - suite_vce_tests_clean, vce_tests }, + { + .pName = "Basic Tests", + .pInitFunc = suite_basic_tests_init, + .pCleanupFunc = suite_basic_tests_clean, + .pTests = basic_tests, + }, + { + .pName = "BO Tests", + .pInitFunc = suite_bo_tests_init, + .pCleanupFunc = suite_bo_tests_clean, + .pTests = bo_tests, + }, + { + .pName = "CS Tests", + .pInitFunc = suite_cs_tests_init, + .pCleanupFunc = suite_cs_tests_clean, + .pTests = cs_tests, + }, + { + .pName = "VCE Tests", + .pInitFunc = suite_vce_tests_init, + .pCleanupFunc = suite_vce_tests_clean, + .pTests = vce_tests, + }, CU_SUITE_INFO_NULL, };