kernel-hacking-2024-linux-s.../fs/btrfs
Josef Bacik fcb80c2aff Btrfs: fix how we do space reservation for truncate
The ceph guys keep running into problems where we have space reserved in our
orphan block rsv when freeing it up.  This is because they tend to do snapshots
alot, so their truncates tend to use a bunch of space, so when we go to do
things like update the inode we have to steal reservation space in order to make
the reservation happen.  This happens because truncate can use as much space as
it freaking feels like, but we still have to hold space for removing the orphan
item and updating the inode, which will definitely always happen.  So in order
to fix this we need to split all of the reservation stuf up.  So with this patch
we have

1) The orphan block reserve which only holds the space for deleting our orphan
item when everything is over.

2) The truncate block reserve which gets allocated and used specifically for the
space that the truncate will use on a per truncate basis.

3) The transaction will always have 1 item's worth of data reserved so we can
update the inode normally.

Hopefully this will make the ceph problem go away.  Thanks,

Signed-off-by: Josef Bacik <josef@redhat.com>
2011-05-23 13:03:08 -04:00
..
acl.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable 2011-05-15 10:22:10 -07:00
async-thread.c
async-thread.h
btrfs_inode.h
compat.h
compression.c Btrfs: check return value of btrfs_alloc_path() 2011-03-28 05:37:54 -04:00
compression.h
ctree.c Btrfs: check return value of read_tree_block() 2011-03-28 05:37:37 -04:00
ctree.h Btrfs: fix how we do space reservation for truncate 2011-05-23 13:03:08 -04:00
delayed-ref.c Btrfs: add initial tracepoint support for btrfs 2011-03-28 05:37:33 -04:00
delayed-ref.h
dir-item.c Btrfs: check return value of btrfs_alloc_path() 2011-03-28 05:37:54 -04:00
disk-io.c Btrfs: kill trans_mutex 2011-05-23 13:00:57 -04:00
disk-io.h
export.c
export.h
extent-tree.c Btrfs: fix how we do space reservation for truncate 2011-05-23 13:03:08 -04:00
extent_io.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable 2011-04-26 08:26:58 -07:00
extent_io.h btrfs: using cached extent_state in set/unlock combinations 2011-04-11 20:45:36 -04:00
extent_map.c Fix common misspellings 2011-03-31 11:26:23 -03:00
extent_map.h
file-item.c Btrfs: check return value of btrfs_alloc_path() 2011-03-28 05:37:54 -04:00
file.c Btrfs: kill trans_mutex 2011-05-23 13:00:57 -04:00
free-space-cache.c Btrfs: free bitmaps properly when evicting the cache 2011-04-25 19:43:52 -04:00
free-space-cache.h Btrfs: add btrfs_trim_fs() to handle FITRIM 2011-03-28 05:37:47 -04:00
hash.h
inode-item.c
inode-map.c Btrfs: cleanup some BUG_ON() 2011-03-28 05:37:35 -04:00
inode.c Btrfs: fix how we do space reservation for truncate 2011-05-23 13:03:08 -04:00
ioctl.c Btrfs: kill trans_mutex 2011-05-23 13:00:57 -04:00
ioctl.h
Kconfig
locking.c
locking.h
lzo.c
Makefile
ordered-data.c Btrfs: add initial tracepoint support for btrfs 2011-03-28 05:37:33 -04:00
ordered-data.h
orphan.c
print-tree.c
print-tree.h
ref-cache.c
ref-cache.h
relocation.c Btrfs: kill trans_mutex 2011-05-23 13:00:57 -04:00
root-tree.c Btrfs: Fix uninitialized root flags for subvolumes 2011-04-05 01:20:24 -04:00
struct-funcs.c
super.c Btrfs: fix subvolume mount by name problem when default mount subvolume is set 2011-04-11 20:26:50 -04:00
sysfs.c
transaction.c Btrfs: kill trans_mutex 2011-05-23 13:00:57 -04:00
transaction.h Btrfs: kill trans_mutex 2011-05-23 13:00:57 -04:00
tree-defrag.c
tree-log.c Btrfs: fix missing mutex_unlock in btrfs_del_dir_entries_in_log() 2011-04-25 19:43:51 -04:00
tree-log.h
version.h
version.sh
volumes.c Btrfs: do some plugging in the submit_bio threads 2011-04-19 20:12:40 -04:00
volumes.h Btrfs: make btrfs_map_block() return entire free extent for each device of RAID0/1/10/DUP 2011-03-28 05:37:45 -04:00
xattr.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable 2011-04-18 12:24:05 -07:00
xattr.h
zlib.c zlib: slim down zlib_deflate() workspace when possible 2011-03-22 17:44:17 -07:00