* [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order
@ 2024-04-17 10:29 Tio Zhang
2024-04-23 10:24 ` Madadi Vineeth Reddy
0 siblings, 1 reply; 8+ messages in thread
From: Tio Zhang @ 2024-04-17 10:29 UTC (permalink / raw)
To: rostedt, mhiramat
Cc: akpm, linux-kernel, mathieu.desnoyers, tiozhang, zyhtheonly,
zyhtheonly
Switch the order of prev_comm and next_comm in sched_switch's code to
align with its printing order.
Signed-off-by: Tio Zhang <tiozhang@didiglobal.com>
---
include/trace/events/sched.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/trace/events/sched.h b/include/trace/events/sched.h
index dbb01b4b7451..a4bd4330db4c 100644
--- a/include/trace/events/sched.h
+++ b/include/trace/events/sched.h
@@ -239,11 +239,11 @@ TRACE_EVENT(sched_switch,
),
TP_fast_assign(
- memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
+ memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
__entry->prev_pid = prev->pid;
__entry->prev_prio = prev->prio;
__entry->prev_state = __trace_sched_switch_state(preempt, prev_state, prev);
- memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
+ memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
__entry->next_pid = next->pid;
__entry->next_prio = next->prio;
/* XXX SCHED_DEADLINE */
--
2.17.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order
2024-04-17 10:29 Tio Zhang
@ 2024-04-23 10:24 ` Madadi Vineeth Reddy
2024-07-02 7:14 ` 张元瀚 Tio Zhang
0 siblings, 1 reply; 8+ messages in thread
From: Madadi Vineeth Reddy @ 2024-04-23 10:24 UTC (permalink / raw)
To: tiozhang
Cc: Steven Rostedt, mhiramat, akpm, linux-kernel, Mathieu Desnoyers,
zyhtheonly, zyhtheonly, Madadi Vineeth Reddy
Hi Tio zhang,
On 17/04/24 15:59, Tio Zhang wrote:
> Switch the order of prev_comm and next_comm in sched_switch's code to
> align with its printing order.
>
> Signed-off-by: Tio Zhang <tiozhang@didiglobal.com>
> ---
> include/trace/events/sched.h | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/include/trace/events/sched.h b/include/trace/events/sched.h
> index dbb01b4b7451..a4bd4330db4c 100644
> --- a/include/trace/events/sched.h
> +++ b/include/trace/events/sched.h
> @@ -239,11 +239,11 @@ TRACE_EVENT(sched_switch,
> ),
>
> TP_fast_assign(
> - memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
> + memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
> __entry->prev_pid = prev->pid;
> __entry->prev_prio = prev->prio;
> __entry->prev_state = __trace_sched_switch_state(preempt, prev_state, prev);
> - memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
> + memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
> __entry->next_pid = next->pid;
> __entry->next_prio = next->prio;
> /* XXX SCHED_DEADLINE */
Yes, makes sense to have all previous and then the next for increased readability.
Reviewed-by: Madadi Vineeth Reddy <vineethr@linux.ibm.com>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order
2024-04-23 10:24 ` Madadi Vineeth Reddy
@ 2024-07-02 7:14 ` 张元瀚 Tio Zhang
2024-07-02 16:29 ` Steven Rostedt
0 siblings, 1 reply; 8+ messages in thread
From: 张元瀚 Tio Zhang @ 2024-07-02 7:14 UTC (permalink / raw)
To: Madadi Vineeth Reddy
Cc: Steven Rostedt, mhiramat@kernel.org, akpm@linux-foundation.org,
linux-kernel@vger.kernel.org, Mathieu Desnoyers,
zyhtheonly@gmail.com, zyhtheonly@yeah.net
Hi Steven,
Ping :)
On 4/23/24 下午6:24, "Madadi Vineeth Reddy" <vineethr@linux.ibm.com <mailto:vineethr@linux.ibm.com>> wrote:
Hi Tio zhang,
On 17/04/24 15:59, Tio Zhang wrote:
> Switch the order of prev_comm and next_comm in sched_switch's code to
> align with its printing order.
>
> Signed-off-by: Tio Zhang <tiozhang@didiglobal.com <mailto:tiozhang@didiglobal.com>>
> ---
> include/trace/events/sched.h | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/include/trace/events/sched.h b/include/trace/events/sched.h
> index dbb01b4b7451..a4bd4330db4c 100644
> --- a/include/trace/events/sched.h
> +++ b/include/trace/events/sched.h
> @@ -239,11 +239,11 @@ TRACE_EVENT(sched_switch,
> ),
>
> TP_fast_assign(
> - memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
> + memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
> __entry->prev_pid = prev->pid;
> __entry->prev_prio = prev->prio;
> __entry->prev_state = __trace_sched_switch_state(preempt, prev_state, prev);
> - memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
> + memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
> __entry->next_pid = next->pid;
> __entry->next_prio = next->prio;
> /* XXX SCHED_DEADLINE */
Yes, makes sense to have all previous and then the next for increased readability.
Reviewed-by: Madadi Vineeth Reddy <vineethr@linux.ibm.com <mailto:vineethr@linux.ibm.com>>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order
2024-07-02 7:14 ` 张元瀚 Tio Zhang
@ 2024-07-02 16:29 ` Steven Rostedt
2024-07-12 7:18 ` 张元瀚 Tio Zhang
0 siblings, 1 reply; 8+ messages in thread
From: Steven Rostedt @ 2024-07-02 16:29 UTC (permalink / raw)
To: 张元瀚 Tio Zhang
Cc: Madadi Vineeth Reddy, mhiramat@kernel.org,
akpm@linux-foundation.org, linux-kernel@vger.kernel.org,
Mathieu Desnoyers, zyhtheonly@gmail.com, zyhtheonly@yeah.net
On Tue, 2 Jul 2024 07:14:33 +0000
张元瀚 Tio Zhang <tiozhang@didiglobal.com> wrote:
> Hi Steven,
>
> Ping :)
If you want me to take this, please resend it and add
linux-trace-kernel@vger.kernel.org to the Cc so that my patchwork can
pick it up.
Also add anyone's tags to it as well.
-- Steve
^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order
@ 2024-07-03 3:33 Tio Zhang
2024-07-15 19:04 ` Steven Rostedt
0 siblings, 1 reply; 8+ messages in thread
From: Tio Zhang @ 2024-07-03 3:33 UTC (permalink / raw)
To: rostedt, mhiramat
Cc: linux-kernel, linux-trace-kernel, vineethr, akpm,
mathieu.desnoyers, tiozhang, mingo, mgorman, peterz, qyousef,
vincent.guittot, elver, zyhtheonly, zyhtheonly
Switch the order of prev_comm and next_comm in sched_switch's code to
align with its printing order.
Signed-off-by: Tio Zhang <tiozhang@didiglobal.com>
Reviewed-by: Madadi Vineeth Reddy <vineethr@linux.ibm.com>
---
include/trace/events/sched.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/trace/events/sched.h b/include/trace/events/sched.h
index dbb01b4b7451..a4bd4330db4c 100644
--- a/include/trace/events/sched.h
+++ b/include/trace/events/sched.h
@@ -239,11 +239,11 @@ TRACE_EVENT(sched_switch,
),
TP_fast_assign(
- memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
+ memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
__entry->prev_pid = prev->pid;
__entry->prev_prio = prev->prio;
__entry->prev_state = __trace_sched_switch_state(preempt, prev_state, prev);
- memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
+ memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
__entry->next_pid = next->pid;
__entry->next_prio = next->prio;
/* XXX SCHED_DEADLINE */
--
2.17.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order
2024-07-02 16:29 ` Steven Rostedt
@ 2024-07-12 7:18 ` 张元瀚 Tio Zhang
0 siblings, 0 replies; 8+ messages in thread
From: 张元瀚 Tio Zhang @ 2024-07-12 7:18 UTC (permalink / raw)
To: Steven Rostedt
Cc: Madadi Vineeth Reddy, mhiramat@kernel.org,
akpm@linux-foundation.org, linux-kernel@vger.kernel.org,
Mathieu Desnoyers, zyhtheonly@gmail.com, zyhtheonly@yeah.net
Hi Steven,
Thank you, I resend this patch with linux-trace-kernel@vger.kernel.org on the cc list, please see https://lore.kernel.org/lkml/20240703033353.GA2833@didi-ThinkCentre-M930t-N000/#t
On 7/3/24 上午12:29, "Steven Rostedt" <rostedt@goodmis.org <mailto:rostedt@goodmis.org>> wrote:
On Tue, 2 Jul 2024 07:14:33 +0000
张元瀚 Tio Zhang <tiozhang@didiglobal.com <mailto:tiozhang@didiglobal.com>> wrote:
> Hi Steven,
>
> Ping :)
If you want me to take this, please resend it and add
linux-trace-kernel@vger.kernel.org <mailto:linux-trace-kernel@vger.kernel.org> to the Cc so that my patchwork can
pick it up.
Also add anyone's tags to it as well.
-- Steve
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order
2024-07-03 3:33 [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order Tio Zhang
@ 2024-07-15 19:04 ` Steven Rostedt
2024-07-16 9:18 ` Peter Zijlstra
0 siblings, 1 reply; 8+ messages in thread
From: Steven Rostedt @ 2024-07-15 19:04 UTC (permalink / raw)
To: Tio Zhang
Cc: mhiramat, linux-kernel, linux-trace-kernel, vineethr, akpm,
mathieu.desnoyers, mingo, mgorman, peterz, qyousef,
vincent.guittot, elver, zyhtheonly, zyhtheonly, Peter Zijlstra,
Ingo Molnar, Juri Lelli, Vincent Guittot, Dietmar Eggemann,
Ben Segall, Mel Gorman, Valentin Schneider
[ Adding sched maintainers, as this is a scheduling trace event ]
On Wed, 3 Jul 2024 11:33:53 +0800
Tio Zhang <tiozhang@didiglobal.com> wrote:
> Switch the order of prev_comm and next_comm in sched_switch's code to
> align with its printing order.
I'm going to pick this up in my tree, as it is pretty much a nop. It's
just changing the ordering of the assignments of the comm names so that
the copy of prev_comm is with the updates to the prev_fields, and the
next_comm is with the updates to the next fields.
-- Steve
>
> Signed-off-by: Tio Zhang <tiozhang@didiglobal.com>
> Reviewed-by: Madadi Vineeth Reddy <vineethr@linux.ibm.com>
> ---
> include/trace/events/sched.h | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/include/trace/events/sched.h b/include/trace/events/sched.h
> index dbb01b4b7451..a4bd4330db4c 100644
> --- a/include/trace/events/sched.h
> +++ b/include/trace/events/sched.h
> @@ -239,11 +239,11 @@ TRACE_EVENT(sched_switch,
> ),
>
> TP_fast_assign(
> - memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
> + memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
> __entry->prev_pid = prev->pid;
> __entry->prev_prio = prev->prio;
> __entry->prev_state = __trace_sched_switch_state(preempt, prev_state, prev);
> - memcpy(__entry->prev_comm, prev->comm, TASK_COMM_LEN);
> + memcpy(__entry->next_comm, next->comm, TASK_COMM_LEN);
> __entry->next_pid = next->pid;
> __entry->next_prio = next->prio;
> /* XXX SCHED_DEADLINE */
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order
2024-07-15 19:04 ` Steven Rostedt
@ 2024-07-16 9:18 ` Peter Zijlstra
0 siblings, 0 replies; 8+ messages in thread
From: Peter Zijlstra @ 2024-07-16 9:18 UTC (permalink / raw)
To: Steven Rostedt
Cc: Tio Zhang, mhiramat, linux-kernel, linux-trace-kernel, vineethr,
akpm, mathieu.desnoyers, mingo, mgorman, qyousef, vincent.guittot,
elver, zyhtheonly, zyhtheonly, Juri Lelli, Dietmar Eggemann,
Ben Segall, Mel Gorman, Valentin Schneider
On Mon, Jul 15, 2024 at 03:04:12PM -0400, Steven Rostedt wrote:
>
> [ Adding sched maintainers, as this is a scheduling trace event ]
>
> On Wed, 3 Jul 2024 11:33:53 +0800
> Tio Zhang <tiozhang@didiglobal.com> wrote:
>
> > Switch the order of prev_comm and next_comm in sched_switch's code to
> > align with its printing order.
>
> I'm going to pick this up in my tree, as it is pretty much a nop. It's
> just changing the ordering of the assignments of the comm names so that
> the copy of prev_comm is with the updates to the prev_fields, and the
> next_comm is with the updates to the next fields.
Right, have at. very close to a whitespace patch.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2024-07-16 9:19 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-03 3:33 [PATCH 1/1] tracing/sched: sched_switch: place prev_comm and next_comm in right order Tio Zhang
2024-07-15 19:04 ` Steven Rostedt
2024-07-16 9:18 ` Peter Zijlstra
-- strict thread matches above, loose matches on Subject: below --
2024-04-17 10:29 Tio Zhang
2024-04-23 10:24 ` Madadi Vineeth Reddy
2024-07-02 7:14 ` 张元瀚 Tio Zhang
2024-07-02 16:29 ` Steven Rostedt
2024-07-12 7:18 ` 张元瀚 Tio Zhang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox