Subject: [PATCH net-next 2/3] netdevice: remove useless else keyword

From: Jean Sacren <[email-masked]>
Date: Tue, 6 Aug 2013 01:32:50 -0600

Clean up multiple useless else keywords. Add empty lines for
readability.

Signed-off-by: Jean Sacren <[email-masked]>
---
 net/core/dev.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/net/core/dev.c b/net/core/dev.c
index 58eb802..1b0bea8 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -1062,9 +1062,11 @@ static int dev_get_valid_name(struct net *net,
 
 	if (strchr(name, '%'))
 		return dev_alloc_name_ns(net, dev, name);
-	else if (__dev_get_by_name(net, name))
+
+	if (__dev_get_by_name(net, name))
 		return -EEXIST;
-	else if (dev->name != name)
+
+	if (dev->name != name)
 		strlcpy(dev->name, name, IFNAMSIZ);
 
 	return 0;