tracing: Deletion of an unnecessary check before iput()

Author: Markus Elfring <>

The iput() function tests whether its argument is NULL and then
returns immediately. Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.


Signed-off-by: Markus Elfring 
Signed-off-by: Steven Rostedt 
 kernel/trace/trace_uprobe.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/kernel/trace/trace_uprobe.c b/kernel/trace/trace_uprobe.c
index fd76f8e..8520acc 100644
--- a/kernel/trace/trace_uprobe.c
+++ b/kernel/trace/trace_uprobe.c
@@ -552,8 +552,7 @@ error:
 	return ret;
-	if (inode)
-		iput(inode);
+	iput(inode);
 	pr_info("Failed to parse address or file.\n");