summaryrefslogtreecommitdiff
path: root/drivers/input/misc/adxl34x.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2021-10-13 05:46:37 +0300
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2021-10-16 04:39:32 +0300
commit804f354ab6ce6668244db6d4c2da8e481ad89fb5 (patch)
tree7c77c4019ebc1dbf293461df9d9edc934ee9c7f6 /drivers/input/misc/adxl34x.c
parentc4be5e5a113d78490c426b1124fd458a9d807933 (diff)
downloadlinux-804f354ab6ce6668244db6d4c2da8e481ad89fb5.tar.xz
Input: adxl34x - fix sparse warning
This fixes the following warning from sparse: CC [M] drivers/input/misc/adxl34x.o CHECK drivers/input/misc/adxl34x.c drivers/input/misc/adxl34x.c:245:29: warning: cast to restricted __le16 drivers/input/misc/adxl34x.c:248:29: warning: cast to restricted __le16 drivers/input/misc/adxl34x.c:251:29: warning: cast to restricted __le16 Acked-by: Michael Hennerich <michael.hennerich@analog.com> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/YWZIjb91d6aAwgss@google.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/misc/adxl34x.c')
-rw-r--r--drivers/input/misc/adxl34x.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/input/misc/adxl34x.c b/drivers/input/misc/adxl34x.c
index 34beac80e6f0..a4af314392a9 100644
--- a/drivers/input/misc/adxl34x.c
+++ b/drivers/input/misc/adxl34x.c
@@ -237,7 +237,7 @@ static const struct adxl34x_platform_data adxl34x_default_init = {
static void adxl34x_get_triple(struct adxl34x *ac, struct axis_triple *axis)
{
- short buf[3];
+ __le16 buf[3];
ac->bops->read_block(ac->dev, DATAX0, DATAZ1 - DATAX0 + 1, buf);