diff options
| author | Ethan Tidmore <ethantidmore06@gmail.com> | 2026-02-14 12:46:37 -0600 |
|---|---|---|
| committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2026-02-23 08:24:38 +0000 |
| commit | dd6183e42719cc54057579b8e6be5348cecfeda7 (patch) | |
| tree | 0d576817331304c32e7c66012c6760c85e646bcd /scripts/rt-tester/git@git.tavy.me:linux.git | |
| parent | c3914ce1963c4db25e186112c90fa5d2361e9e0a (diff) | |
iio: adc: ad7768-1: Fix ERR_PTR dereference in ad7768_fill_scale_tbl
The function iio_get_current_scan_type() can return an error pointer,
the return value scan_type is not checked for this and immediately
dereferenced which can cause a kernel panic.
Add check for IS_ERR() and propagate the error back.
Fixes: ff085189cb17 ("iio: adc: ad7768-1: add support for ADAQ776x-1 ADC Family")
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <error27@gmail.com>
Closes: https://lore.kernel.org/r/202602051234.5gArzLyZ-lkp@intel.com/
Signed-off-by: Ethan Tidmore <ethantidmore06@gmail.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'scripts/rt-tester/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions
