]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
5.10-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 11 Feb 2021 14:23:52 +0000 (15:23 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 11 Feb 2021 14:23:52 +0000 (15:23 +0100)
added patches:
nilfs2-make-splice-write-available-again.patch

queue-5.10/nilfs2-make-splice-write-available-again.patch [new file with mode: 0644]
queue-5.10/series

diff --git a/queue-5.10/nilfs2-make-splice-write-available-again.patch b/queue-5.10/nilfs2-make-splice-write-available-again.patch
new file mode 100644 (file)
index 0000000..de9d892
--- /dev/null
@@ -0,0 +1,38 @@
+From a35d8f016e0b68634035217d06d1c53863456b50 Mon Sep 17 00:00:00 2001
+From: Joachim Henke <joachim.henke@t-systems.com>
+Date: Tue, 9 Feb 2021 13:42:36 -0800
+Subject: nilfs2: make splice write available again
+
+From: Joachim Henke <joachim.henke@t-systems.com>
+
+commit a35d8f016e0b68634035217d06d1c53863456b50 upstream.
+
+Since 5.10, splice() or sendfile() to NILFS2 return EINVAL.  This was
+caused by commit 36e2c7421f02 ("fs: don't allow splice read/write
+without explicit ops").
+
+This patch initializes the splice_write field in file_operations, like
+most file systems do, to restore the functionality.
+
+Link: https://lkml.kernel.org/r/1612784101-14353-1-git-send-email-konishi.ryusuke@gmail.com
+Signed-off-by: Joachim Henke <joachim.henke@t-systems.com>
+Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
+Tested-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
+Cc: <stable@vger.kernel.org>   [5.10+]
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ fs/nilfs2/file.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/fs/nilfs2/file.c
++++ b/fs/nilfs2/file.c
+@@ -141,6 +141,7 @@ const struct file_operations nilfs_file_
+       /* .release     = nilfs_release_file, */
+       .fsync          = nilfs_sync_file,
+       .splice_read    = generic_file_splice_read,
++      .splice_write   = iter_file_splice_write,
+ };
+ const struct inode_operations nilfs_file_inode_operations = {
index fe8026f7a50ebdb6f4f955ed9e1082fcb860e58b..d5223a78a596a4e19d7d8381b305bf2bfe686a47 100644 (file)
@@ -46,3 +46,4 @@ bpf-fix-32-bit-src-register-truncation-on-div-mod.patch
 bpf-fix-verifier-jsgt-branch-analysis-on-max-bound.patch
 drm-i915-fix-icl-mg-phy-vswing-handling.patch
 drm-i915-skip-vswing-programming-for-tbt.patch
+nilfs2-make-splice-write-available-again.patch