Skip to content

Commit 2375083

Browse files
jic23jfvogel
authored andcommitted
iio: adc: ad7768-1: Fix insufficient alignment of timestamp.
[ Upstream commit ffbc26bc91c1f1eb3dcf5d8776e74cbae21ee13a ] On architectures where an s64 is not 64-bit aligned, this may result insufficient alignment of the timestamp and the structure being too small. Use aligned_s64 to force the alignment. Fixes: a1caeeb ("iio: adc: ad7768-1: Fix too small buffer passed to iio_push_to_buffers_with_timestamp()") # aligned_s64 newer Reported-by: David Lechner <[email protected]> Reviewed-by: Nuno Sá <[email protected]> Reviewed-by: David Lechner <[email protected]> Link: https://patch.msgid.link/[email protected] Cc: <[email protected]> Signed-off-by: Jonathan Cameron <[email protected]> Signed-off-by: Sasha Levin <[email protected]> (cherry picked from commit 7b16d3c36123f88125493886e1ac58bf2ba59234) Signed-off-by: Jack Vogel <[email protected]>
1 parent d5088f6 commit 2375083

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/iio/adc/ad7768-1.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ struct ad7768_state {
169169
union {
170170
struct {
171171
__be32 chan;
172-
s64 timestamp;
172+
aligned_s64 timestamp;
173173
} scan;
174174
__be32 d32;
175175
u8 d8[2];

0 commit comments

Comments
 (0)