diff options
author | Jeff Layton <jlayton@kernel.org> | 2021-09-23 07:50:08 -0400 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2021-11-08 03:29:51 +0100 |
commit | 9c43ff4490ef1d721877fdfdb4ff2d9bda93f391 (patch) | |
tree | 45c9f966fef8b3999eb4e7801f4d2dc4eb705360 /fs | |
parent | 8bb7eca972ad531c9b149c0a51ab43a417385813 (diff) | |
download | lwn-9c43ff4490ef1d721877fdfdb4ff2d9bda93f391.tar.gz lwn-9c43ff4490ef1d721877fdfdb4ff2d9bda93f391.zip |
ceph: convert to noop_direct_IO
We have our own op, but the WARN_ON is not terribly helpful, and it's
otherwise identical to the noop one. Just use that.
Signed-off-by: Jeff Layton <jlayton@kernel.org>
Reviewed-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/ceph/addr.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c index 99b80b5c7a93..b42920431419 100644 --- a/fs/ceph/addr.c +++ b/fs/ceph/addr.c @@ -1306,17 +1306,6 @@ out: return copied; } -/* - * we set .direct_IO to indicate direct io is supported, but since we - * intercept O_DIRECT reads and writes early, this function should - * never get called. - */ -static ssize_t ceph_direct_io(struct kiocb *iocb, struct iov_iter *iter) -{ - WARN_ON(1); - return -EINVAL; -} - const struct address_space_operations ceph_aops = { .readpage = ceph_readpage, .readahead = ceph_readahead, @@ -1327,7 +1316,7 @@ const struct address_space_operations ceph_aops = { .set_page_dirty = ceph_set_page_dirty, .invalidatepage = ceph_invalidatepage, .releasepage = ceph_releasepage, - .direct_IO = ceph_direct_io, + .direct_IO = noop_direct_IO, }; static void ceph_block_sigs(sigset_t *oldset) |