[lkml]   [2004]   [Dec]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm3-V0.7.32-15
Here is my script (at the end).

So I read the preempt_max_latency (to see if its changed) before
I copy the latency_trace output. I am not so sure that cat is
really doing an "atomic" read when some of the latency traces
are over 300 Kbytes in length.

Also note that some of the files were empty :-(. I don't think
I've seen that symptom before.

Note that the preempt_max_latency value DID match the last line of
the trace output in the example I described. It is just the header
that had some stale data in it.


--- ---


let MAX=`cat /proc/sys/kernel/preempt_max_latency`
let I=0 J=1
let MP=${1:-1000}
echo "Current Maximum is $MAX, limit will be $MP."
while (( I < 100 )) ; do
sleep 1s
let NOW=`cat /proc/sys/kernel/preempt_max_latency`
if (( MAX != NOW )) ; then
echo "New trace $I w/ $NOW usec latency."
cat /proc/latency_trace > lt.`printf "%02d" $I`
# sync ; sync
let I++
elif (( J++ >= 10 )) ; then
if (( MAX != MP )) ; then
echo "Resetting max latency from $MAX to $MP."
echo $MP > /proc/sys/kernel/preempt_max_latency
let MAX=$MP
echo "No new latency samples at `date`."
let J=1
# else do nothing...

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 14:08    [W:0.030 / U:0.312 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site