From patchwork Tue Jan 24 15:27:16 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Engestrom X-Patchwork-Id: 9535411 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3C4AE6042C for ; Tue, 24 Jan 2017 15:27:35 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2E9C328179 for ; Tue, 24 Jan 2017 15:27:35 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 21B3C2819A; Tue, 24 Jan 2017 15:27:35 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id B1FD528179 for ; Tue, 24 Jan 2017 15:27:34 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id DC8F66E7B1; Tue, 24 Jan 2017 15:27:33 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mailapp01.imgtec.com (mailapp01.imgtec.com [195.59.15.196]) by gabe.freedesktop.org (Postfix) with ESMTP id 999996E136 for ; Tue, 24 Jan 2017 15:27:32 +0000 (UTC) Received: from HHMAIL01.hh.imgtec.org (unknown [10.100.10.19]) by Forcepoint Email with ESMTPS id 95887574A1740 for ; Tue, 24 Jan 2017 15:27:27 +0000 (GMT) Received: from localhost.localdomain (10.60.4.28) by HHMAIL01.hh.imgtec.org (10.100.10.21) with Microsoft SMTP Server (TLS) id 14.3.294.0; Tue, 24 Jan 2017 15:27:30 +0000 From: Eric Engestrom To: Intel GFX Date: Tue, 24 Jan 2017 15:27:16 +0000 Message-ID: <20170124152716.16780-1-eric.engestrom@imgtec.com> X-Mailer: git-send-email 2.11.0 MIME-Version: 1.0 X-Originating-IP: [10.60.4.28] Cc: Eric Engestrom Subject: [Intel-gfx] [PATCH i-g-t] lib/drmtest: make DRIVER_ANY match any driver X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Eric Engestrom --- Not tested or anything, I just happened to notice this code and it looked wrong, but maybe I misunderstood what it was meant to do. An alternative would be to just set the bits the the drivers that are defined already, but that would require an update everytime a new DRIVER_* is added (error-prone): #define DRIVER_ANY ((1 << 4) - 1) --- lib/drmtest.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/drmtest.h b/lib/drmtest.h index 19d4bd19..1d41df93 100644 --- a/lib/drmtest.h +++ b/lib/drmtest.h @@ -42,7 +42,7 @@ #define DRIVER_VC4 (1 << 1) #define DRIVER_VGEM (1 << 2) #define DRIVER_VIRTIO (1 << 3) -#define DRIVER_ANY ~(DRIVER_VGEM) +#define DRIVER_ANY (~0) #ifdef ANDROID #if (!(defined HAVE_MMAP64)) && (!(defined __x86_64__))