aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Kacur <jkacur@redhat.com>2017-05-18 13:32:48 +0200
committerJohn Kacur <jkacur@redhat.com>2017-05-18 13:32:48 +0200
commit42d724f1a68815ecf7b44c7a2b9001363c93f4ce (patch)
tree808f7d400e146a495931a4d27f9cf2965947d15e
parent035794c6485dc69bbea58659ac73c5e6bfda5ec8 (diff)
downloadrteval-42d724f1a68815ecf7b44c7a2b9001363c93f4ce.tar.gz
rteval: systopology.py: Remove underscore from sysread
Remove underscore from sysread. I'm eseentially backporting this comment from the obsolete file rteval/sysinfo/systopology.py Signed-off-by: John Kacur <jkacur@redhat.com>
-rw-r--r--rteval/systopology.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/rteval/systopology.py b/rteval/systopology.py
index 7c0985e..fc3876c 100644
--- a/rteval/systopology.py
+++ b/rteval/systopology.py
@@ -27,7 +27,7 @@ import os, sys
import os.path
import glob
-def _sysread(path, obj):
+def sysread(path, obj):
fp = open(os.path.join(path,obj), "r")
return fp.readline().strip()
@@ -117,7 +117,7 @@ class CpuList(object):
return True
path = os.path.join(CpuList.cpupath,'cpu%d' % n)
if os.path.exists(path):
- return _sysread(path, "online") == 1
+ return sysread(path, "online") == 1
return False
#
@@ -132,7 +132,7 @@ class NumaNode(object):
def __init__(self, path):
self.path = path
self.nodeid = int(os.path.basename(path)[4:].strip())
- self.cpus = CpuList(_sysread(self.path, "cpulist"))
+ self.cpus = CpuList(sysread(self.path, "cpulist"))
self.getmeminfo()
# function for the 'in' operator