]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
bcachefs: Delete dio read alignment check
authorKent Overstreet <kent.overstreet@linux.dev>
Wed, 20 Dec 2023 02:58:20 +0000 (21:58 -0500)
committerKent Overstreet <kent.overstreet@linux.dev>
Mon, 1 Jan 2024 16:47:42 +0000 (11:47 -0500)
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: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/fs-io-direct.c

index 84e20c3ada6cbb50e3de3a40510db6125856e443..fdd57c5785c9cebf609959fb753ee30e55e85b92 100644 (file)
@@ -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);
 
-       if ((offset|iter->count) & (block_bytes(c) - 1))
-               return -EINVAL;
-
        ret = min_t(loff_t, iter->count,
                    max_t(loff_t, 0, i_size_read(&inode->v) - offset));