Re: [PATCH] kselftests: ftrace: limit the executing time by reading from cached trace

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 18 Oct 2021 21:26:16 +0800
Li Zhijian <lizhijian@xxxxxxxxxxxxxx> wrote:

> LKP/0day observed that kselftests/ftrace cannot finish within 1 hour on
> a 96 cpus platform where it hangs in the line like:
> 'cat trace | grep -v ^# | awk '{ print $5 }' | sort -u | wc -l'
> subsystem-enable.tc
> 
> It seems that trace will keep growing during it's read by 'cat' command.
> Consequently, trace becomes too large to finish reading.
> 
> replace 'cat trace' by:
> $ sed -i 's/cat trace |/read_cached_trace |/g' $(find test.d -name "*.tc")
> 

Instead, what happens if you add this command to each test?

if [ -t options/pause-on-trace ]; then
   echo 1 > options/pause-on-trace
fi

We also need to add to the "initialize_ftrace" function in test.d/functions.

if [ -t options/pause-on-trace ]; then
   echo 0 > options/pause-on-trace
fi

-- Steve

> CC: Philip Li <philip.li@xxxxxxxxx>
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Signed-off-by: Li Zhijian <lizhijian@xxxxxxxxxxxxxx>
> ---



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux