summaryrefslogtreecommitdiffstats
path: root/net/caif
diff options
context:
space:
mode:
authorFabian Frederick <fabf@skynet.be>2014-06-27 23:07:43 +0200
committerDavid S. Miller <davem@davemloft.net>2014-07-02 17:05:29 -0700
commitfb0d164cc1e46ddb22e8fac9f9cb94fdaeddd70f (patch)
tree32423811167d177312541d940764f9aeb3e84cef /net/caif
parent9f16dc2ec7cb3527c66581ad762876ba1f774cdb (diff)
downloadlinux-fb0d164cc1e46ddb22e8fac9f9cb94fdaeddd70f.tar.bz2
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>
Diffstat (limited to 'net/caif')
-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)
sock->sk = NULL;
WARN_ON(IS_ERR(cf_sk->debugfs_socket_dir));
- if (cf_sk->debugfs_socket_dir != NULL)
- debugfs_remove_recursive(cf_sk->debugfs_socket_dir);
+ debugfs_remove_recursive(cf_sk->debugfs_socket_dir);
lock_sock(&(cf_sk->sk));
sk->sk_state = CAIF_DISCONNECTED;