]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
i2c: octeon: remove unused signal handling
authorNicholas Mc Guire <hofrat@osadl.org>
Thu, 11 Jun 2015 14:12:03 +0000 (16:12 +0200)
committerWolfram Sang <wsa@the-dreams.de>
Wed, 17 Jun 2015 12:50:03 +0000 (14:50 +0200)
'commit 2637e5fd232d ("i2c: octeon: Fix i2c fail problem when a process is
terminated by a signal")' removed the wait_event_interruptible_timeout to
prevent half/mixed i2c messages from being sent/recievd but forgot to
drop the signal handling case in the return handling. This just removes
this dead code. While at it the return variable is adjusted to the type
expected.

Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
Reviewed-by: Alexander Sverdlin <alexander.sverdlin@nokia.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/busses/i2c-octeon.c

index 6e75e016bffcd8196a96aceaee312b441fe04ae5..32914ab42a1968b359c68beb307b80d99d04d38c 100644 (file)
@@ -200,7 +200,7 @@ static int octeon_i2c_test_iflg(struct octeon_i2c *i2c)
  */
 static int octeon_i2c_wait(struct octeon_i2c *i2c)
 {
-       int result;
+       long result;
 
        octeon_i2c_int_enable(i2c);
 
@@ -210,10 +210,7 @@ static int octeon_i2c_wait(struct octeon_i2c *i2c)
 
        octeon_i2c_int_disable(i2c);
 
-       if (result < 0) {
-               dev_dbg(i2c->dev, "%s: wait interrupted\n", __func__);
-               return result;
-       } else if (result == 0) {
+       if (result == 0) {
                dev_dbg(i2c->dev, "%s: timeout\n", __func__);
                return -ETIMEDOUT;
        }