]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
spi: spidev: Remove unneeded variable
authorFabio Estevam <fabio.estevam@freescale.com>
Sat, 9 May 2015 15:57:19 +0000 (12:57 -0300)
committerMark Brown <broonie@kernel.org>
Mon, 11 May 2015 15:14:57 +0000 (16:14 +0100)
Remove unneeded variable used to store return value.

The semantic patch that makes this change is available
in scripts/coccinelle/misc/returnvar.cocci.

More information about semantic patching is available at
http://coccinelle.lip6.fr/

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spidev.c

index eb0a075b23a2222eba583225afc3844b455cfb96..dba7b4624b998b0915069b480721087156dd123e 100644 (file)
@@ -616,7 +616,6 @@ err_find_dev:
 static int spidev_release(struct inode *inode, struct file *filp)
 {
        struct spidev_data      *spidev;
-       int                     status = 0;
 
        mutex_lock(&device_list_lock);
        spidev = filp->private_data;
@@ -645,7 +644,7 @@ static int spidev_release(struct inode *inode, struct file *filp)
        }
        mutex_unlock(&device_list_lock);
 
-       return status;
+       return 0;
 }
 
 static const struct file_operations spidev_fops = {