FAILED: patch "[PATCH] fix the regression from "direct-io: Fix negative return from" failed to apply to 3.14-stable tree
Subsystems (2)
[email protected]
maintainerThe patch below does not apply to the 3.14-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
Quoted 1 line
From
2d4594acbf6d8f75a27f3578476b6a27d8b13ebbMon Sep 17 00:00:00 2001
From: Al Viro <[email protected]>
Date: Tue, 8 Dec 2015 12:22:47 -0500
Subject: [PATCH] fix the regression from "direct-io: Fix negative return from
dio read beyond eof"
Sure, it's better to bail out of past-the-eof read and return 0 than return a bogus negative value on such. Only we'd better make sure we are bailing out with 0 and not -ENOMEM...
Signed-off-by Al Viro <[email protected]>
fs/direct-io.c +1 -0
@@ -1175,6 +1175,7 @@ do_blockdev_direct_IO(struct kiocb *iocb, struct inode *inode,if (dio->flags &DIO_LOCKING )mutex_unlock (&inode->i_mutex);kmem_cache_free (dio_cache, dio); + retval =0 ; goto out; }