From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754589AbdLGPKk (ORCPT ); Thu, 7 Dec 2017 10:10:40 -0500 Received: from mx2.suse.de ([195.135.220.15]:45461 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754525AbdLGPKZ (ORCPT ); Thu, 7 Dec 2017 10:10:25 -0500 Date: Thu, 7 Dec 2017 16:08:24 +0100 From: David Sterba To: Qu Wenruo Cc: Arnd Bergmann , Chris Mason , Josef Bacik , David Sterba , Qu Wenruo , Su Yue , Nikolay Borisov , linux-btrfs@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] btrfs: tree-checker: use %zu format string for size_t Message-ID: <20171207150824.GG3553@twin.jikos.cz> Reply-To: dsterba@suse.cz Mail-Followup-To: dsterba@suse.cz, Qu Wenruo , Arnd Bergmann , Chris Mason , Josef Bacik , David Sterba , Qu Wenruo , Su Yue , Nikolay Borisov , linux-btrfs@vger.kernel.org, linux-kernel@vger.kernel.org References: <20171206141844.788362-1-arnd@arndb.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.23.1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Dec 07, 2017 at 08:32:04AM +0800, Qu Wenruo wrote: > > > On 2017年12月06日 22:18, Arnd Bergmann wrote: > > The return value of sizeof() is of type size_t, so we must print it > > using the %z format modifier rather than %l to avoid this warning > > on some architectures: > > > > fs/btrfs/tree-checker.c: In function 'check_dir_item': > > fs/btrfs/tree-checker.c:273:50: error: format '%lu' expects argument of type 'long unsigned int', but argument 5 has type 'u32' {aka 'unsigned int'} [-Werror=format=] > > Any idea about which architecture will cause such warning? > On x86_64 I always fail to get such warning. The intel 0-day build bot compiles on various architectures and 32/64 setups, I'm not sure if this warning has been reported, no such mail in my mboxes.