git.openpandora.org
/
pandora-kernel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f7067a5
)
iio: imu: adis16400: Fix sign extension
author
Rasmus Villemoes
<linux@rasmusvillemoes.dk>
Thu, 22 Jan 2015 23:34:02 +0000
(
00:34
+0100)
committer
Jonathan Cameron
<jic23@kernel.org>
Mon, 26 Jan 2015 21:06:42 +0000
(21:06 +0000)
The intention is obviously to sign-extend a 12 bit quantity. But
because of C's promotion rules, the assignment is equivalent to "val16
&= 0xfff;". Use the proper API for this.
Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Cc: Stable@vger.kernel.org
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
No differences found