aboutsummaryrefslogtreecommitdiff
path: root/tools/perf
diff options
context:
space:
mode:
authorBen Hutchings2013-05-20 14:45:57 +0000
committerDavid S. Miller2013-05-22 15:10:11 -0700
commit6b75c7357c947dd9fd8482b3395664a9b7385ed5 (patch)
tree213515aa6421863b679d6075416b2d52b41a99e7 /tools/perf
parent0ce58bae851dc3728af1c0b83905cd6b4565417a (diff)
perf: net_dropmonitor: Remove progress indicator
We can read /proc/kallsyms in a fraction of a second, so why waste a further fraction of a second showing progress? Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf')
-rwxr-xr-xtools/perf/scripts/python/net_dropmonitor.py13
1 files changed, 1 insertions, 12 deletions
diff --git a/tools/perf/scripts/python/net_dropmonitor.py b/tools/perf/scripts/python/net_dropmonitor.py
index 32fcee05c0f6..b5740599aabd 100755
--- a/tools/perf/scripts/python/net_dropmonitor.py
+++ b/tools/perf/scripts/python/net_dropmonitor.py
@@ -15,28 +15,17 @@ kallsyms = []
def get_kallsyms_table():
global kallsyms
+
try:
f = open("/proc/kallsyms", "r")
- linecount = 0
- for line in f:
- linecount = linecount+1
- f.seek(0)
except:
return
-
- j = 0
for line in f:
loc = int(line.split()[0], 16)
name = line.split()[2]
- j = j +1
- if ((j % 100) == 0):
- print "\r" + str(j) + "/" + str(linecount),
kallsyms.append((loc, name))
-
- print "\r" + str(j) + "/" + str(linecount)
kallsyms.sort()
- return
def get_sym(sloc):
loc = int(sloc)