Skip to content

Commit 785e21c

Browse files
jwrdegoedewsakernel
authored andcommitted
i2c: core: Do not print duplicate error when failing to register an i2c-client from ACPI
i2c_new_client_device() already prints an error when it fails. Some ACPI tables contain 2 ACPI devices describing the same i2c-client, leading to errors like this: [ 1.620847] i2c i2c-4: Failed to register i2c client MAGN0001:00 at 0x1d (-16) [ 1.620870] i2c i2c-4: failed to add I2C device MAGN0001:00 from ACPI There is nothing we can do about the first -EBUSY error being logged, but the second error does not really add any new information, so lets drop it. Signed-off-by: Hans de Goede <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Reviewed-by: Mika Westerberg <[email protected]> Signed-off-by: Wolfram Sang <[email protected]>
1 parent e71ba94 commit 785e21c

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

drivers/i2c/i2c-core-acpi.c

+1-5
Original file line numberDiff line numberDiff line change
@@ -225,12 +225,8 @@ static void i2c_acpi_register_device(struct i2c_adapter *adapter,
225225
adev->power.flags.ignore_parent = true;
226226
acpi_device_set_enumerated(adev);
227227

228-
if (IS_ERR(i2c_new_client_device(adapter, info))) {
228+
if (IS_ERR(i2c_new_client_device(adapter, info)))
229229
adev->power.flags.ignore_parent = false;
230-
dev_err(&adapter->dev,
231-
"failed to add I2C device %s from ACPI\n",
232-
dev_name(&adev->dev));
233-
}
234230
}
235231

236232
static acpi_status i2c_acpi_add_device(acpi_handle handle, u32 level,

0 commit comments

Comments
 (0)