Skip to contentSkip to conversation

staging: gasket: Remove return variable

PATCH In review Nishka Dasgupta 3 participants 3 messages Mar 19, 2019 – Mar 24, 2019 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: gasket: Remove return variable

Remove return variable and return the return value directly. Issue suggested by ret.cocci.

---
 drivers/staging/gasket/apex_driver.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/staging/gasket/apex_driver.c +1 -3
index 0578bf1ba1e9..a5da9bbd8396 100644
@@ -439,9 +439,7 @@ static int apex_reset(struct gasket_dev *gasket_dev)
 		if (ret)
 			return ret;
 	}
-	ret = apex_quit_reset(gasket_dev);
-
-	return ret;
+	return apex_quit_reset(gasket_dev);
 }
 
 /*
Signature · 1 line
2.19.1
Acked-by on v1 1/1
#1 lore raw
Quoted 4 lines · Nishka Dasgupta' via outreachy-kernel

Remove return variable and return the return value directly. Issue suggested by ret.cocci.

Quoted 29 lines
---
 drivers/staging/gasket/apex_driver.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/staging/gasket/apex_driver.c +1 -4
index 0578bf1ba1e9..a5da9bbd8396 100644
@@ -439,9 +439,7 @@ static int apex_reset(struct gasket_dev *gasket_dev)
 		if (ret)
 			return ret;
 	}
-	ret = apex_quit_reset(gasket_dev);
-
-	return ret;
+	return apex_quit_reset(gasket_dev);
 }
 
 /*
--

2.19.1

--
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20190319192911.8526-1-nishka.dasgupta%40yahoo.com.
For more options, visit https://groups.google.com/d/optout.

Acked-by
#2 lore raw
Quoted 30 lines · Julia Lawall
Quoted 4 lines · Nishka Dasgupta' via outreachy-kernel

Remove return variable and return the return value directly. Issue suggested by ret.cocci.

Quoted 18 lines
---
 drivers/staging/gasket/apex_driver.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/staging/gasket/apex_driver.c +1 -3
index 0578bf1ba1e9..a5da9bbd8396 100644
@@ -439,9 +439,7 @@ static int apex_reset(struct gasket_dev *gasket_dev)
              if (ret)
                      return ret;
      }
-     ret = apex_quit_reset(gasket_dev);
-
-     return ret;
+     return apex_quit_reset(gasket_dev);
 }
 
Quoted 3 lines
Quoted 3 lines
drivers/staging/gasket/apex_driver.c +0 -1
 /*
--

2.19.1

Thanks.