Re: [PATCH 3/5] rteval: kernel.py: Add support for kthreads running with deadline policy

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

 



John Kacur <jkacur@xxxxxxxxxx> writes:

> On Wed, 15 Sep 2021, Punit Agrawal wrote:
>
>> Hi John,
>> 
>> John Kacur <jkacur@xxxxxxxxxx> writes:
>> 
>> > On Wed, 1 Sep 2021, Punit Agrawal wrote:
>> >
>> >> From: Punit Agrawal <punit1.agrawal@xxxxxxxxxxxxx>
>> >> 
>> >> When running rteval on a system with kthreads running with "deadline"
>> >> policy, an exception is encountered when parsing the output of "ps".
>> >> 
>> >>     [DEBUG] cmd: /usr/bin/ps -eocommand,pid,policy,rtprio,comm
>> >>     Traceback (most recent call last):
>> >>     ...
>> >>       File "...rteval/rteval/sysinfo/kernel.py", line 60, in kernel_get_kthreads
>> >> 	ret_kthreads[v[0]] = {'policy' : policies[bytes.decode(v[1])],
>> >>       KeyError: 'DLN'
>> >> 
>> >> The kernel uses deadline policy for "schedutil" cpufreq governor
>> >> threads. Fix the crash in rteval by adding support for "deadline" to
>> >> the list of policies.
>> >> 
>> >> Signed-off-by: Punit Agrawal <punit1.agrawal@xxxxxxxxxxxxx>
>> >> ---
>> >>  rteval/sysinfo/kernel.py | 2 +-
>> >>  1 file changed, 1 insertion(+), 1 deletion(-)
>> >> 
>> >> diff --git a/rteval/sysinfo/kernel.py b/rteval/sysinfo/kernel.py
>> >> index 97ad9402b13e..f2e9d72ac2ef 100644
>> >> --- a/rteval/sysinfo/kernel.py
>> >> +++ b/rteval/sysinfo/kernel.py
>> >> @@ -44,7 +44,7 @@ class KernelInfo:
>> >>  
>> >>  
>> >>      def kernel_get_kthreads(self):
>> >> -        policies = {'FF':'fifo', 'RR':'rrobin', 'TS':'other', '?':'unknown'}
>> >> +        policies = {'DLN': 'deadline', 'FF':'fifo', 'RR':'rrobin', 'TS':'other', '?':'unknown'}
>> >>          ret_kthreads = {}
>> >>          self.__log(Log.DEBUG, "getting kthread status")
>> >>          cmd = '%s -eocommand,pid,policy,rtprio,comm' % getcmdpath('ps')
>> >> -- 
>> >> 2.32.0
>> >> 
>> >> 
>> >
>> > Signed-off-by: John Kacur <jkacur@xxxxxxxxxx>
>> 
>> It looks like this patch and the other one converting hackbench memory
>> check to a warning was missed when applying the rest of the series -
>> John, could you please pick these as well.
>> 
>> Thanks,
>> Punit
>> 
>
> I added the patch to support deadline policy, the other one had already 
> been added, I just hadn't pushed upstream yet, but I just did so, so go 
> ahead and pull.

Thanks, I see both the patches now.



[Index of Archives]     [RT Stable]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux