tracing: Make splice_read available again
stable inclusion from stable-v5.10.176 commit de3170bd41dee29039e8a87efa960759ad256a5a category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I8CHVQ Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=de3170bd41dee29039e8a87efa960759ad256a5a -------------------------------- commit e400be67 upstream. Since the commit 36e2c742 ("fs: don't allow splice read/write without explicit ops") is applied to the kernel, splice() and sendfile() calls on the trace file (/sys/kernel/debug/tracing /trace) return EINVAL. This patch restores these system calls by initializing splice_read in file_operations of the trace file. This patch only enables such functionalities for the read case. Link: https://lore.kernel.org/linux-trace-kernel/20230314013707.28814-1-sfoon.kim@samsung.com Cc: stable@vger.kernel.org Fixes: 36e2c742 ("fs: don't allow splice read/write without explicit ops") Signed-off-by:Sung-hun Kim <sfoon.kim@samsung.com> Signed-off-by:
Steven Rostedt (Google) <rostedt@goodmis.org> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by:
sanglipeng <sanglipeng1@jd.com>
Loading
Please sign in to comment