[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170428172024.GL29622@ZenIV.linux.org.uk>
Date: Fri, 28 Apr 2017 18:20:25 +0100
From: Al Viro <viro@...IV.linux.org.uk>
To: Dave Jones <davej@...emonkey.org.uk>,
Linux Kernel <linux-kernel@...r.kernel.org>
Subject: Re: iov_iter_pipe warning.
On Fri, Apr 28, 2017 at 12:50:24PM -0400, Dave Jones wrote:
> currently running v4.11-rc8-75-gf83246089ca0
>
> sunrpc bit is for the other unrelated problem I'm chasing.
>
> note also, I saw the backtrace without the fs/splice.c changes.
Interesting... Could you add this and see if that triggers?
diff --git a/fs/splice.c b/fs/splice.c
index 540c4a44756c..12a12d9c313f 100644
--- a/fs/splice.c
+++ b/fs/splice.c
@@ -306,6 +306,9 @@ ssize_t generic_file_splice_read(struct file *in, loff_t *ppos,
kiocb.ki_pos = *ppos;
ret = call_read_iter(in, &kiocb, &to);
if (ret > 0) {
+ if (WARN_ON(iov_iter_count(&to) != len - ret))
+ printk(KERN_ERR "ops %p: was %zd, left %zd, returned %d\n",
+ in->f_op, len, iov_iter_count(&to), ret);
*ppos = kiocb.ki_pos;
file_accessed(in);
} else if (ret < 0) {
Powered by blists - more mailing lists