public inbox for kernel-janitors@vger.kernel.org
 help / color / mirror / Atom feed
* [patch] tracing: remove unneeded NULL check
@ 2014-11-22 18:30 Dan Carpenter
  0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2014-11-22 18:30 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: Ingo Molnar, linux-kernel, kernel-janitors

We checked "iter->trace" earlier so there is no need to check here.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
index 9ddd6aa..52fbbc5 100644
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -3019,7 +3019,7 @@ __tracing_open(struct inode *inode, struct file *file, bool snapshot)
 	mutex_init(&iter->mutex);
 
 	/* Notify the tracer early; before we stop tracing. */
-	if (iter->trace && iter->trace->open)
+	if (iter->trace->open)
 		iter->trace->open(iter);
 
 	/* Annotate start of buffers if we had overruns */

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2014-11-22 18:30 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-11-22 18:30 [patch] tracing: remove unneeded NULL check Dan Carpenter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox