]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
auxdisplay: ht16k33: Remove unneeded error check in keypad probe()
authorGeert Uytterhoeven <geert@linux-m68k.org>
Tue, 19 Oct 2021 14:45:11 +0000 (16:45 +0200)
committerMiguel Ojeda <ojeda@kernel.org>
Thu, 21 Oct 2021 21:36:29 +0000 (23:36 +0200)
There is no need to check the return code of input_register_device(),
just propagate it to the caller.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Robin van der Gracht <robin@protonic.nl>
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
drivers/auxdisplay/ht16k33.c

index fed2f8bd2d27c65ba4e533919712cdf0403ca65e..1ce73c4172c89244b4cfa89468e6fec660de2470 100644 (file)
@@ -388,11 +388,7 @@ static int ht16k33_keypad_probe(struct i2c_client *client,
 
        ht16k33_keypad_stop(keypad->dev);
 
-       err = input_register_device(keypad->dev);
-       if (err)
-               return err;
-
-       return 0;
+       return input_register_device(keypad->dev);
 }
 
 static int ht16k33_probe(struct i2c_client *client,