Commit 023f9ac9 authored by Kent Overstreet's avatar Kent Overstreet

bcachefs: Delete dio read alignment check

We'll typically fomat devices with the physical blocksize supported, but
the logical blocksize will be smaller.

There's no real need to be checking the blocksize at the filesystem
level, anyways - the block layer has to check this anyways.
Signed-off-by: default avatarKent Overstreet <kent.overstreet@linux.dev>
parent 033c9d7a
...@@ -77,9 +77,6 @@ static int bch2_direct_IO_read(struct kiocb *req, struct iov_iter *iter) ...@@ -77,9 +77,6 @@ static int bch2_direct_IO_read(struct kiocb *req, struct iov_iter *iter)
bch2_inode_opts_get(&opts, c, &inode->ei_inode); bch2_inode_opts_get(&opts, c, &inode->ei_inode);
if ((offset|iter->count) & (block_bytes(c) - 1))
return -EINVAL;
ret = min_t(loff_t, iter->count, ret = min_t(loff_t, iter->count,
max_t(loff_t, 0, i_size_read(&inode->v) - offset)); max_t(loff_t, 0, i_size_read(&inode->v) - offset));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment