diff options
author | Wolfram Sang <wsa+renesas@sang-engineering.com> | 2020-07-25 17:07:36 +0300 |
---|---|---|
committer | Wolfram Sang <wsa@kernel.org> | 2020-07-27 21:16:58 +0300 |
commit | 8be23aec0ee151de731626d5578973fde25b2285 (patch) | |
tree | 4fb66bd92b8a4a8bdda7b9462f8f46b84ce9e9e4 /include | |
parent | 92ed301919932f777713b9172e525674157e983d (diff) | |
download | linux-8be23aec0ee151de731626d5578973fde25b2285.tar.xz |
i2c: also convert placeholder function to return errno
All i2c_new_device-alike functions return ERR_PTR these days, but this
fallback function was missed.
Fixes: 2dea645ffc21 ("i2c: acpi: Return error pointers from i2c_acpi_new_device()")
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
[wsa: changed from 'ENOSYS' to 'ENODEV']
Signed-off-by: Wolfram Sang <wsa@kernel.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/i2c.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/i2c.h b/include/linux/i2c.h index ee328cf80bd9..4e7714c88f95 100644 --- a/include/linux/i2c.h +++ b/include/linux/i2c.h @@ -1001,7 +1001,7 @@ static inline u32 i2c_acpi_find_bus_speed(struct device *dev) static inline struct i2c_client *i2c_acpi_new_device(struct device *dev, int index, struct i2c_board_info *info) { - return NULL; + return ERR_PTR(-ENODEV); } static inline struct i2c_adapter *i2c_acpi_find_adapter_by_handle(acpi_handle handle) { |