linux-stable/fs/btrfs
Josef Bacik 224ecce517 Btrfs: fix possible corruption when fsyncing written prealloced extents
While working on my fsync patch my fsync tester kept hitting mismatching
md5sums when I would randomly write to a prealloc'ed region, syncfs() and
then write to the prealloced region some more and then fsync() and then
immediately reboot.  This is because the tree logging code will skip writing
csums for file extents who's generation is less than the current running
transaction.  When we mark extents as written we haven't been updating their
generation so they were always being skipped.  This wouldn't happen if you
were to preallocate and then write in the same transaction, but if you for
example prealloced a VM you could definitely run into this problem.  This
patch makes my fsync tester happy again.  Thanks,

Signed-off-by: Josef Bacik <jbacik@fusionio.com>
2012-10-01 15:19:02 -04:00
..
acl.c
async-thread.c Btrfs: call the ordered free operation without any locks held 2012-07-25 16:15:07 -04:00
async-thread.h
backref.c Btrfs: fix gcc warnings for 32bit compiles 2012-10-01 15:19:01 -04:00
backref.h Merge branch 'send-v2' of git://github.com/ablock84/linux-btrfs into for-linus 2012-07-25 19:19:10 -04:00
btrfs_inode.h Btrfs: kill free_space pointer from inode structure 2012-07-23 16:28:05 -04:00
check-integrity.c Btrfs: introduce subvol uuids and times 2012-07-25 23:28:38 +02:00
check-integrity.h
compat.h
compression.c Btrfs: barrier before waitqueue_active 2012-08-28 16:53:33 -04:00
compression.h
ctree.c Btrfs: fix btrfs send for inline items and compression 2012-10-01 15:19:00 -04:00
ctree.h Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs 2012-08-29 11:36:22 -07:00
delayed-inode.c Btrfs: barrier before waitqueue_active 2012-08-28 16:53:33 -04:00
delayed-inode.h Btrfs: flush delayed inodes if we're short on space 2012-07-23 15:41:40 -04:00
delayed-ref.c Btrfs: allow delayed refs to be merged 2012-08-28 16:53:38 -04:00
delayed-ref.h Btrfs: allow delayed refs to be merged 2012-08-28 16:53:38 -04:00
dir-item.c
disk-io.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs 2012-08-29 11:36:22 -07:00
disk-io.h Btrfs: remove superblock writing after fatal error 2012-08-28 16:53:38 -04:00
export.c
export.h
extent-tree.c Btrfs: do not allocate chunks as agressively 2012-10-01 15:19:02 -04:00
extent_io.c Btrfs: fix btrfs send for inline items and compression 2012-10-01 15:19:00 -04:00
extent_io.h
extent_map.c
extent_map.h
file-item.c Btrfs: fix gcc warnings for 32bit compiles 2012-10-01 15:19:01 -04:00
file.c Btrfs: fix possible corruption when fsyncing written prealloced extents 2012-10-01 15:19:02 -04:00
free-space-cache.c Btrfs: do not count in readonly bytes 2012-07-23 16:28:03 -04:00
free-space-cache.h
hash.h
inode-item.c
inode-map.c
inode-map.h
inode.c Btrfs: update last trans if we don't update the inode 2012-10-01 15:19:02 -04:00
ioctl.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs 2012-08-29 11:36:22 -07:00
ioctl.h Merge branch 'send-v2' of git://github.com/ablock84/linux-btrfs into for-linus 2012-07-25 19:19:10 -04:00
Kconfig
locking.c Btrfs: fix a misplaced address operator in a condition 2012-08-28 16:53:23 -04:00
locking.h
lzo.c
Makefile Merge branch 'send-v2' of git://github.com/ablock84/linux-btrfs into for-linus 2012-07-25 19:19:10 -04:00
ordered-data.c btrfs: nuke pdflush from comments 2012-08-04 12:15:35 +04:00
ordered-data.h
orphan.c
print-tree.c
print-tree.h
qgroup.c Btrfs: fix gcc warnings for 32bit compiles 2012-10-01 15:19:01 -04:00
rcu-string.h Btrfs: use rcu to protect device->name 2012-06-14 21:29:16 -04:00
reada.c
relocation.c btrfs: use printk_get_level and printk_skip_level, add __printf, fix fallout 2012-07-30 17:25:14 -07:00
root-tree.c Btrfs: fix some endian bugs handling the root times 2012-08-28 16:53:26 -04:00
scrub.c Btrfs: use rcu to protect device->name 2012-06-14 21:29:16 -04:00
send.c Btrfs: fix gcc warnings for 32bit compiles 2012-10-01 15:19:01 -04:00
send.h Btrfs: introduce BTRFS_IOC_SEND for btrfs send/receive 2012-07-25 23:30:19 +02:00
struct-funcs.c Btrfs: rewrite BTRFS_SETGET_FUNCS 2012-07-23 16:28:06 -04:00
super.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs 2012-08-29 11:36:22 -07:00
sysfs.c
transaction.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs 2012-08-29 11:36:22 -07:00
transaction.h Merge branch 'qgroup' of git://git.jan-o-sch.net/btrfs-unstable into for-linus 2012-07-25 16:11:38 -04:00
tree-defrag.c
tree-log.c Btrfs: return error of btrfs_update_inode() to caller 2012-07-23 16:27:54 -04:00
tree-log.h
ulist.c Btrfs: make aux field of ulist 64 bit 2012-10-01 15:18:53 -04:00
ulist.h Btrfs: make aux field of ulist 64 bit 2012-10-01 15:18:53 -04:00
version.h
volumes.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs 2012-08-29 11:36:22 -07:00
volumes.h Btrfs: revert checksum error statistic which can cause a BUG() 2012-08-28 16:53:39 -04:00
xattr.c
xattr.h
zlib.c