From: Steven Rostedt <rostedt@goodmis.org>
To: "Masami Hiramatsu (Google)" <mhiramat@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
Linux Trace Kernel <linux-trace-kernel@vger.kernel.org>,
Mark Rutland <mark.rutland@arm.com>,
Zheng Yejian <zhengyejian1@huawei.com>
Subject: Re: [PATCH 2/2] tracing: Add free_trace_iter_content() helper function
Date: Fri, 14 Jul 2023 10:22:17 -0400 [thread overview]
Message-ID: <20230714102217.35e2153c@gandalf.local.home> (raw)
In-Reply-To: <20230714174757.4ab9157a2edb32d35224edfb@kernel.org>
On Fri, 14 Jul 2023 17:47:57 +0900
Masami Hiramatsu (Google) <mhiramat@kernel.org> wrote:
> > @@ -6709,7 +6723,12 @@ static int tracing_open_pipe(struct inode *inode, struct file *filp)
> > }
> >
> > trace_seq_init(&iter->seq);
> > - iter->trace = tr->current_trace;
> > +
> > + iter->trace = kzalloc(sizeof(*iter->trace), GFP_KERNEL);
> > + if (!iter->trace)
> > + goto fail;
> > +
> > + *iter->trace = *tr->current_trace;
>
> Hmm, you allocate iter->trace here (again)
Bah, that looks like it got out of sync with the previous patch (which
removed that). That's not suppose to be there.
I'll fix this an send out a v2. Thanks for catching that!
-- Steve
next prev parent reply other threads:[~2023-07-14 14:22 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-13 15:45 [PATCH 0/2] tracing: Clean up how iter is freed Steven Rostedt
2023-07-13 15:46 ` [PATCH 1/2] tracing: Remove unnecessary copying of tr->current_trace Steven Rostedt
2023-07-14 8:38 ` Masami Hiramatsu
2023-07-13 15:47 ` [PATCH 2/2] tracing: Add free_trace_iter_content() helper function Steven Rostedt
2023-07-14 8:47 ` Masami Hiramatsu
2023-07-14 14:22 ` Steven Rostedt [this message]
2023-07-15 5:15 ` Zheng Yejian
2023-07-15 13:42 ` Steven Rostedt
2023-07-15 13:54 ` Steven Rostedt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230714102217.35e2153c@gandalf.local.home \
--to=rostedt@goodmis.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-trace-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=mhiramat@kernel.org \
--cc=zhengyejian1@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).