OSDN Git Service
(root)
/
tomoyo
/
tomoyo-test1.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5e64897
)
staging:iio:hmc5843: Fix measurement conversion
author
Peter Meerwald
<pmeerw@pmeerw.net>
Tue, 3 Sep 2013 01:05:00 +0000
(
02:05
+0100)
committer
Jonathan Cameron
<jic23@kernel.org>
Wed, 18 Sep 2013 18:43:30 +0000
(19:43 +0100)
recently broken,
cd6fe06588423ff4cca85c85c4402027b04dccf1
staging:iio:hmc5843: Use i2c_smbus_read_word_swapped()
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/magnetometer/hmc5843.c
patch
|
blob
|
history
diff --git
a/drivers/staging/iio/magnetometer/hmc5843.c
b/drivers/staging/iio/magnetometer/hmc5843.c
index
d2748c3
..
c3f3f53
100644
(file)
--- a/
drivers/staging/iio/magnetometer/hmc5843.c
+++ b/
drivers/staging/iio/magnetometer/hmc5843.c
@@
-229,7
+229,7
@@
static int hmc5843_read_measurement(struct iio_dev *indio_dev,
if (result < 0)
return -EINVAL;
- *val =
result
;
+ *val =
sign_extend32(result, 15)
;
return IIO_VAL_INT;
}