summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorLiu Bo <bo.li.liu@oracle.com>2015-08-07 16:48:41 +0800
committerChris Mason <clm@fb.com>2015-08-09 07:33:50 -0700
commit4a3560c4f3f0f92d3b673944753e3e947e030bc4 (patch)
tree42c267c9b447ded5d96adbfb03efd87fa7195ed0 /tools/perf/scripts/python/export-to-postgresql.py
parentacdf898de8903f50bb10bbce4b774432bcd63c85 (diff)
Btrfs: fix defrag to merge tail file extent
The file layout is [extent 1]...[extent n][4k extent][HOLE][extent x] extent 1~n and 4k extent can be merged during defrag, and the whole defrag bytes is larger than our defrag thresh(256k), 4k extent as a tail is left unmerged since we check if its next extent can be merged (the next one is a hole, so the check will fail), the layout thus can be [new extent][4k extent][HOLE][extent x] (1~n) To fix it, beside looking at the next one, this also looks at the previous one by checking @defrag_end, which is set to 0 when we decide to stop merging contiguous extents, otherwise, we can merge the previous one with our extent. Also, this makes btrfs behave consistent with how xfs and ext4 do. Signed-off-by: Liu Bo <bo.li.liu@oracle.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