Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Mike Marshall <hubcap@omnibond.com>
struct orangefs_khandle *handle = &orangefs_inode->refn.khandle;
struct orangefs_bufmap *bufmap = NULL;
struct orangefs_kernel_op_s *new_op = NULL;
+ struct iov_iter saved = *iter;
int buffer_index = -1;
ssize_t ret;
if (ret == -EAGAIN && op_state_purged(new_op)) {
orangefs_bufmap_put(bufmap, buffer_index);
buffer_index = -1;
+ if (type == ORANGEFS_IO_WRITE)
+ *iter = saved;
gossip_debug(GOSSIP_FILE_DEBUG,
"%s:going to repopulate_shared_memory.\n",
__func__);