aboutsummaryrefslogtreecommitdiff
path: root/drivers/usb/cdns3/cdns3-debug.h
diff options
context:
space:
mode:
authorMatti Vaittinen <[email protected]>2023-10-03 12:57:47 +0300
committerJonathan Cameron <[email protected]>2023-10-05 16:16:20 +0100
commit2d3dff577dd0ea8fe9637a13822f7603c4a881c8 (patch)
treedf53721a51779094af01bfeefe9ebc6a2ff67746 /drivers/usb/cdns3/cdns3-debug.h
parent848f68c760ab1e14a9046ea6e45e3304ab9fa50b (diff)
tools: iio: iio_generic_buffer ensure alignment
The iio_generic_buffer can return garbage values when the total size of scan data is not a multiple of the largest element in the scan. This can be demonstrated by reading a scan, consisting, for example of one 4-byte and one 2-byte element, where the 4-byte element is first in the buffer. The IIO generic buffer code does not take into account the last two padding bytes that are needed to ensure that the 4-byte data for next scan is correctly aligned. Add the padding bytes required to align the next sample with the scan size. Signed-off-by: Matti Vaittinen <[email protected]> Fixes: e58537ccce73 ("staging: iio: update example application.") Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-debug.h')
0 files changed, 0 insertions, 0 deletions