]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
iio: adc: ad7380: remove unused oversampling_ratio getter
authorDavid Lechner <dlechner@baylibre.com>
Tue, 24 Jun 2025 22:44:51 +0000 (22:44 +0000)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sun, 6 Jul 2025 09:37:51 +0000 (10:37 +0100)
Remove a call to ad7380_get_osr() in ad7380_init_offload_msg. The
returned value is never used.

Signed-off-by: David Lechner <dlechner@baylibre.com>
Reviewed-by: Nuno Sá <nuno.sa@analog.com>
Link: https://patch.msgid.link/20250624-iio-adc-ad7380-remove-unused-oversampling_ratio-getter-v1-1-26cbee356860@baylibre.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/ad7380.c

index d96bd12dfea632b62475d6537c8d6601b042de1f..abcd4cc70074723303b9b67e2b89b0c4b43c6884 100644 (file)
@@ -1165,7 +1165,6 @@ static int ad7380_init_offload_msg(struct ad7380_state *st,
        struct spi_transfer *xfer = &st->offload_xfer;
        struct device *dev = &st->spi->dev;
        const struct iio_scan_type *scan_type;
-       int oversampling_ratio;
        int ret;
 
        scan_type = iio_get_current_scan_type(indio_dev,
@@ -1195,10 +1194,6 @@ static int ad7380_init_offload_msg(struct ad7380_state *st,
                }
        }
 
-       ret = ad7380_get_osr(st, &oversampling_ratio);
-       if (ret)
-               return ret;
-
        xfer->bits_per_word = scan_type->realbits;
        xfer->offload_flags = SPI_OFFLOAD_XFER_RX_STREAM;
        xfer->len = AD7380_SPI_BYTES(scan_type) * st->chip_info->num_simult_channels;