start adding the tag to iov_iter
For now, just use the same thing we pass to ->direct_IO() - it's all iovec-based at the moment. Pass it explicitly to iov_iter_init() and account for kvec vs. iovec in there, by the same kludge NFS ->direct_IO() uses. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
@@ -173,7 +173,7 @@ nfs_file_read(struct kiocb *iocb, const struct iovec *iov,
|
||||
ssize_t result;
|
||||
struct iov_iter to;
|
||||
|
||||
iov_iter_init(&to, iov, nr_segs, count, 0);
|
||||
iov_iter_init(&to, READ, iov, nr_segs, count);
|
||||
|
||||
if (iocb->ki_filp->f_flags & O_DIRECT)
|
||||
return nfs_file_direct_read(iocb, &to, pos, true);
|
||||
@@ -648,7 +648,7 @@ ssize_t nfs_file_write(struct kiocb *iocb, const struct iovec *iov,
|
||||
ssize_t result;
|
||||
size_t count = iov_length(iov, nr_segs);
|
||||
struct iov_iter from;
|
||||
iov_iter_init(&from, iov, nr_segs, count, 0);
|
||||
iov_iter_init(&from, WRITE, iov, nr_segs, count);
|
||||
|
||||
result = nfs_key_timeout_notify(file, inode);
|
||||
if (result)
|
||||
|
Reference in New Issue
Block a user