[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200115200250.10849-3-krzk@kernel.org>
Date: Wed, 15 Jan 2020 21:02:50 +0100
From: Krzysztof Kozlowski <krzk@...nel.org>
To: Wolfram Sang <wsa@...-dreams.de>
Cc: Vladimir Zapolskiy <vz@...ia.com>,
Sylvain Lemieux <slemieux.tyco@...il.com>,
Linus Walleij <linus.walleij@...aro.org>,
Arnd Bergmann <arnd@...db.de>, linux-i2c@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
Jean Delvare <jdelvare@...e.de>,
Jarkko Nikula <jarkko.nikula@...ux.intel.com>,
Krzysztof Kozlowski <krzk@...nel.org>
Subject: [PATCH v3 3/3] i2c: highlander: Use proper printk format for size_t
size_t should be printed with its own format to be 64-bit friendly and
fix warning when compiling on 64-bit platform (e.g. with COMPILE_TEST):
drivers/i2c/busses/i2c-highlander.c: In function ‘highlander_i2c_smbus_xfer’:
drivers/i2c/busses/i2c-highlander.c:325:22: warning:
format ‘%d’ expects argument of type ‘int’,
but argument 3 has type ‘size_t {aka long unsigned int}’ [-Wformat=]
Signed-off-by: Krzysztof Kozlowski <krzk@...nel.org>
---
Changes since v2:
1. Rewrite incorrect commit msg.
Changes since v1:
1. None
---
drivers/i2c/busses/i2c-highlander.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/i2c/busses/i2c-highlander.c b/drivers/i2c/busses/i2c-highlander.c
index abfe3094c047..803dad70e2a7 100644
--- a/drivers/i2c/busses/i2c-highlander.c
+++ b/drivers/i2c/busses/i2c-highlander.c
@@ -322,7 +322,7 @@ static int highlander_i2c_smbus_xfer(struct i2c_adapter *adap, u16 addr,
tmp |= (SMMR_MODE0 | SMMR_MODE1);
break;
default:
- dev_err(dev->dev, "unsupported xfer size %d\n", dev->buf_len);
+ dev_err(dev->dev, "unsupported xfer size %zu\n", dev->buf_len);
return -EINVAL;
}
--
2.17.1
Powered by blists - more mailing lists