diff options
author | David S. Miller <davem@davemloft.net> | 2018-10-13 00:38:46 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-10-13 00:38:46 -0400 |
commit | d864991b220b7c62e81d21209e1fd978fd67352c (patch) | |
tree | b570a1ad6fc1b959c5bcda6ceca0b321319c01e0 /tools/perf | |
parent | a688c53a0277d8ea21d86a5c56884892e3442c5e (diff) | |
parent | bab5c80b211035739997ebd361a679fa85b39465 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts were easy to resolve using immediate context mostly,
except the cls_u32.c one where I simply too the entire HEAD
chunk.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf')
-rw-r--r-- | tools/perf/scripts/python/export-to-postgresql.py | 9 | ||||
-rw-r--r-- | tools/perf/scripts/python/export-to-sqlite.py | 6 | ||||
-rw-r--r-- | tools/perf/util/machine.c | 8 | ||||
-rw-r--r-- | tools/perf/util/setup.py | 2 |
4 files changed, 20 insertions, 5 deletions
diff --git a/tools/perf/scripts/python/export-to-postgresql.py b/tools/perf/scripts/python/export-to-postgresql.py index efcaf6cac2eb..e46f51b17513 100644 --- a/tools/perf/scripts/python/export-to-postgresql.py +++ b/tools/perf/scripts/python/export-to-postgresql.py | |||
@@ -204,14 +204,23 @@ from ctypes import * | |||
204 | libpq = CDLL("libpq.so.5") | 204 | libpq = CDLL("libpq.so.5") |
205 | PQconnectdb = libpq.PQconnectdb | 205 | PQconnectdb = libpq.PQconnectdb |
206 | PQconnectdb.restype = c_void_p | 206 | PQconnectdb.restype = c_void_p |
207 | PQconnectdb.argtypes = [ c_char_p ] | ||
207 | PQfinish = libpq.PQfinish | 208 | PQfinish = libpq.PQfinish |
209 | PQfinish.argtypes = [ c_void_p ] | ||
208 | PQstatus = libpq.PQstatus | 210 | PQstatus = libpq.PQstatus |
211 | PQstatus.restype = c_int | ||
212 | PQstatus.argtypes = [ c_void_p ] | ||
209 | PQexec = libpq.PQexec | 213 | PQexec = libpq.PQexec |
210 | PQexec.restype = c_void_p | 214 | PQexec.restype = c_void_p |
215 | PQexec.argtypes = [ c_void_p, c_char_p ] | ||
211 | PQresultStatus = libpq.PQresultStatus | 216 | PQresultStatus = libpq.PQresultStatus |
217 | PQresultStatus.restype = c_int | ||
218 | PQresultStatus.argtypes = [ c_void_p ] | ||
212 | PQputCopyData = libpq.PQputCopyData | 219 | PQputCopyData = libpq.PQputCopyData |
220 | PQputCopyData.restype = c_int | ||
213 | PQputCopyData.argtypes = [ c_void_p, c_void_p, c_int ] | 221 | PQputCopyData.argtypes = [ c_void_p, c_void_p, c_int ] |
214 | PQputCopyEnd = libpq.PQputCopyEnd | 222 | PQputCopyEnd = libpq.PQputCopyEnd |
223 | PQputCopyEnd.restype = c_int | ||
215 | PQputCopyEnd.argtypes = [ c_void_p, c_void_p ] | 224 | PQputCopyEnd.argtypes = [ c_void_p, c_void_p ] |
216 | 225 | ||
217 | sys.path.append(os.environ['PERF_EXEC_PATH'] + \ | 226 | sys.path.append(os.environ['PERF_EXEC_PATH'] + \ |
diff --git a/tools/perf/scripts/python/export-to-sqlite.py b/tools/perf/scripts/python/export-to-sqlite.py index f827bf77e9d2..e4bb82c8aba9 100644 --- a/tools/perf/scripts/python/export-to-sqlite.py +++ b/tools/perf/scripts/python/export-to-sqlite.py | |||
@@ -440,7 +440,11 @@ def branch_type_table(*x): | |||
440 | 440 | ||
441 | def sample_table(*x): | 441 | def sample_table(*x): |
442 | if branches: | 442 | if branches: |
443 | bind_exec(sample_query, 18, x) | 443 | for xx in x[0:15]: |
444 | sample_query.addBindValue(str(xx)) | ||
445 | for xx in x[19:22]: | ||
446 | sample_query.addBindValue(str(xx)) | ||
447 | do_query_(sample_query) | ||
444 | else: | 448 | else: |
445 | bind_exec(sample_query, 22, x) | 449 | bind_exec(sample_query, 22, x) |
446 | 450 | ||
diff --git a/tools/perf/util/machine.c b/tools/perf/util/machine.c index c4acd2001db0..111ae858cbcb 100644 --- a/tools/perf/util/machine.c +++ b/tools/perf/util/machine.c | |||
@@ -2286,7 +2286,8 @@ static int append_inlines(struct callchain_cursor *cursor, | |||
2286 | if (!symbol_conf.inline_name || !map || !sym) | 2286 | if (!symbol_conf.inline_name || !map || !sym) |
2287 | return ret; | 2287 | return ret; |
2288 | 2288 | ||
2289 | addr = map__rip_2objdump(map, ip); | 2289 | addr = map__map_ip(map, ip); |
2290 | addr = map__rip_2objdump(map, addr); | ||
2290 | 2291 | ||
2291 | inline_node = inlines__tree_find(&map->dso->inlined_nodes, addr); | 2292 | inline_node = inlines__tree_find(&map->dso->inlined_nodes, addr); |
2292 | if (!inline_node) { | 2293 | if (!inline_node) { |
@@ -2312,7 +2313,7 @@ static int unwind_entry(struct unwind_entry *entry, void *arg) | |||
2312 | { | 2313 | { |
2313 | struct callchain_cursor *cursor = arg; | 2314 | struct callchain_cursor *cursor = arg; |
2314 | const char *srcline = NULL; | 2315 | const char *srcline = NULL; |
2315 | u64 addr; | 2316 | u64 addr = entry->ip; |
2316 | 2317 | ||
2317 | if (symbol_conf.hide_unresolved && entry->sym == NULL) | 2318 | if (symbol_conf.hide_unresolved && entry->sym == NULL) |
2318 | return 0; | 2319 | return 0; |
@@ -2324,7 +2325,8 @@ static int unwind_entry(struct unwind_entry *entry, void *arg) | |||
2324 | * Convert entry->ip from a virtual address to an offset in | 2325 | * Convert entry->ip from a virtual address to an offset in |
2325 | * its corresponding binary. | 2326 | * its corresponding binary. |
2326 | */ | 2327 | */ |
2327 | addr = map__map_ip(entry->map, entry->ip); | 2328 | if (entry->map) |
2329 | addr = map__map_ip(entry->map, entry->ip); | ||
2328 | 2330 | ||
2329 | srcline = callchain_srcline(entry->map, entry->sym, addr); | 2331 | srcline = callchain_srcline(entry->map, entry->sym, addr); |
2330 | return callchain_cursor_append(cursor, entry->ip, | 2332 | return callchain_cursor_append(cursor, entry->ip, |
diff --git a/tools/perf/util/setup.py b/tools/perf/util/setup.py index 97efbcad076e..1942f6dd24f6 100644 --- a/tools/perf/util/setup.py +++ b/tools/perf/util/setup.py | |||
@@ -35,7 +35,7 @@ class install_lib(_install_lib): | |||
35 | 35 | ||
36 | cflags = getenv('CFLAGS', '').split() | 36 | cflags = getenv('CFLAGS', '').split() |
37 | # switch off several checks (need to be at the end of cflags list) | 37 | # switch off several checks (need to be at the end of cflags list) |
38 | cflags += ['-fno-strict-aliasing', '-Wno-write-strings', '-Wno-unused-parameter' ] | 38 | cflags += ['-fno-strict-aliasing', '-Wno-write-strings', '-Wno-unused-parameter', '-Wno-redundant-decls' ] |
39 | if cc != "clang": | 39 | if cc != "clang": |
40 | cflags += ['-Wno-cast-function-type' ] | 40 | cflags += ['-Wno-cast-function-type' ] |
41 | 41 | ||