Re: [PATCH v2 next 1/5] iio: sca3000: cache SPI device ID in probe
From: David Lechner
Date: Mon Feb 02 2026 - 18:04:39 EST
On 2/2/26 1:40 PM, Harshit Mogalapalli wrote:
> Store the spi_device_id at probe entry and reuse it for the name and
> chip info instead of calling spi_get_device_id() repeatedly.
Even better would be to replace spi_get_device_id() with
pi_get_device_match_data() and turn sca3000_spi_chip_info_tbl[]
into individual structs that are used directly as the match
data pointers.
>
> Reuse the local dev pointer for resource managed helpers. While at it,
> reshuffle variable list in a reverse Christmas tree order.
The dev cleanup sounds like a second unrelated change that can be split
out from the spi_get_device_id() changes.