staging: iio: isl29028: remove unnecessary error logging in isl29028_chip_init_and_po...
authorBrian Masney <masneyb@onstation.org>
Tue, 17 Jan 2017 09:24:56 +0000 (04:24 -0500)
committerJonathan Cameron <jic23@kernel.org>
Sun, 22 Jan 2017 13:21:36 +0000 (13:21 +0000)
If the call to isl29028_chip_init_and_power_on() in isl29028_probe()
fails, then isl29028_probe() will log an error message. All of the
error paths in that call path already have error logging in place. This
patch removes the unnecessary logging.

Signed-off-by: Brian Masney <masneyb@onstation.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/light/isl29028.c

index cffecf9d6bdecd4c0ad52ae49af5b56e2e77389d..be1fc4a8960e4827e91184d7c563beea4149ff98 100644 (file)
@@ -528,10 +528,8 @@ static int isl29028_probe(struct i2c_client *client,
        }
 
        ret = isl29028_chip_init_and_power_on(chip);
-       if (ret < 0) {
-               dev_err(&client->dev, "chip initialization failed: %d\n", ret);
+       if (ret < 0)
                return ret;
-       }
 
        indio_dev->info = &isl29028_info;
        indio_dev->channels = isl29028_channels;