From patchwork Fri Mar 4 02:04:03 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matt Turner X-Patchwork-Id: 607561 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p2425F5T023740 for ; Fri, 4 Mar 2011 02:05:36 GMT Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 44B369E9C8 for ; Thu, 3 Mar 2011 18:05:15 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-vw0-f49.google.com (mail-vw0-f49.google.com [209.85.212.49]) by gabe.freedesktop.org (Postfix) with ESMTP id 72A009E798 for ; Thu, 3 Mar 2011 18:05:02 -0800 (PST) Received: by vws7 with SMTP id 7so1739890vws.36 for ; Thu, 03 Mar 2011 18:05:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:to:cc:subject:date:message-id:x-mailer; bh=+Vg5D/i/cur8F84pVH52ENzVkQ6mRk++auWAAWmVOcc=; b=MIiECLqkGUcPVufgX2e+r2MIUzr3h30hpoORP5OdZ80GooAu0re7O4G7BvWxaUXgOl Q++a72hk5T0UvNo5RkJ8B+xeSFuq2ky+D996VFD9y/aBnRWg3lMi++LldsMJtyhXKHCc oygG9GyZ275oahrjd8bwz5tf+rK0uU6s0IMsQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; b=QeqHOK1JepuBc26DPK5uPv+UgsjqBgBJfbHuLdkhoNV/jSV2/dTsPLBoHriBkQmXKO 7chXgvurRLTQjFgVRL4rXJocCQgJ1Yms/Cut+i3+uvctX1Le7JNanlxjqoqdZ2K8FlE3 +9V6Jztrfei6ejKVz6sPCchYWpKrf7+cSXuPQ= Received: by 10.52.18.9 with SMTP id s9mr26212vdd.211.1299204301536; Thu, 03 Mar 2011 18:05:01 -0800 (PST) Received: from localhost (cpe-024-163-056-168.nc.res.rr.com [24.163.56.168]) by mx.google.com with ESMTPS id k8sm415391vdv.39.2011.03.03.18.04.59 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 03 Mar 2011 18:05:00 -0800 (PST) From: Matt Turner To: dri-devel@lists.freedesktop.org Subject: [PATCH] modeprint.c: use PRIu64 for printing uint64_t Date: Thu, 3 Mar 2011 21:04:03 -0500 Message-Id: <1299204243-12379-1-git-send-email-mattst88@gmail.com> X-Mailer: git-send-email 1.7.3.4 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Fri, 04 Mar 2011 02:05:36 +0000 (UTC) diff --git a/tests/modeprint/modeprint.c b/tests/modeprint/modeprint.c index 09b8df0..545ff40 100644 --- a/tests/modeprint/modeprint.c +++ b/tests/modeprint/modeprint.c @@ -36,6 +36,7 @@ #include #include #include +#include #include "xf86drm.h" #include "xf86drmMode.h" @@ -101,7 +102,7 @@ int printProperty(int fd, drmModeResPtr res, drmModePropertyPtr props, uint64_t if (props->count_values) { printf("\tvalues :"); for (j = 0; j < props->count_values; j++) - printf(" %llu", props->values[j]); + printf(" %" PRIu64, props->values[j]); printf("\n"); } @@ -116,7 +117,7 @@ int printProperty(int fd, drmModeResPtr res, drmModePropertyPtr props, uint64_t printf("blob is %d length, %08X\n", blob->length, *(uint32_t *)blob->data); drmModeFreePropertyBlob(blob); } else { - printf("error getting blob %llu\n", value); + printf("error getting blob %" PRIu64 "\n", value); } } else { @@ -132,7 +133,7 @@ int printProperty(int fd, drmModeResPtr res, drmModePropertyPtr props, uint64_t if (props->count_enums && name) { printf("\tcon_value : %s\n", name); } else { - printf("\tcon_value : %lld\n", value); + printf("\tcon_value : %" PRIu64 "\n", value); } }