mirror of
https://github.com/torvalds/linux.git
synced 2025-12-07 20:06:24 +00:00
Merge tag 'for-5.13-rc4-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux
Pull btrfs fixes from David Sterba:
"Error handling improvements, caught by error injection:
- handle errors during checksum deletion
- set error on mapping when ordered extent io cannot be finished
- inode link count fixup in tree-log
- missing return value checks for inode updates in tree-log
- abort transaction in rename exchange if adding second reference
fails
Fixes:
- fix fsync failure after writes to prealloc extents
- fix deadlock when cloning inline extents and low on available space
- fix compressed writes that cross stripe boundary"
* tag 'for-5.13-rc4-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
MAINTAINERS: add btrfs IRC link
btrfs: fix deadlock when cloning inline extents and low on available space
btrfs: fix fsync failure and transaction abort after writes to prealloc extents
btrfs: abort in rename_exchange if we fail to insert the second ref
btrfs: check error value from btrfs_update_inode in tree log
btrfs: fixup error handling in fixup_inode_link_counts
btrfs: mark ordered extent and inode with error if we fail to finish
btrfs: return errors from btrfs_del_csums in cleanup_ref_head
btrfs: fix error handling in btrfs_del_csums
btrfs: fix compressed writes that cross stripe boundary
This commit is contained in:
@@ -457,7 +457,7 @@ blk_status_t btrfs_submit_compressed_write(struct btrfs_inode *inode, u64 start,
|
||||
bytes_left = compressed_len;
|
||||
for (pg_index = 0; pg_index < cb->nr_pages; pg_index++) {
|
||||
int submit = 0;
|
||||
int len;
|
||||
int len = 0;
|
||||
|
||||
page = compressed_pages[pg_index];
|
||||
page->mapping = inode->vfs_inode.i_mapping;
|
||||
@@ -465,10 +465,17 @@ blk_status_t btrfs_submit_compressed_write(struct btrfs_inode *inode, u64 start,
|
||||
submit = btrfs_bio_fits_in_stripe(page, PAGE_SIZE, bio,
|
||||
0);
|
||||
|
||||
if (pg_index == 0 && use_append)
|
||||
len = bio_add_zone_append_page(bio, page, PAGE_SIZE, 0);
|
||||
else
|
||||
len = bio_add_page(bio, page, PAGE_SIZE, 0);
|
||||
/*
|
||||
* Page can only be added to bio if the current bio fits in
|
||||
* stripe.
|
||||
*/
|
||||
if (!submit) {
|
||||
if (pg_index == 0 && use_append)
|
||||
len = bio_add_zone_append_page(bio, page,
|
||||
PAGE_SIZE, 0);
|
||||
else
|
||||
len = bio_add_page(bio, page, PAGE_SIZE, 0);
|
||||
}
|
||||
|
||||
page->mapping = NULL;
|
||||
if (submit || len < PAGE_SIZE) {
|
||||
|
||||
Reference in New Issue
Block a user