From patchwork Fri Sep 8 21:08:08 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 112136 Delivered-To: patch@linaro.org Received: by 10.140.106.117 with SMTP id d108csp821813qgf; Fri, 8 Sep 2017 14:09:06 -0700 (PDT) X-Google-Smtp-Source: ADKCNb4D5yC3vppa1GDmi5yP85cnePuPY6FJv6hPO2IdWDoWA4Oe5mQM+z3UTu8cLcGkB1ZqVyu1 X-Received: by 10.84.241.77 with SMTP id u13mr4809264plm.109.1504904946006; Fri, 08 Sep 2017 14:09:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1504904945; cv=none; d=google.com; s=arc-20160816; b=GDYzX3iQ3qH2xjSTZJLVaXTVGrfpjyWk4TrzZ8UjUxUmQZT7PBY0KAgjC+9h73+ZPv dQoxiSryP1GgqOVMDQd10LUYLAOGK1nWZvfmF6arLqlfbMIK8n29J3ZtI7V7RkRLdKWx Jx7zUpEPku9t5/fkwmLZaI2naRyj373VB0rv1XpraQsSJRGKlCGZJtBm9B3AHzgT6Mvi Ek5NNW6loGn/JYFdPM82ap3VM6r6ZA7964AYLt6TFTCMQLkEAeSzEy9lhmv+tqyVgHSH TeCUPgukmGNfEFS/TirL8B5gFPb1wKu38tmp0gJS293RlYnTpjBclUPU4g5U3giqQXxe E5PQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=LPAeV5FJCatDwPdFIPH+mYo06R4gRv/Fpqwo6yZMRcQ=; b=EitoU9slF0E/DjXS6d0TXFmJFNg+QZPZWD2bpeeVl1uYGRjkyeTg6L6Cz1LGqrJHxp N94eyN1s8LphZVM34JqECSZE9qQ2RL3C7AKvxPdn8FS/zVq35956gnSHYDo92SY4Nym6 oxPl8hvDMXqQyzH2yyEE8OFO7rZ0uaMQJ9eAa1aYYs7lawfHk+BpIUKsTGZoaL8AsF9g o1PHTT/rdtugniqQFns5hsBPIPxthXK0OmuJRzTg0dz4BWE/3XWCeqaN4rwapG6ctkk2 T+x4EHTap0YKQApeXAxbcCJgcPmdi80W4bn1LMy/a2LBHr+la+0EjgUv3EdMbKZQvTLL e8FA== 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 j25si2069839pga.60.2017.09.08.14.09.05; Fri, 08 Sep 2017 14:09:05 -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 S1757097AbdIHVIw (ORCPT + 26 others); Fri, 8 Sep 2017 17:08:52 -0400 Received: from mout.kundenserver.de ([212.227.17.13]:60839 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756063AbdIHVIv (ORCPT ); Fri, 8 Sep 2017 17:08:51 -0400 Received: from wuerfel.lan ([95.208.190.237]) by mrelayeu.kundenserver.de (mreue102 [212.227.15.145]) with ESMTPA (Nemesis) id 0MQNsy-1e2dJt0YWa-00TjQp; Fri, 08 Sep 2017 23:08:33 +0200 From: Arnd Bergmann To: Vishal Verma , Dan Williams Cc: Arnd Bergmann , Jens Axboe , Dmitry Monakhov , "Martin K. Petersen" , linux-nvdimm@lists.01.org, linux-kernel@vger.kernel.org Subject: [PATCH] libnvdimm, btt: use %z format string modifier for size_t Date: Fri, 8 Sep 2017 23:08:08 +0200 Message-Id: <20170908210830.525785-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:fN4EAlCNY+QEprVZmGDb1922aSyQ6q8Avr+T5tiqty6Y/B/5Q6S fxr8Zi+weM32JGpq/JE99UO/Ul6FOuQXZyV0p+2KLuRVb9qObEsBiNM4vBVMJBSnqarjvZ/ xMyGRnqoZUI9mOElgNWIN8LMvjz5rAjEk8TcfLMBu+XLu0HcJanELDfCXCwPlsy2DhVjNI1 vJsKV6gdrWNoCrFnWhwCA== X-UI-Out-Filterresults: notjunk:1; V01:K0:2lk8TC7daW8=:eWSvTeEPbWDmSuo4E40YUF pCkKfiyy6rd3488HBOBBu12XhrPO3kKXJx/ztMmTqpz2jYHJuwyA/heZ8E0g/7s2J269w6z05 iH3J+jh8dLbfpc5Iu8BiCneUjm/MEWU6OGjrkSB460VCanr8YepUJS90WVbA7ckLGeMMEZyDG D+igVZHktJ61GJ00mWoj1jNBNIYV8LAe6a+l9JwK90PcZSEJJ0SK+DiSyucilPMjVXxyzUPGM t8xQQHomegPhs4eKBAMoY2RFlN5Q9mm0606DlU3QeOcKLIK1Rb/EHYPP8ov3iuPBv8HxLTRK3 yH4Ry5Aix6dnfrFgBC4ZgYGsbL+yhSNNYb9DIZTf2/Gq0YBxJzTI554ZShKt+i+m/naFZYZzP YJyalkgRcwTXAStEOop0RuPEFxuLxonSuSfZDNTBlZUTDnrGTH1tsVnKueHRJrlD6nhYisnxj OeOCiQ7ZK83+mKDtuHiDibH7hJkUNTkZh5GpKdpAcg+NPmPGzUXH6+uwV8LeWNv25hrhfuold zDk+t/M2ssAEPqxkvnTG7bK6tQAKfkOTUDMXWyPP6g0IlbhcHPa1KmLXD5HCpXcFNl8JO1iOF fO/z2NuoO3oj0uJfLOEAj6uGJk98PjNfMbFoShyZwOeDJ90iOVurR1XBr3jkeot/13Zz5VmWa ad3AZO6Dd2jlIzPCA1eRaSrPEHH+TBMIpMbW7iOnMfchaMztYQ/C7gRsBofs95yND6NZ88b+0 zEXYcKYE5Sy7w/81F+18tAHUEFy8KLgNgWROnQ== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We get a warning about an two incorrect format strings: drivers/nvdimm/btt.c: In function 'btt_map_init': include/linux/device.h:1472:23: error: format '%lx' expects argument of type 'long unsigned int', but argument 6 has type 'size_t {aka unsigned int}' [-Werror=format=] This changes the %lx to %zx as it should be. Fixes: 86652d2eb347 ("libnvdimm, btt: clean up warning and error messages") Signed-off-by: Arnd Bergmann --- drivers/nvdimm/btt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.9.0 diff --git a/drivers/nvdimm/btt.c b/drivers/nvdimm/btt.c index 5bc686e9195a..d5612bd1cc81 100644 --- a/drivers/nvdimm/btt.c +++ b/drivers/nvdimm/btt.c @@ -428,7 +428,7 @@ static int btt_map_init(struct arena_info *arena) size_t size = min(mapsize, chunk_size); dev_WARN_ONCE(to_dev(arena), size < 512, - "chunk size: %#lx is unaligned\n", size); + "chunk size: %#zx is unaligned\n", size); ret = arena_write_bytes(arena, arena->mapoff + offset, zerobuf, size, 0); if (ret) @@ -472,7 +472,7 @@ static int btt_log_init(struct arena_info *arena) size_t size = min(logsize, chunk_size); dev_WARN_ONCE(to_dev(arena), size < 512, - "chunk size: %#lx is unaligned\n", size); + "chunk size: %#zx is unaligned\n", size); ret = arena_write_bytes(arena, arena->logoff + offset, zerobuf, size, 0); if (ret)