This removes the call to spi_setup() in the ad2s1210 driver. Setting MODE_3 was incorrect. It should be MODE_1 but we can let the device tree select this and avoid the need to call spi_setup(). This issue has been fixed by the following patch which can be cleanly applied to the 5.10/5.15/6.1.y branches.
From: David Lechner dlechner@baylibre.com
commit 9829ebacea804ad4b5d1a74a8d94a1f843505546 upstream.
This removes the call to spi_setup() in the ad2s1210 driver. Setting MODE_3 was incorrect. It should be MODE_1 but we can let the device tree select this and avoid the need to call spi_setup().
Signed-off-by: David Lechner dlechner@baylibre.com Link: https://lore.kernel.org/r/20230929-ad2s1210-mainline-v3-3-fa4364281745@bayli... Signed-off-by: Jonathan Cameron Jonathan.Cameron@huawei.com Signed-off-by: Aleksandr Mishin amishin@t-argos.ru --- drivers/staging/iio/resolver/ad2s1210.c | 2 -- 1 file changed, 2 deletions(-)
diff --git a/drivers/staging/iio/resolver/ad2s1210.c b/drivers/staging/iio/resolver/ad2s1210.c index 636c45b12843..42aab1ac3aac 100644 --- a/drivers/staging/iio/resolver/ad2s1210.c +++ b/drivers/staging/iio/resolver/ad2s1210.c @@ -681,8 +681,6 @@ static int ad2s1210_probe(struct spi_device *spi) return ret;
st->fclkin = spi->max_speed_hz; - spi->mode = SPI_MODE_3; - spi_setup(spi); ad2s1210_initial(st);
return 0;
linux-stable-mirror@lists.linaro.org