diff options
| author | Javier Carrasco <[email protected]> | 2024-12-02 19:18:44 +0000 |
|---|---|---|
| committer | Jonathan Cameron <[email protected]> | 2024-12-08 16:59:13 +0000 |
| commit | 54d394905c92b9ecc65c1f9b2692c8e10716d8e1 (patch) | |
| tree | 24c86b7f7fb061bac2bc2d52304dadb4f2dc0537 /net/unix/af_unix.c | |
| parent | iio: temperature: tmp006: fix information leak in triggered buffer (diff) | |
| download | kernel-54d394905c92b9ecc65c1f9b2692c8e10716d8e1.tar.gz kernel-54d394905c92b9ecc65c1f9b2692c8e10716d8e1.zip | |
iio: adc: ti-ads1119: fix sample size in scan struct for triggered buffer
This device returns signed, 16-bit samples as stated in its datasheet
(see 8.5.2 Data Format). That is in line with the scan_type definition
for the IIO_VOLTAGE channel, but 'unsigned int' is being used to read
and push the data to userspace.
Given that the size of that type depends on the architecture (at least
2 bytes to store values up to 65535, but its actual size is often 4
bytes), use the 's16' type to provide the same structure in all cases.
Fixes: a9306887eba4 ("iio: adc: ti-ads1119: Add driver")
Signed-off-by: Javier Carrasco <[email protected]>
Reviewed-by: Francesco Dolcini <[email protected]>
Link: https://patch.msgid.link/[email protected]
Cc: <[email protected]>
Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions
