[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20170623090023.9482-1-colin.king@canonical.com>
Date: Fri, 23 Jun 2017 10:00:23 +0100
From: Colin King <colin.king@...onical.com>
To: David Woodhouse <dwmw2@...radead.org>,
Brian Norris <computersforpeace@...il.com>,
Boris Brezillon <boris.brezillon@...e-electrons.com>,
Marek Vasut <marek.vasut@...il.com>,
Richard Weinberger <richard@....at>,
Cyrille Pitchen <cyrille.pitchen@...ev4u.fr>,
Rafał Miłecki <rafal@...ecki.pl>,
linux-mtd@...ts.infradead.org
Cc: kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH][mtd-next] mtd: parser: print hex size_t value using correct %zx printk format specifier
From: Colin Ian King <colin.king@...onical.com>
Use %zx instead of %X for size_t variable offset, fixes build warning:
warning: format '%X' expects argument of type 'unsigned int', but argument
2 has type 'size_t {aka long unsigned int}' [-Wformat=]
Signed-off-by: Colin Ian King <colin.king@...onical.com>
---
drivers/mtd/parsers/parser_trx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mtd/parsers/parser_trx.c b/drivers/mtd/parsers/parser_trx.c
index e805108afd31..c0539555fac3 100644
--- a/drivers/mtd/parsers/parser_trx.c
+++ b/drivers/mtd/parsers/parser_trx.c
@@ -39,7 +39,7 @@ static const char *parser_trx_data_part_name(struct mtd_info *master,
err = mtd_read(master, offset, sizeof(buf), &bytes_read,
(uint8_t *)&buf);
if (err && !mtd_is_bitflip(err)) {
- pr_err("mtd_read error while parsing (offset: 0x%X): %d\n",
+ pr_err("mtd_read error while parsing (offset: 0x%zx): %d\n",
offset, err);
goto out_default;
}
--
2.11.0
Powered by blists - more mailing lists