The drivers do not require their own error messages for error
-ENOMEM, memory allocation failures. So remove the dev_err
messages from the probe().
Signed-off-by: Dixit Parmar <dixitparmar19@gmail.com>
---
drivers/iio/pressure/dlhl60d.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/iio/pressure/dlhl60d.c b/drivers/iio/pressure/dlhl60d.c
index 48afe5c94000..c5f4f5efaef8 100644
--- a/drivers/iio/pressure/dlhl60d.c
+++ b/drivers/iio/pressure/dlhl60d.c
@@ -294,10 +294,8 @@ static int dlh_probe(struct i2c_client *client)
}
indio_dev = devm_iio_device_alloc(&client->dev, sizeof(*st));
- if (!indio_dev) {
- dev_err(&client->dev, "failed to allocate iio device\n");
+ if (!indio_dev)
return -ENOMEM;
- }
i2c_set_clientdata(client, indio_dev);
--
2.43.0