Received: by 10.223.164.221 with SMTP id h29csp2031147wrb; Thu, 2 Nov 2017 04:57:27 -0700 (PDT) X-Google-Smtp-Source: ABhQp+RUhb49FzlqMCgnZquc0of99rmWW4pQhgPPmNGt9uPeurCF8AmNpmltJ6qyTFCxQE+ErS4s X-Received: by 10.99.123.78 with SMTP id k14mr3273772pgn.351.1509623847099; Thu, 02 Nov 2017 04:57:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1509623847; cv=none; d=google.com; s=arc-20160816; b=p21SFBOvZADczKY/LFAjnRJOsVJBn/N+GJ/oZzLGo2hhj4D0IS+5SfDnQ6L0ntNMUS zfj9hXWP9lF7wehg+adm4MW/8HYq7Rmg0miuGl0WKz48mJAyuZt+G+zO49se9s2DN33o 0WtA/0U6jrAQ7NiWfi+kTpNtxEdRw1Mo9r7Yw46LEepYpywXo14KXTciDCxeM5vZbfHK 9sS9vRoV2oICB97mHYNeMvq6yNrIq7MTF8sR5IAxCgjZNQDrvudKJnx+Hsxyq2PUL47N 9EjTK1ainUYs5vvf2P1eXH3kxcHxhYpadC3KyymA/y+/CCkarbZfQdmdPdWLw6ORTK86 InAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :arc-authentication-results; bh=y2aMIa/B2MGcWL3i3ewHBxPX6/jzqGY7LUztncEyZ1M=; b=Y8MBS+fEE2erKdjlFYgwgn02jntLUhDTzXECboFnpZz12DhLREs6vKWraln2xOqi4Y us1UKa3oHVNulkSLwGtCn+fsroaDA149G1+fDDCPyRpvZ2jKuPAb3/h8rsw5RREuup3b m6/fFowjTyYH6+zKE32AcR5MzZQtAykT7VcFao1+MD5clNM7mP5A4BU4ihUukI0cTm9s 0ESev2EK6rPoW2zmaVDoXGZvKpabL0Wd7TC1gWQZ/6Ojua9lHSwgr5Cqu0lfyEZkXAmz zKcBQl0SHfY9B4oT2d9Y5TBvp9yj899eU6t3tzEYCIGSwAtrGoAO2yA9IvXa35r/QC4f 6lNg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e12si2132757plj.21.2017.11.02.04.57.13; Thu, 02 Nov 2017 04:57:27 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753080AbdKBL4a (ORCPT + 96 others); Thu, 2 Nov 2017 07:56:30 -0400 Received: from mail.free-electrons.com ([62.4.15.54]:33727 "EHLO mail.free-electrons.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751303AbdKBL43 (ORCPT ); Thu, 2 Nov 2017 07:56:29 -0400 Received: by mail.free-electrons.com (Postfix, from userid 110) id 453DB21D68; Thu, 2 Nov 2017 12:56:27 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.free-electrons.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.0 Received: from bbrezillon (91-160-177-164.subs.proxad.net [91.160.177.164]) by mail.free-electrons.com (Postfix) with ESMTPSA id 0D21D20869; Thu, 2 Nov 2017 12:56:27 +0100 (CET) Date: Thu, 2 Nov 2017 12:56:27 +0100 From: Boris Brezillon To: Arnd Bergmann Cc: Eric Anholt , David Airlie , Daniel Vetter , Cihangir Akturk , Dave Airlie , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] drm/vc4: use %z format string for size_t Message-ID: <20171102125627.45a19fd7@bbrezillon> In-Reply-To: <20171102112107.4058917-1-arnd@arndb.de> References: <20171102112107.4058917-1-arnd@arndb.de> X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Arnd, On Thu, 2 Nov 2017 12:20:43 +0100 Arnd Bergmann wrote: > Printing a size_t variable needs to use the %z format string modifier > rather than %l, otherwise we get this warning on 64-bit architectures: > > drivers/gpu/drm/vc4/vc4_bo.c: In function 'vc4_bo_stats_debugfs': > drivers/gpu/drm/vc4/vc4_bo.c:91:26: error: format '%d' expects argument of type 'int', but argument 4 has type 'size_t {aka long unsigned int}' [-Werror=format=] > I already sent (and applied) a fix for this bug [1]. Regards, Boris [1]https://patchwork.kernel.org/patch/10036075/ > Fixes: b9f19259b84d ("drm/vc4: Add the DRM_IOCTL_VC4_GEM_MADVISE ioctl") > Signed-off-by: Arnd Bergmann > --- > drivers/gpu/drm/vc4/vc4_bo.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/vc4/vc4_bo.c b/drivers/gpu/drm/vc4/vc4_bo.c > index 3c3d11236910..4ae45d7dac42 100644 > --- a/drivers/gpu/drm/vc4/vc4_bo.c > +++ b/drivers/gpu/drm/vc4/vc4_bo.c > @@ -88,11 +88,11 @@ int vc4_bo_stats_debugfs(struct seq_file *m, void *unused) > > mutex_lock(&vc4->purgeable.lock); > if (vc4->purgeable.num) > - seq_printf(m, "%30s: %6dkb BOs (%d)\n", "userspace BO cache", > + seq_printf(m, "%30s: %6zdkb BOs (%d)\n", "userspace BO cache", > vc4->purgeable.size / 1024, vc4->purgeable.num); > > if (vc4->purgeable.purged_num) > - seq_printf(m, "%30s: %6dkb BOs (%d)\n", "total purged BO", > + seq_printf(m, "%30s: %6zdkb BOs (%d)\n", "total purged BO", > vc4->purgeable.purged_size / 1024, > vc4->purgeable.purged_num); > mutex_unlock(&vc4->purgeable.lock); From 1582953191534627641@xxx Thu Nov 02 11:23:22 +0000 2017 X-GM-THRID: 1582953191534627641 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread