]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
iio: pressure: Drop unnecessary -ENOMEM messages
authorDixit Parmar <dixitparmar19@gmail.com>
Fri, 22 Aug 2025 03:49:56 +0000 (09:19 +0530)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Mon, 25 Aug 2025 11:36:50 +0000 (12:36 +0100)
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>
Link: https://patch.msgid.link/20250822-enomam_logs-v1-8-db87f2974552@gmail.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/pressure/dlhl60d.c

index 6a13cf2eaf50187d4cbd94cd93b1d14ad4de8b26..8bad7162fec64ba1eef45ae3fa944b45573318f4 100644 (file)
@@ -289,10 +289,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);