diff options
| author | Jiale Yao <yaojiale02@163.com> | 2026-09-25 20:57:39 +0800 |
|---|---|---|
| committer | Jonathan Cameron <jonathan.cameron@oss.qualcomm.com> | 2026-09-28 17:07:34 +0100 |
| commit | 7f7a119a370ecf6c8d4ab9e9ee0a8cdd77afedd3 (patch) | |
| tree | f0e337f18be381234b3b4554782e787b0f140395 /tools/perf/scripts/python | |
| parent | 206fc54554c28d76c5d8f66091b846ef1dd88f64 (diff) | |
| download | linux-next-7f7a119a370ecf6c8d4ab9e9ee0a8cdd77afedd3.tar.gz linux-next-7f7a119a370ecf6c8d4ab9e9ee0a8cdd77afedd3.zip | |
iio: adc: ad7192: reject devices without match data
SPI driver_override allows a device to bind to this driver without
matching either the OF or SPI device ID table. In that case,
spi_get_device_match_data() returns NULL.
ad7192_probe() immediately dereferences the returned chip information
to initialize the IIO device, causing a NULL pointer dereference.
Commit 572a00852635 ("iio: dac: ad5686: missing NULL check on match
data") fixed the same driver_override issue in another SPI driver.
Reject devices without match data before using the chip information.
Fixes: c3708c829a06 ("iio: adc: ad7192: Convert from of specific to fwnode property handling")
Cc: stable@vger.kernel.org
Signed-off-by: Jiale Yao <yaojiale02@163.com>
Signed-off-by: Jonathan Cameron <jonathan.cameron@oss.qualcomm.com>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
