[PATCH v3 04/13] iio: adc: at91-sama5d2_adc: adapt the driver for sama7d65

Jonathan Cameron jic23 at kernel.org
Tue Jun 30 16:43:13 PDT 2026


On Tue, 30 Jun 2026 15:05:54 +0530
Varshini Rajendran <varshini.rajendran at microchip.com> wrote:

> Add support for sama7d65 ADC. The differences are highlighted with the
> compatible. The calibration data layout is the main difference.
> 
> Update Kconfig help text to mention SAMA7 SoC family support.
> 
> Signed-off-by: Varshini Rajendran <varshini.rajendran at microchip.com>
> @@ -2639,6 +2667,9 @@ static const struct of_device_id at91_adc_dt_match[] = {
>  	}, {
>  		.compatible = "microchip,sama7g5-adc",
>  		.data = (const void *)&sama7g5_platform,
> +	}, {
> +		.compatible = "microchip,sama7d65-adc",
> +		.data = (const void *)&sama7d65_platform,
Silly question for you that is more about the original code than what you
are adding, but why the casts?  It is already a const pointer so I think
we are fine under the C spec to just do this cast implicitly to a const
void *

If you agree, ideally please add a precursor patch to drop these casts
before this patch.

Thanks,

Jonathan

>  	}, {
>  		/* sentinel */
>  	}




More information about the linux-arm-kernel mailing list