iio: chemical: sps30: fix buffer size calculations
Status from this message: Applied to the fixes-togreg branch of iio.git and marked for stable.
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | iio: chemical: sps30_i2c: fix buffer size in sps30_i2c_read_meas()drivers/ | +1 | 2 replies | |
| 2/2 | iio: chemical: sps30_serial: fix buffer size in sps30_serial_read_meas()drivers/ | +1 | 2 replies |
Reviews trailers per patch
All 2 patches have a Reviewed-by or Acked-by.
| Patch | Andy Shevchenko | Tomasz Duszynski |
|---|---|---|
| 1/2 | R-b | A-b |
| 2/2 | R-b | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/2] iio: chemical: sps30: fix buffer size calculations
Fix incorrect buffer size calculations in sps30_i2c_read_meas() and sps30_serial_read_meas(). Both functions used sizeof(num) which evaluates to sizeof(size_t) (8 bytes on 64-bit) instead of sizeof(*meas) (4 bytes for __be32), leading to oversized buffer requests.
Antoniu Miclaus (2):
iio: chemical: sps30_i2c: fix buffer size in sps30_i2c_read_meas()
iio: chemical: sps30_serial: fix buffer size in
sps30_serial_read_meas()
drivers/iio/chemical/sps30_i2c.c | 2 +- drivers/iio/chemical/sps30_serial.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
Signature · 1 line
2.43.0