Re: [PATCH] iio: adc: mt6577_auxadc: Fix kernel panic on suspend

From: Alexandre Mergnat
Date: Tue Oct 10 2023 - 08:35:12 EST


Reviewed-by: Alexandre Mergnat <amergnat@xxxxxxxxxxxx>

On 10/10/2023 14:19, AngeloGioacchino Del Regno wrote:
Commit a2d518fbe376 ("iio: adc: mt6577_auxadc: Simplify with device managed function") simplified the driver with devm hooks, but wrongly states that the platform_set_drvdata(), platform_get_drvdata() are unused after the simplification: the driver data is infact used in .suspend() and .resume() PM callbacks, currently producing a kernel panic. Reintroduce the call to platform_set_drvdata() in the probe function

--
Regards,
Alexandre