aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorLogan Gunthorpe <[email protected]>2016-06-20 13:15:05 -0600
committerJon Mason <[email protected]>2016-08-05 10:21:06 -0400
commitda573eaa3a13f60efafcbe25e4f4465cf1a1b40b (patch)
tree4de19d41638f8499bbc19a80c7cbd9c36c5bac1f /tools/perf/scripts/python/export-to-postgresql.py
parentfd2ecd885bab8e456298d0b702806ea736456c62 (diff)
ntb_perf: Improve thread handling to increase robustness
This commit accomplishes a few things: 1) Properly prevent multiple sets of threads from running at once using a mutex. Lots of race issues existed with the thread_cleanup. 2) The mutex allows us to ensure that threads are finished before tearing down the device or module. 3) Don't use kthread_stop when the threads can exit by themselves, as this is counter-indicated by the kthread_create documentation. Threads now wait for kthread_stop to occur. 4) Writing to the run file now blocks until the threads are complete. The test can then be safely interrupted by a SIGINT. Also, while I was at it: 5) debugfs_run_write shouldn't return 0 in the early check cases as this could cause debugfs_run_write to loop undesirably. Signed-off-by: Logan Gunthorpe <[email protected]> Acked-by: Dave Jiang <[email protected]> Signed-off-by: Jon Mason <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions