]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
iio: pressure: rohm-bm1390: Remove redundant if statement
authorColin Ian King <colin.i.king@intel.com>
Thu, 10 Oct 2024 17:08:35 +0000 (18:08 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Thu, 10 Oct 2024 18:06:19 +0000 (19:06 +0100)
There is a check on non-zero ret that is redundant because the
same check is being performed in a previous if statement and
also before that. The check is not required, remove it.

Signed-off-by: Colin Ian King <colin.i.king@intel.com>
Link: https://patch.msgid.link/20241010170835.772764-1-colin.i.king@gmail.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/pressure/rohm-bm1390.c

index ccaa07a569c9a8a07c6965ef0cf4ba4a734a42ee..f24d9f92768123fee772320fcecf906e69c23c40 100644 (file)
@@ -417,9 +417,6 @@ static int __bm1390_fifo_flush(struct iio_dev *idev, unsigned int samples,
                        return ret;
        }
 
-       if (ret)
-               return ret;
-
        for (i = 0; i < smp_lvl; i++) {
                buffer[i].temp = temp;
                iio_push_to_buffers(idev, &buffer[i]);