From patchwork Fri Sep 5 09:52:08 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Wood X-Patchwork-Id: 4851071 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 4FD7FC0338 for ; Fri, 5 Sep 2014 09:52:23 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 907F020176 for ; Fri, 5 Sep 2014 09:52:22 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 9BD7A20120 for ; Fri, 5 Sep 2014 09:52:21 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id D2E686E83B; Fri, 5 Sep 2014 02:52:20 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-wg0-f46.google.com (mail-wg0-f46.google.com [74.125.82.46]) by gabe.freedesktop.org (Postfix) with ESMTP id 6A88A6E82F for ; Fri, 5 Sep 2014 02:52:18 -0700 (PDT) Received: by mail-wg0-f46.google.com with SMTP id n12so571000wgh.17 for ; Fri, 05 Sep 2014 02:52:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=tK4qhibiBsvQhk5R3WjBYR5HVHYU3fPYAoAftrvIaVA=; b=YQUruV6UaUdk+1QucBnOQDwHsWxsz1iR9Mv0SR3ujCfoMKf1X80MjZWnnQQGXPrvxj Fl1uYBBGWPY7RpOEjTb7ZZXWzLKD0LBALXVl/UulSSIHzVFtUU7vCrHj8IJwX7lZvbna /ZTiatbSBV8H/OhohRreypdHGRn2Ihj61SRnZox8RqvgIBeSwxMYOXB2unr+j36UEgFs H/FgPrmVabo5GKF8oBu5FS5/F9P1BOw4pnqH4OFmWmjdNox4sbKJ0MwaKO6x9IPKU2AN zGV70P5shCIWIhwJaaM4j9Ns+OkEQqe6Ah+K+hTY54Oxl7YsgxZfTtXL17A7jzt598RD Zjyg== X-Gm-Message-State: ALoCoQnBiBFM+2wn0mOlGcHDFOTFE7eK9tm1xgE4FqSDvAPUJwCOvY9U+yBucIlo3L3UyO4T8yLe X-Received: by 10.180.24.35 with SMTP id r3mr2167104wif.71.1409910737610; Fri, 05 Sep 2014 02:52:17 -0700 (PDT) Received: from pistachio.icx.intel.com ([83.217.123.106]) by mx.google.com with ESMTPSA id h6sm875050wjb.33.2014.09.05.02.52.16 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 05 Sep 2014 02:52:16 -0700 (PDT) From: Thomas Wood To: intel-gfx@lists.freedesktop.org Date: Fri, 5 Sep 2014 10:52:08 +0100 Message-Id: <1409910729-13485-6-git-send-email-thomas.wood@intel.com> X-Mailer: git-send-email 1.9.3 In-Reply-To: <1409910729-13485-1-git-send-email-thomas.wood@intel.com> References: <5408C410.8080500@intel.com> <1409910729-13485-1-git-send-email-thomas.wood@intel.com> Subject: [Intel-gfx] [PATCH i-g-t v2 5/6] lib: don't force HDMI or DP connectors on gen 7 and 8 X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-5.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, 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 Forcing HDMI or DP connectors on gen 7 and 8 doesn't currently work, so fail early to allow the test to skip if required. Signed-off-by: Thomas Wood --- lib/igt_kms.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/lib/igt_kms.c b/lib/igt_kms.c index 0dc46f9..e9455aa 100644 --- a/lib/igt_kms.c +++ b/lib/igt_kms.c @@ -41,6 +41,7 @@ #include "drmtest.h" #include "igt_kms.h" #include "igt_aux.h" +#include "intel_chipset.h" /* * There hasn't been a release of libdrm containing these #define's yet, so @@ -344,6 +345,17 @@ bool kmstest_force_connector(int drm_fd, drmModeConnector *connector, char *path; const char *value; int debugfs_fd, ret; + uint32_t devid; + + devid = intel_get_drm_devid(drm_fd); + + /* forcing hdmi or dp connectors on gen 7 and 8 doesn't currently work, + * so fail early to allow the test to skip if required */ + if ((connector->connector_type == DRM_MODE_CONNECTOR_HDMIA || + connector->connector_type == DRM_MODE_CONNECTOR_HDMIB || + connector->connector_type == DRM_MODE_CONNECTOR_DisplayPort) + && (IS_GEN7(devid) || IS_GEN8(devid))) + return false; switch (state) { case FORCE_CONNECTOR_ON: