From patchwork Tue Jun 5 18:06:28 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rob Clark X-Patchwork-Id: 9116 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 74B4123E1B for ; Tue, 5 Jun 2012 18:06:53 +0000 (UTC) Received: from mail-yx0-f180.google.com (mail-yx0-f180.google.com [209.85.213.180]) by fiordland.canonical.com (Postfix) with ESMTP id 3DBF9A183B5 for ; Tue, 5 Jun 2012 18:06:53 +0000 (UTC) Received: by mail-yx0-f180.google.com with SMTP id q6so4773576yen.11 for ; Tue, 05 Jun 2012 11:06:53 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf :dkim-signature:sender:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references:x-gm-message-state; bh=Tmgv8hQvlUIx0RC+h7Wl+ndjuRvTHuB+mPkJYsJmNFs=; b=jGBig93LXF0qGSLIpHbt9q683f5RlY1RST2vSozmZFjVj2Pv5ejk0SJzLQtk0p+so0 jJXywzkmw8nOFKs6bgauZQupdfw65CCSWrDYv7pUS9plOcvOcmFM38s+owa7yMykFnZe vAMC3m1zLlB131QnCEwqsI4GEdXHhZwRQ1dur3OfXCbZtaSvokNb9DSNh6mUppHjJOL9 aM1/b3nhlL3M2f/Ise/LuWlyI/qlQF6HJog9GmvOuxhXLQgRjENbSoAM9UIkMJRcj1/M 2KsKhFAiPrDX5ORogoKJxt140L6ORQH6wPjslOt6uoUvr0EV7UquI6tL9M9hZWplcusJ fNxA== Received: by 10.42.89.72 with SMTP id f8mr11680370icm.33.1338919612426; Tue, 05 Jun 2012 11:06:52 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.231.24.148 with SMTP id v20csp39691ibb; Tue, 5 Jun 2012 11:06:51 -0700 (PDT) Received: by 10.182.154.73 with SMTP id vm9mr17486812obb.72.1338919611820; Tue, 05 Jun 2012 11:06:51 -0700 (PDT) Received: from mail-ob0-f178.google.com (mail-ob0-f178.google.com [209.85.214.178]) by mx.google.com with ESMTPS id xz10si1955460obb.48.2012.06.05.11.06.51 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 05 Jun 2012 11:06:51 -0700 (PDT) Received-SPF: pass (google.com: domain of robdclark@gmail.com designates 209.85.214.178 as permitted sender) client-ip=209.85.214.178; Authentication-Results: mx.google.com; spf=pass (google.com: domain of robdclark@gmail.com designates 209.85.214.178 as permitted sender) smtp.mail=robdclark@gmail.com; dkim=pass header.i=@gmail.com Received: by obceq6 with SMTP id eq6so12339372obc.37 for ; Tue, 05 Jun 2012 11:06:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references; bh=Tmgv8hQvlUIx0RC+h7Wl+ndjuRvTHuB+mPkJYsJmNFs=; b=C6Jzb9shhBqKZ319fuaSthAAKgNHJkf9ZjhohtZaRZFeZUKSxu4ZsizeFVEASwENa6 BmTCdmqRY0Q1rnVD2vqbXW6aGzPxxK0KVMRC413HtUzYwEcr/kyfZpuqWhNKtbuhjdLg dYHyM6cV8NjKyCgp01Og7t3o73dhRmZDIc8JQmoY3zX+tvYWwUuQxyxyqWKZFPBPgGXP Xe0y3Y3gcLPbJnSfv3mf6lkPE5UJJUvwxe+S7KtrtpHNd7WmGcMchBLvF/DDQ4C8jXFL +S4IuOOGs8rPGyFK1J3YdCNKuW+UKjPCgH2Sa6+cQ06aBXV6v6fwtZT9SfT0oa/09fFr t+fw== Received: by 10.182.8.99 with SMTP id q3mr17283968oba.63.1338919611255; Tue, 05 Jun 2012 11:06:51 -0700 (PDT) Received: from localhost (ppp-70-253-38-6.dsl.rcsntx.swbell.net. [70.253.38.6]) by mx.google.com with ESMTPS id u2sm1778107obc.16.2012.06.05.11.06.50 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 05 Jun 2012 11:06:50 -0700 (PDT) Sender: Rob Clark From: Rob Clark To: dri-devel@lists.freedesktop.org Cc: patches@linaro.org, Paulo Zanoni Subject: [PATCH libdrm 2/8] modetest: print CRTC properties Date: Tue, 5 Jun 2012 13:06:28 -0500 Message-Id: <1338919594-25392-3-git-send-email-rob.clark@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1338919594-25392-1-git-send-email-rob.clark@linaro.org> References: <1338919594-25392-1-git-send-email-rob.clark@linaro.org> X-Gm-Message-State: ALoCoQlygWiC72t3HlF5+odONCLri5sOWczoo7cP8CyHBXAYx/nGh+AAl0Rw0qBZO/rXsPhkILVx From: Paulo Zanoni Reviewed-by: Eugeni Dodonov Reviewed-by: Rob Clark Signed-off-by: Paulo Zanoni --- tests/modetest/modetest.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/tests/modetest/modetest.c b/tests/modetest/modetest.c index 8012ecc..ce57e65 100644 --- a/tests/modetest/modetest.c +++ b/tests/modetest/modetest.c @@ -295,7 +295,9 @@ void dump_connectors(void) void dump_crtcs(void) { drmModeCrtc *crtc; + drmModeObjectPropertiesPtr props; int i; + uint32_t j; printf("CRTCs:\n"); printf("id\tfb\tpos\tsize\n"); @@ -314,6 +316,19 @@ void dump_crtcs(void) crtc->width, crtc->height); dump_mode(&crtc->mode); + printf(" props:\n"); + props = drmModeObjectGetProperties(fd, crtc->crtc_id, + DRM_MODE_OBJECT_CRTC); + if (props) { + for (j = 0; j < props->count_props; j++) + dump_prop(props->props[j], + props->prop_values[j]); + drmModeFreeObjectProperties(props); + } else { + printf("\tcould not get crtc properties: %s\n", + strerror(errno)); + } + drmModeFreeCrtc(crtc); } printf("\n");