[PATCH 2/2] iio:adc:ti-ads124s08: Fix packet read from the ADC

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Fix the spi_transfer array in the reading of the data from the ADC.

Fixes: ("e717f8c6dfec iio: adc: Add the TI ads124s08 ADC code")
Signed-off-by: Dan Murphy <dmurphy@xxxxxx>
---
 drivers/iio/adc/ti-ads124s08.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/iio/adc/ti-ads124s08.c b/drivers/iio/adc/ti-ads124s08.c
index f05d4e0e1c9d..023d81c7e8da 100644
--- a/drivers/iio/adc/ti-ads124s08.c
+++ b/drivers/iio/adc/ti-ads124s08.c
@@ -201,12 +201,10 @@ static int ads124s_read(struct iio_dev *indio_dev, unsigned int chan)
 	struct spi_transfer t[] = {
 		{
 			.tx_buf = &priv->data[0],
-			.len = 4,
-			.cs_change = 1,
 		}, {
-			.tx_buf = &priv->data[1],
 			.rx_buf = &priv->data[1],
 			.len = 4,
+			.cs_change = 1,
 		},
 	};
 
-- 
2.29.2




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux