Skip to content

Commit 512b0f4

Browse files
tobluxdtor
authored andcommitted
Input: qt1050 - inline i2c_check_functionality check
Inline the i2c_check_functionality() check, since the function returns a boolean status rather than an error code. Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev> Link: https://patch.msgid.link/20260408141926.1181389-3-thorsten.blum@linux.dev Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
1 parent 95dffe3 commit 512b0f4

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

drivers/input/keyboard/qt1050.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -435,8 +435,7 @@ static int qt1050_probe(struct i2c_client *client)
435435
int err;
436436

437437
/* Check basic functionality */
438-
err = i2c_check_functionality(client->adapter, I2C_FUNC_SMBUS_BYTE);
439-
if (!err) {
438+
if (!i2c_check_functionality(client->adapter, I2C_FUNC_SMBUS_BYTE)) {
440439
dev_err(&client->dev, "%s adapter not supported\n",
441440
dev_driver_string(&client->adapter->dev));
442441
return -ENODEV;

0 commit comments

Comments
 (0)