[PATCH 1/3] iio: adc: xilinx-ams: fix out-of-bounds channel lookup in event handling

Guilherme Ivo Bozi guilherme.bozi em usp.br
Qua Abr 15 00:34:35 -03 2026


> ams_event_to_channel() may return a pointer past the end of
> dev->channels when no matching scan_index is found. This can lead
> to invalid memory access in ams_handle_event().
>
> Add a bounds check in ams_event_to_channel() and return NULL when
> no channel is found. Also guard the caller to safely handle this
> case.

Testing the reply-to sending

--
With Best Regards,
Guilherme Ivo Bozi


Mais detalhes sobre a lista de discussão kernel