aboutsummaryrefslogtreecommitdiffstats
path: root/net/l2tp
diff options
context:
space:
mode:
authorstephen hemminger <stephen@networkplumber.org>2014-02-12 23:51:22 -0500
committerDavid S. Miller <davem@davemloft.net>2014-02-13 18:33:38 -0500
commit2045ceaed4d54e6e698874d008be727ee5b2a01c (patch)
treea481bc211dd20db90275aceab3721c7a8fb147d9 /net/l2tp
parent45f7435968363816f8fc4c6abef692808534140d (diff)
net: remove unnecessary return's
One of my pet coding style peeves is the practice of adding extra return; at the end of function. Kill several instances of this in network code. I suppose some coccinelle wizardy could do this automatically. Signed-off-by: Stephen Hemminger <stephen@networkplumber.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/l2tp')
-rw-r--r--net/l2tp/l2tp_core.c2
-rw-r--r--net/l2tp/l2tp_ppp.c3
2 files changed, 0 insertions, 5 deletions
diff --git a/net/l2tp/l2tp_core.c b/net/l2tp/l2tp_core.c
index 735d0f60c83a..e5dc42f0e527 100644
--- a/net/l2tp/l2tp_core.c
+++ b/net/l2tp/l2tp_core.c
@@ -1809,8 +1809,6 @@ void l2tp_session_free(struct l2tp_session *session)
1809 } 1809 }
1810 1810
1811 kfree(session); 1811 kfree(session);
1812
1813 return;
1814} 1812}
1815EXPORT_SYMBOL_GPL(l2tp_session_free); 1813EXPORT_SYMBOL_GPL(l2tp_session_free);
1816 1814
diff --git a/net/l2tp/l2tp_ppp.c b/net/l2tp/l2tp_ppp.c
index be5fadf34739..ec40bc344be6 100644
--- a/net/l2tp/l2tp_ppp.c
+++ b/net/l2tp/l2tp_ppp.c
@@ -454,13 +454,11 @@ static void pppol2tp_session_close(struct l2tp_session *session)
454 454
455 BUG_ON(session->magic != L2TP_SESSION_MAGIC); 455 BUG_ON(session->magic != L2TP_SESSION_MAGIC);
456 456
457
458 if (sock) { 457 if (sock) {
459 inet_shutdown(sock, 2); 458 inet_shutdown(sock, 2);
460 /* Don't let the session go away before our socket does */ 459 /* Don't let the session go away before our socket does */
461 l2tp_session_inc_refcount(session); 460 l2tp_session_inc_refcount(session);
462 } 461 }
463 return;
464} 462}
465 463
466/* Really kill the session socket. (Called from sock_put() if 464/* Really kill the session socket. (Called from sock_put() if
@@ -474,7 +472,6 @@ static void pppol2tp_session_destruct(struct sock *sk)
474 BUG_ON(session->magic != L2TP_SESSION_MAGIC); 472 BUG_ON(session->magic != L2TP_SESSION_MAGIC);
475 l2tp_session_dec_refcount(session); 473 l2tp_session_dec_refcount(session);
476 } 474 }
477 return;
478} 475}
479 476
480/* Called when the PPPoX socket (session) is closed. 477/* Called when the PPPoX socket (session) is closed.