projects
/
profile
/
ivi
/
kernel-adaptation-intel-automotive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
be344c8
)
iio staging: fix cast warning and cleanup alignment code
author
Peter Meerwald
<pmeerw@pmeerw.net>
Sat, 14 Jul 2012 16:23:00 +0000
(17:23 +0100)
committer
Jonathan Cameron
<jic23@kernel.org>
Sun, 15 Jul 2012 16:33:18 +0000
(17:33 +0100)
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/accel/lis3l02dq_ring.c
patch
|
blob
|
history
diff --git
a/drivers/staging/iio/accel/lis3l02dq_ring.c
b/drivers/staging/iio/accel/lis3l02dq_ring.c
index
d7f8af7
..
18d108f
100644
(file)
--- a/
drivers/staging/iio/accel/lis3l02dq_ring.c
+++ b/
drivers/staging/iio/accel/lis3l02dq_ring.c
@@
-151,8
+151,7
@@
static irqreturn_t lis3l02dq_trigger_handler(int irq, void *p)
/* Guaranteed to be aligned with 8 byte boundary */
if (indio_dev->scan_timestamp)
- *(s64 *)(((phys_addr_t)data + len
- + sizeof(s64) - 1) & ~(sizeof(s64) - 1))
+ *(s64 *)((u8 *)data + ALIGN(len, sizeof(s64)))
= pf->timestamp;
buffer->access->store_to(buffer, (u8 *)data, pf->timestamp);