summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorSage Weil <sage@redhat.com>2014-09-26 19:30:06 +0400
committerChris Mason <clm@fb.com>2014-10-04 03:14:59 +0400
commit42383020beb1cfb05f5d330cc311931bc4917a97 (patch)
tree08e2411cd332c3c56323ac9ffc27164079e29daf /tools/perf/scripts/python/export-to-postgresql.py
parent656f30dba7ab8179c9a2e04293b0c7b383fa9ce9 (diff)
downloadlinux-42383020beb1cfb05f5d330cc311931bc4917a97.tar.xz
Btrfs: fix race in WAIT_SYNC ioctl
We check whether transid is already committed via last_trans_committed and then search through trans_list for pending transactions. If last_trans_committed is updated by btrfs_commit_transaction after we check it (there is no locking), we will fail to find the committed transaction and return EINVAL to the caller. This has been observed occasionally by ceph-osd (which uses this ioctl heavily). Fix by rechecking whether the provided transid <= last_trans_committed after the search fails, and if so return 0. Signed-off-by: Sage Weil <sage@redhat.com> Signed-off-by: Chris Mason <clm@fb.com>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions