* [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh
@ 2011-02-10 7:23 Han Pingtian
2011-02-21 7:37 ` Han Pingtian
2011-02-21 7:44 ` Li Zefan
0 siblings, 2 replies; 6+ messages in thread
From: Han Pingtian @ 2011-02-10 7:23 UTC (permalink / raw)
To: ltp-list
It seems we need echo -1 to set_ftrace_pid to disable in. Or we'll get
these error message when running ftrace_stress:
...
ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh: line 39: echo: write error: Invalid argument
...
---
.../ftrace_stress/ftrace_set_ftrace_pid.sh | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh b/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
index 541215c..bd08f04 100755
--- a/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
+++ b/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
@@ -36,7 +36,7 @@ for ((; ; ))
eval echo $str >> "$TRACING_PATH"/set_ftrace_pid
}
- echo > "$TRACING_PATH"/set_ftrace_pid
+ echo -1 > "$TRACING_PATH"/set_ftrace_pid
}
sleep 1
--
1.7.1
------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh
2011-02-10 7:23 [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh Han Pingtian
@ 2011-02-21 7:37 ` Han Pingtian
2011-02-21 7:44 ` Li Zefan
1 sibling, 0 replies; 6+ messages in thread
From: Han Pingtian @ 2011-02-21 7:37 UTC (permalink / raw)
To: ltp-list
Hello,
Any comments to this patch?
Thanks.
On Thu, Feb 10, 2011 at 03:23:15PM +0800, Han Pingtian wrote:
> It seems we need echo -1 to set_ftrace_pid to disable in. Or we'll get
> these error message when running ftrace_stress:
>
> ...
> ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh: line 39: echo: write error: Invalid argument
> ...
> ---
> .../ftrace_stress/ftrace_set_ftrace_pid.sh | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh b/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> index 541215c..bd08f04 100755
> --- a/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> +++ b/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> @@ -36,7 +36,7 @@ for ((; ; ))
> eval echo $str >> "$TRACING_PATH"/set_ftrace_pid
> }
>
> - echo > "$TRACING_PATH"/set_ftrace_pid
> + echo -1 > "$TRACING_PATH"/set_ftrace_pid
> }
>
> sleep 1
> --
> 1.7.1
>
> ------------------------------------------------------------------------------
> The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
> Pinpoint memory and threading errors before they happen.
> Find and fix more than 250 security defects in the development cycle.
> Locate bottlenecks in serial and parallel code that limit performance.
> http://p.sf.net/sfu/intel-dev2devfeb
> _______________________________________________
> Ltp-list mailing list
> Ltp-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ltp-list
--
Han Pingtian
Quality Engineer
hpt @ #kernel-qe
Red Hat, Inc
Freedom ... courage ... Commitment ... ACCOUNTABILITY
------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh
2011-02-10 7:23 [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh Han Pingtian
2011-02-21 7:37 ` Han Pingtian
@ 2011-02-21 7:44 ` Li Zefan
2011-02-22 1:58 ` Han Pingtian
1 sibling, 1 reply; 6+ messages in thread
From: Li Zefan @ 2011-02-21 7:44 UTC (permalink / raw)
To: Han Pingtian; +Cc: ltp-list
Han Pingtian wrote:
> It seems we need echo -1 to set_ftrace_pid to disable in. Or we'll get
> these error message when running ftrace_stress:
>
kernel version?
This is the result from latest kernel:
# echo > set_ftrace_pid
# echo -1 > set_ftrace_pid
bash: echo: write error: Invalid argument
> ...
> ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh: line 39: echo: write error: Invalid argument
> ...
> ---
> .../ftrace_stress/ftrace_set_ftrace_pid.sh | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh b/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> index 541215c..bd08f04 100755
> --- a/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> +++ b/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> @@ -36,7 +36,7 @@ for ((; ; ))
> eval echo $str >> "$TRACING_PATH"/set_ftrace_pid
> }
>
> - echo > "$TRACING_PATH"/set_ftrace_pid
> + echo -1 > "$TRACING_PATH"/set_ftrace_pid
> }
>
> sleep 1
------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh
2011-02-21 7:44 ` Li Zefan
@ 2011-02-22 1:58 ` Han Pingtian
2011-02-22 2:08 ` Li Zefan
0 siblings, 1 reply; 6+ messages in thread
From: Han Pingtian @ 2011-02-22 1:58 UTC (permalink / raw)
To: Li Zefan; +Cc: ltp-list
On Mon, Feb 21, 2011 at 03:44:11PM +0800, Li Zefan wrote:
> Han Pingtian wrote:
> > It seems we need echo -1 to set_ftrace_pid to disable in. Or we'll get
> > these error message when running ftrace_stress:
> >
>
> kernel version?
2.6.32-114.0.1.el6.x86_64 , RHEL6.1.
>
> This is the result from latest kernel:
>
> # echo > set_ftrace_pid
> # echo -1 > set_ftrace_pid
> bash: echo: write error: Invalid argument
>
Looks like latest kernel changed the behaviour. But the
Documentation/trace/ftrace.txt hasn't been updated:
yum-updatesd-3111 [003] 1637.254683: lock_hrtimer_base <-hrtimer_try_to_cancel
yum-updatesd-3111 [003] 1637.254685: fget_light <-do_sys_poll
yum-updatesd-3111 [003] 1637.254686: pipe_poll <-do_sys_poll
# echo -1 > set_ftrace_pid
# cat trace |head
# tracer: function
#
# TASK-PID CPU# TIMESTAMP FUNCTION
Thanks.
> > ...
> > ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh: line 39: echo: write error: Invalid argument
> > ...
> > ---
> > .../ftrace_stress/ftrace_set_ftrace_pid.sh | 2 +-
> > 1 files changed, 1 insertions(+), 1 deletions(-)
> >
> > diff --git a/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh b/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> > index 541215c..bd08f04 100755
> > --- a/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> > +++ b/testcases/kernel/tracing/ftrace_stress_test/ftrace_stress/ftrace_set_ftrace_pid.sh
> > @@ -36,7 +36,7 @@ for ((; ; ))
> > eval echo $str >> "$TRACING_PATH"/set_ftrace_pid
> > }
> >
> > - echo > "$TRACING_PATH"/set_ftrace_pid
> > + echo -1 > "$TRACING_PATH"/set_ftrace_pid
> > }
> >
> > sleep 1
--
Han Pingtian
Quality Engineer
hpt @ #kernel-qe
Red Hat, Inc
Freedom ... courage ... Commitment ... ACCOUNTABILITY
------------------------------------------------------------------------------
Index, Search & Analyze Logs and other IT data in Real-Time with Splunk
Collect, index and harness all the fast moving IT data generated by your
applications, servers and devices whether physical, virtual or in the cloud.
Deliver compliance at lower cost and gain new business insights.
Free Software Download: http://p.sf.net/sfu/splunk-dev2dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh
2011-02-22 1:58 ` Han Pingtian
@ 2011-02-22 2:08 ` Li Zefan
2011-02-22 3:55 ` Han Pingtian
0 siblings, 1 reply; 6+ messages in thread
From: Li Zefan @ 2011-02-22 2:08 UTC (permalink / raw)
To: phan@redhat.com >> Han Pingtian; +Cc: ltp-list
于 2011年02月22日 09:58, Han Pingtian 写道:
> On Mon, Feb 21, 2011 at 03:44:11PM +0800, Li Zefan wrote:
>> Han Pingtian wrote:
>>> It seems we need echo -1 to set_ftrace_pid to disable in. Or we'll get
>>> these error message when running ftrace_stress:
>>>
>>
>> kernel version?
> 2.6.32-114.0.1.el6.x86_64 , RHEL6.1.
>>
>> This is the result from latest kernel:
>>
>> # echo > set_ftrace_pid
>> # echo -1 > set_ftrace_pid
>> bash: echo: write error: Invalid argument
>>
> Looks like latest kernel changed the behaviour. But the
The change came from commit 756d17ee7ee4fbc8238bdf97100af63e6ac441ef
So we have to check the kernel version, or try both "echo > ..." and
"echo -1 > ...".
> Documentation/trace/ftrace.txt hasn't been updated:
>
> yum-updatesd-3111 [003] 1637.254683: lock_hrtimer_base <-hrtimer_try_to_cancel
> yum-updatesd-3111 [003] 1637.254685: fget_light <-do_sys_poll
> yum-updatesd-3111 [003] 1637.254686: pipe_poll <-do_sys_poll
> # echo -1 > set_ftrace_pid
> # cat trace |head
> # tracer: function
> #
> # TASK-PID CPU# TIMESTAMP FUNCTION
------------------------------------------------------------------------------
Index, Search & Analyze Logs and other IT data in Real-Time with Splunk
Collect, index and harness all the fast moving IT data generated by your
applications, servers and devices whether physical, virtual or in the cloud.
Deliver compliance at lower cost and gain new business insights.
Free Software Download: http://p.sf.net/sfu/splunk-dev2dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh
2011-02-22 2:08 ` Li Zefan
@ 2011-02-22 3:55 ` Han Pingtian
0 siblings, 0 replies; 6+ messages in thread
From: Han Pingtian @ 2011-02-22 3:55 UTC (permalink / raw)
To: Li Zefan; +Cc: ltp-list
On Tue, Feb 22, 2011 at 10:08:18AM +0800, Li Zefan wrote:
> 于 2011年02月22日 09:58, Han Pingtian 写道:
> > On Mon, Feb 21, 2011 at 03:44:11PM +0800, Li Zefan wrote:
> >> Han Pingtian wrote:
> >>> It seems we need echo -1 to set_ftrace_pid to disable in. Or we'll get
> >>> these error message when running ftrace_stress:
> >>>
> >>
> >> kernel version?
> > 2.6.32-114.0.1.el6.x86_64 , RHEL6.1.
> >>
> >> This is the result from latest kernel:
> >>
> >> # echo > set_ftrace_pid
> >> # echo -1 > set_ftrace_pid
> >> bash: echo: write error: Invalid argument
> >>
> > Looks like latest kernel changed the behaviour. But the
>
> The change came from commit 756d17ee7ee4fbc8238bdf97100af63e6ac441ef
>
> So we have to check the kernel version, or try both "echo > ..." and
> "echo -1 > ...".
I believe the second method is better.
>
> > Documentation/trace/ftrace.txt hasn't been updated:
> >
> > yum-updatesd-3111 [003] 1637.254683: lock_hrtimer_base <-hrtimer_try_to_cancel
> > yum-updatesd-3111 [003] 1637.254685: fget_light <-do_sys_poll
> > yum-updatesd-3111 [003] 1637.254686: pipe_poll <-do_sys_poll
> > # echo -1 > set_ftrace_pid
> > # cat trace |head
> > # tracer: function
> > #
> > # TASK-PID CPU# TIMESTAMP FUNCTION
--
Han Pingtian
Quality Engineer
hpt @ #kernel-qe
Red Hat, Inc
Freedom ... courage ... Commitment ... ACCOUNTABILITY
------------------------------------------------------------------------------
Index, Search & Analyze Logs and other IT data in Real-Time with Splunk
Collect, index and harness all the fast moving IT data generated by your
applications, servers and devices whether physical, virtual or in the cloud.
Deliver compliance at lower cost and gain new business insights.
Free Software Download: http://p.sf.net/sfu/splunk-dev2dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2011-02-22 3:51 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-10 7:23 [LTP] [PATCH] Fix disable set_ftrace_pid in ftrace_set_ftrace_pid.sh Han Pingtian
2011-02-21 7:37 ` Han Pingtian
2011-02-21 7:44 ` Li Zefan
2011-02-22 1:58 ` Han Pingtian
2011-02-22 2:08 ` Li Zefan
2011-02-22 3:55 ` Han Pingtian
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox