iio: adc: ad4030: remove bits_per_word = 8
authorDavid Lechner <dlechner@baylibre.com>
Mon, 5 May 2025 19:20:28 +0000 (14:20 -0500)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Wed, 21 May 2025 13:20:30 +0000 (14:20 +0100)
Remove setting bits_per_word = 8 from the ad4030 driver. This is the
default value for SPI transfers, so it is not necessary to explicitly
set it.

Signed-off-by: David Lechner <dlechner@baylibre.com>
Reviewed-by: Nuno Sá <nuno.sa@analog.com>
Link: https://patch.msgid.link/20250505-iio-remove-bits_per_word-8-v1-1-341f85fcfe11@baylibre.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/ad4030.c

index 5aa26dc3a2cefed9bcaec1b9f3cc127d06aff19a..1bc2f9a2247081e166680232aa6d4aebc5f41b89 100644 (file)
@@ -244,7 +244,6 @@ static int ad4030_enter_config_mode(struct ad4030_state *st)
 
        struct spi_transfer xfer = {
                .tx_buf = st->tx_data,
-               .bits_per_word = 8,
                .len = 1,
                .speed_hz = AD4030_SPI_MAX_REG_XFER_SPEED,
        };
@@ -260,7 +259,6 @@ static int ad4030_exit_config_mode(struct ad4030_state *st)
 
        struct spi_transfer xfer = {
                .tx_buf = st->tx_data,
-               .bits_per_word = 8,
                .len = 3,
                .speed_hz = AD4030_SPI_MAX_REG_XFER_SPEED,
        };
@@ -276,7 +274,6 @@ static int ad4030_spi_read(void *context, const void *reg, size_t reg_size,
        struct spi_transfer xfer = {
                .tx_buf = st->tx_data,
                .rx_buf = st->rx_data.raw,
-               .bits_per_word = 8,
                .len = reg_size + val_size,
                .speed_hz = AD4030_SPI_MAX_REG_XFER_SPEED,
        };
@@ -311,7 +308,6 @@ static int ad4030_spi_write(void *context, const void *data, size_t count)
                        ((u8 *)data)[2] == 0x81;
        struct spi_transfer xfer = {
                .tx_buf = st->tx_data,
-               .bits_per_word = 8,
                .len = count,
                .speed_hz = AD4030_SPI_MAX_REG_XFER_SPEED,
        };