提交 d88d46c6 编写于 作者: J Josef Bacik

Btrfs: free csums when we're done scrubbing an extent

A user reported scrub taking up an unreasonable amount of ram as it ran.  This
is because we lookup the csums for the extent we're scrubbing but don't free it
up until after we're done with the scrub, which means we can take up a whole lot
of ram.  This patch fixes this by dropping the csums once we're done with the
extent we've scrubbed.  The user reported this to fix their problem.  Thanks,
Reported-and-tested-by: NRemco Hosman <remco@hosman.xs4all.nl>
Signed-off-by: NJosef Bacik <jbacik@fusionio.com>
上级 1be41b78
......@@ -2505,6 +2505,7 @@ static noinline_for_stack int scrub_stripe(struct scrub_ctx *sctx,
if (ret)
goto out;
scrub_free_csums(sctx);
if (extent_logical + extent_len <
key.objectid + bytes) {
logical += increment;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册