* Realtime System only works after running cyclictest with -b option
@ 2013-08-01 17:34 Paul-Ehrlich
2013-08-01 21:03 ` Clark Williams
0 siblings, 1 reply; 2+ messages in thread
From: Paul-Ehrlich @ 2013-08-01 17:34 UTC (permalink / raw)
To: linux-rt-users
Hello linux-rt-users,
I have a question concerning RT-Patch, which shows strange behavior
discoverd using cyclictest. I have an embedded system with patched RT.
The max latency of the cyclictest isn’t as low as expected and my only
application hangs to, so I included tracing abilities to the kernel to
use the “-b” switch of cyclictest. But the kernel behaves different if
switched on (detailed below)? Maybe you can give me a hint what the
cyclictest does when using the –b switch. It somehow persists after the
option is used once and my own application runs fine afterwards too. So
in order to run my application right now I have to run cyclictest with
the -b option after each reboot.
Many Thanks in Advance
Paul Ehrlich
First test run after boot - showing huge latencies:
linaro@linaro-ubuntu-desktop:~$ sudo cyclictest -t1 -p 80 -n -i 250 -l
10000 -a 1
# /dev/cpu_dma_latency set to 0us
policy: fifo: loadavg: 0.74 0.34 0.13 1/144 1966
T: 0 ( 1966) P:80 I:250 C: 10000 Min: 18 Act: 27 Avg: 36 Max: 1590
Secound test run after boot - just to make sure:
linaro@linaro-ubuntu-desktop:~$ sudo cyclictest -t1 -p 80 -n -i 250 -l
10000 -a 1
# /dev/cpu_dma_latency set to 0us
policy: fifo: loadavg: 0.93 0.30 0.10 1/142 1948
T: 0 ( 1948) P:80 I:250 C: 10000 Min: 18 Act: 46 Avg: 38 Max: 3639
Third test run after boot now using -b option - result looks ok for the
system:
linaro@linaro-ubuntu-desktop:~$ sudo cyclictest -t1 -p 80 -n -i 250 -l
10000 -a 1 -b 1000
# /dev/cpu_dma_latency set to 0us
INFO: debugfs mountpoint: /sys/kernel/debug/tracing/
policy: fifo: loadavg: 0.51 0.32 0.13 1/144 1979
T: 0 ( 1979) P:80 I:250 C: 10000 Min: 85 Act: 101 Avg: 114 Max: 179
Fourth run after boot - now without -b even faster?:
# Thread Ids: 01979
linaro@linaro-ubuntu-desktop:~$ sudo cyclictest -t1 -p 80 -n -i 250 -l
10000 -a 1
# /dev/cpu_dma_latency set to 0us
policy: fifo: loadavg: 0.66 0.38 0.16 1/157 2283
T: 0 ( 2279) P:80 I:250 C: 10000 Min: 6 Act: 27 Avg: 27 Max: 51
--
To unsubscribe from this list: send the line "unsubscribe linux-rt-users" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Realtime System only works after running cyclictest with -b option
2013-08-01 17:34 Realtime System only works after running cyclictest with -b option Paul-Ehrlich
@ 2013-08-01 21:03 ` Clark Williams
0 siblings, 0 replies; 2+ messages in thread
From: Clark Williams @ 2013-08-01 21:03 UTC (permalink / raw)
To: Paul-Ehrlich@gmx.de; +Cc: linux-rt-users
[-- Attachment #1: Type: text/plain, Size: 3160 bytes --]
On Thu, 01 Aug 2013 19:34:31 +0200
"Paul-Ehrlich@gmx.de" <Paul-Ehrlich@gmx.de> wrote:
> Hello linux-rt-users,
> I have a question concerning RT-Patch, which shows strange behavior
> discoverd using cyclictest. I have an embedded system with patched RT.
> The max latency of the cyclictest isn’t as low as expected and my only
> application hangs to, so I included tracing abilities to the kernel to
> use the “-b” switch of cyclictest. But the kernel behaves different if
> switched on (detailed below)? Maybe you can give me a hint what the
> cyclictest does when using the –b switch. It somehow persists after the
> option is used once and my own application runs fine afterwards too. So
> in order to run my application right now I have to run cyclictest with
> the -b option after each reboot.
> Many Thanks in Advance
> Paul Ehrlich
The -b (breaktrace) switch is used to stop cyclictest after a
measured latency on any processor exceeds the value specified with -b.
To do this it mounts the debugfs and sets up latency tracing. When any
latency value exceeds the threshold, cyclictest writes a trace-mark
into the tracing buffer, stops ftrace and then stops the run.
The only thing that's persistent when using the -b option is that
debugfs remains mounted (so you can access the latency tracing data).
Not sure why debugfs would help here. Might be interesting to see if
it's just the fact that debugfs is mounted or if you have to access
some of the ftrace knobs (/sys/kernel/debug/tracing/*).
What kind of processor are you using?
Clark
>
>
> First test run after boot - showing huge latencies:
> linaro@linaro-ubuntu-desktop:~$ sudo cyclictest -t1 -p 80 -n -i 250 -l
> 10000 -a 1
> # /dev/cpu_dma_latency set to 0us
> policy: fifo: loadavg: 0.74 0.34 0.13 1/144 1966
> T: 0 ( 1966) P:80 I:250 C: 10000 Min: 18 Act: 27 Avg: 36 Max: 1590
>
> Secound test run after boot - just to make sure:
> linaro@linaro-ubuntu-desktop:~$ sudo cyclictest -t1 -p 80 -n -i 250 -l
> 10000 -a 1
> # /dev/cpu_dma_latency set to 0us
> policy: fifo: loadavg: 0.93 0.30 0.10 1/142 1948
> T: 0 ( 1948) P:80 I:250 C: 10000 Min: 18 Act: 46 Avg: 38 Max: 3639
>
> Third test run after boot now using -b option - result looks ok for the
> system:
> linaro@linaro-ubuntu-desktop:~$ sudo cyclictest -t1 -p 80 -n -i 250 -l
> 10000 -a 1 -b 1000
> # /dev/cpu_dma_latency set to 0us
> INFO: debugfs mountpoint: /sys/kernel/debug/tracing/
> policy: fifo: loadavg: 0.51 0.32 0.13 1/144 1979
> T: 0 ( 1979) P:80 I:250 C: 10000 Min: 85 Act: 101 Avg: 114 Max: 179
>
> Fourth run after boot - now without -b even faster?:
> # Thread Ids: 01979
> linaro@linaro-ubuntu-desktop:~$ sudo cyclictest -t1 -p 80 -n -i 250 -l
> 10000 -a 1
> # /dev/cpu_dma_latency set to 0us
> policy: fifo: loadavg: 0.66 0.38 0.16 1/157 2283
> T: 0 ( 2279) P:80 I:250 C: 10000 Min: 6 Act: 27 Avg: 27 Max: 51
> --
> To unsubscribe from this list: send the line "unsubscribe linux-rt-users" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-08-01 21:03 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-01 17:34 Realtime System only works after running cyclictest with -b option Paul-Ehrlich
2013-08-01 21:03 ` Clark Williams
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox