From: Li Zefan <lizf@cn.fujitsu.com>
To: Josef Bacik <josef@redhat.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] Btrfs: fix free space cache when there are pinned extents and clusters
Date: Fri, 01 Apr 2011 15:56:33 +0800 [thread overview]
Message-ID: <4D958531.90500@cn.fujitsu.com> (raw)
In-Reply-To: <1301601548-14612-1-git-send-email-josef@redhat.com>
> + spin_lock(&block_group->tree_lock);
> + if (btrfs_block_group_free_space(block_group) !=
This function call can be replaced by block_group->free_space, so
we don't have to iterate the tree.
(This function gets removed in my patchset for inode number caching)
> + (block_group->key.offset - used - block_group->bytes_super)) {
> + spin_unlock(&block_group->tree_lock);
> + printk(KERN_ERR "block group %llu has an wrong amount of free "
> + "space\n", block_group->key.objectid);
> + ret = 0;
> + goto free_cache;
> + }
> + spin_unlock(&block_group->tree_lock);
next prev parent reply other threads:[~2011-04-01 7:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-31 19:59 [PATCH] Btrfs: fix free space cache when there are pinned extents and clusters Josef Bacik
2011-04-01 7:56 ` Li Zefan [this message]
2011-04-01 12:15 ` Josef Bacik
2011-04-01 14:55 ` [PATCH] Btrfs: fix free space cache when there are pinned extents and clusters V2 Josef Bacik
2011-04-04 22:59 ` Mitch Harder
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4D958531.90500@cn.fujitsu.com \
--to=lizf@cn.fujitsu.com \
--cc=josef@redhat.com \
--cc=linux-btrfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).