Staging: vme: devices: Merges two lines of code and removes unused variable

Author: Mahati Chamarthy <mahati.chamarthy@gmail.com>

This patch merges an assignment with an immediately following return of
the assigned variable.  The following Coccinelle semantic patch was used
to make this transformation:

@@
expression ret;
identifier f;
@@

-ret =
+return
     f(...);
-return ret;

Signed-off-by: Mahati Chamarthy 
Signed-off-by: Greg Kroah-Hartman 
---
 drivers/staging/vme/devices/vme_user.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
 
diff --git a/drivers/staging/vme/devices/vme_user.c b/drivers/staging/vme/devices/vme_user.c
index 920e50a..73cec14 100644
--- a/drivers/staging/vme/devices/vme_user.c
+++ b/drivers/staging/vme/devices/vme_user.c
@@ -482,11 +482,9 @@ static int vme_user_ioctl(struct inode *inode, struct file *file,
 				return -EFAULT;
 			}
 
-			retval = vme_irq_generate(vme_user_bridge,
+			return vme_irq_generate(vme_user_bridge,
 						  irq_req.level,
 						  irq_req.statid);
-
-			return retval;
 		}
 		break;
 	case MASTER_MINOR:
BtrLinux
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.