aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFabian Frederick <fabf@skynet.be>2014-06-27 17:07:43 -0400
committerDavid S. Miller <davem@davemloft.net>2014-07-02 20:05:29 -0400
commitfb0d164cc1e46ddb22e8fac9f9cb94fdaeddd70f (patch)
tree32423811167d177312541d940764f9aeb3e84cef
parent9f16dc2ec7cb3527c66581ad762876ba1f774cdb (diff)
net/caif/caif_socket.c: remove unnecessary null test before debugfs_remove_recursive
based on checkpatch: "debugfs_remove_recursive(NULL) is safe this check is probably not required" Cc: Dmitry Tarnyagin <dmitry.tarnyagin@lockless.no> Cc: "David S. Miller" <davem@davemloft.net> Cc: netdev@vger.kernel.org Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/caif/caif_socket.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/caif/caif_socket.c b/net/caif/caif_socket.c
index e8437094d15f..43f750e88e19 100644
--- a/net/caif/caif_socket.c
+++ b/net/caif/caif_socket.c
@@ -908,8 +908,7 @@ static int caif_release(struct socket *sock)
908 sock->sk = NULL; 908 sock->sk = NULL;
909 909
910 WARN_ON(IS_ERR(cf_sk->debugfs_socket_dir)); 910 WARN_ON(IS_ERR(cf_sk->debugfs_socket_dir));
911 if (cf_sk->debugfs_socket_dir != NULL) 911 debugfs_remove_recursive(cf_sk->debugfs_socket_dir);
912 debugfs_remove_recursive(cf_sk->debugfs_socket_dir);
913 912
914 lock_sock(&(cf_sk->sk)); 913 lock_sock(&(cf_sk->sk));
915 sk->sk_state = CAIF_DISCONNECTED; 914 sk->sk_state = CAIF_DISCONNECTED;