From: Punit Agrawal <punit1.agrawal@xxxxxxxxxxxxx> Since the osinfo.py module was developed, RT kernels have moved on from identifying as "RT" to "PREEMPT_RT". This change in the kernel identifier causes osinfo.py to incorrectly detect RT kernels as non-RT. Update the check for detecting RT kernel to be able to handle both the variants. Signed-off-by: Punit Agrawal <punit1.agrawal@xxxxxxxxxxxxx> --- rteval/sysinfo/osinfo.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rteval/sysinfo/osinfo.py b/rteval/sysinfo/osinfo.py index 98e5b4422cad..7b7bfe9ce4ec 100644 --- a/rteval/sysinfo/osinfo.py +++ b/rteval/sysinfo/osinfo.py @@ -91,7 +91,7 @@ class OSInfo: (sys, node, release, ver, machine) = os.uname() isrt = 1 - if ver.find(' RT ') == -1: + if 'RT ' not in ver: isrt = 0 node_n = libxml2.newNode("node") -- 2.32.0