diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2021-12-21 23:13:52 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@gmail.com> | 2021-12-25 18:48:46 -0500 |
commit | ad031731727d4239351afeebf675f069a289beb3 (patch) | |
tree | 6b5dba68f20c6861d90f5706bf1e822a94b84ed6 /libbcachefs/io.c | |
parent | 00f49f23b4c37865618c74a5cb3a65308a9c511d (diff) |
Update bcachefs sources to aa540d47ab bcachefs: Option improvements
Diffstat (limited to 'libbcachefs/io.c')
-rw-r--r-- | libbcachefs/io.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libbcachefs/io.c b/libbcachefs/io.c index a9ca81e..6e64a04 100644 --- a/libbcachefs/io.c +++ b/libbcachefs/io.c @@ -1289,7 +1289,7 @@ void bch2_write(struct closure *cl) bch2_keylist_init(&op->insert_keys, op->inline_keys); wbio_init(bio)->put_bio = false; - if (bio_sectors(bio) & (c->opts.block_size - 1)) { + if (bio->bi_iter.bi_size & (c->opts.block_size - 1)) { bch_err_inum_ratelimited(c, op->pos.inode, "misaligned write"); op->error = -EIO; @@ -2365,7 +2365,7 @@ int bch2_fs_io_init(struct bch_fs *c) BIOSET_NEED_BVECS) || mempool_init_page_pool(&c->bio_bounce_pages, max_t(unsigned, - c->opts.btree_node_size, + btree_sectors(c), c->sb.encoded_extent_max) / PAGE_SECTORS, 0) || rhashtable_init(&c->promote_table, &bch_promote_params)) |